Comments (25)
It seems that my current approach is not working well under Linux. I'll change my approach tomorrow.
from lua-language-server.
Thank you also for helping me test!
from lua-language-server.
你需要在启动lua时指定当前目录为 "/Users/jiya/workspace/lua-language-server/publish/lua-language-server/server/"
此外,建议启动参数加上 "-E" 以免加载到其他位置的同名文件
from lua-language-server.
现在不再需要外部指定当前目录
from lua-language-server.
Same error here, when trying to use it in VSCode on macOS Mojave...
[Error - 3:01:40 PM] Connection to server is erroring. Shutting down server.
[Error - 3:01:40 PM] Connection to server is erroring. Shutting down server.
/Users/bartel/.vscode/extensions/sumneko.lua-0.9.8/server/bin/lua-language-server: ...tel/.vscode/extensions/sumneko.lua-0.9.8/server/main.lua:11: module 'bee.filesystem' not found:
no field package.preload['bee.filesystem']
no file '/usr/local/share/lua/5.4/bee/filesystem.lua'
no file '/usr/local/share/lua/5.4/bee/filesystem/init.lua'
no file '/usr/local/lib/lua/5.4/bee/filesystem.lua'
no file '/usr/local/lib/lua/5.4/bee/filesystem/init.lua'
no file './bee/filesystem.lua'
no file './bee/filesystem/init.lua'
no file '/usr/local/lib/lua/5.4/bee/filesystem.so'
no file '/usr/local/lib/lua/5.4/loadall.so'
no file './bee/filesystem.so'
no file '/usr/local/lib/lua/5.4/bee.so'
no file '/usr/local/lib/lua/5.4/loadall.so'
no file './bee.so'
stack traceback:
[C]: in function 'require'
...tel/.vscode/extensions/sumneko.lua-0.9.8/server/main.lua:11: in main chunk
[C]: in ?
from lua-language-server.
You need build the extension yourself on macOS.
Please refer to Readme
.
from lua-language-server.
I did this. Installed the plugin/extension in VSCode.
Cloned git repo (just now, so up to date)
ran ./osx, output :
/Users/bartel/git/lua-language-server
Try to install lua-language-server for you:
installed.
please restart VScode and enjoy.
Done.
After restarting VSCode I get that error.
from lua-language-server.
@Letrab Please update server/main.lua
manually to try if the problem has been solved.
from lua-language-server.
Same thing unfortunately.
Manually starting main.lua (with lua-language-server) does work now tough, which was not before.
Bartels-MacBook-Pro:server bartel$ pwd
/Users/bartel/.vscode/extensions/sumneko.lua-0.9.8/server
Bartels-MacBook-Pro:server bartel$ ./bin/lua-language-server main.lua
But seems that the VSCode path is not in /Users/bartel/.vscode/extensions/sumneko.lua-0.9.8/server while trying to start the server (as it cannot find bee.so)
(Same error as above)
from lua-language-server.
@Letrab Maybe you need to rebuild, see #41
from lua-language-server.
I started fresh again:
Uninstalled the extension.
Did a clean checkout of the github repo
Rebuilt with ./osx.sh
I can see the bee.so is moved, but somehow it is still not possible for VSCode to find it.
from lua-language-server.
What is the error message now?
from lua-language-server.
Same:
/Users/bartel/.vscode/extensions/sumneko.lua-0.9.8/server/bin/lua-language-server: ...tel/.vscode/extensions/sumneko.lua-0.9.8/server/main.lua:11: module 'bee.filesystem' not found:
no field package.preload['bee.filesystem']
no file '/usr/local/share/lua/5.4/bee/filesystem.lua'
no file '/usr/local/share/lua/5.4/bee/filesystem/init.lua'
no file '/usr/local/lib/lua/5.4/bee/filesystem.lua'
no file '/usr/local/lib/lua/5.4/bee/filesystem/init.lua'
no file './bee/filesystem.lua'
no file './bee/filesystem/init.lua'
no file '/usr/local/lib/lua/5.4/bee/filesystem.so'
no file '/usr/local/lib/lua/5.4/loadall.so'
no file './bee/filesystem.so'
no file '/usr/local/lib/lua/5.4/bee.so'
no file '/usr/local/lib/lua/5.4/loadall.so'
no file './bee.so'
stack traceback:
[C]: in function 'require'
...tel/.vscode/extensions/sumneko.lua-0.9.8/server/main.lua:11: in main chunk
[C]: in ?
from lua-language-server.
It seems you are using an old server/main.lua
, please check it.
from lua-language-server.
Correct, had to copy indeed the git server/main.lua over /Users/bartel/.vscode/extensions/sumneko.lua-0.9.8/server/main.lua
Other errors now:
It faulty detects and tries to load .dll files (I need .so files instead). I had to manually copy all .so files (Ini.so, lpeglabel.so) into the /bin folder to get it working (it does not check the /server folder).
After removing these .dll files in /bin and copying the .so files into /bin, it is working properly.
from lua-language-server.
I tried your latest commit, and responded to it:
from lua-language-server.
Did you use the latest osx.sh
?
from lua-language-server.
Yes,
In my git repo the files are correctly copied with this statement:
cp bin/*.so .
But in the .vscode/extensions/sumneko.lua-0.9.8/server/ directory, they are still in /server/
cp server/*.so "${INSTALL_PATH}/server"
should change to
cp server/*.so "${INSTALL_PATH}/server/bin"
Or actually the first cp bin/*.so .
may be removed and the line above becomes:
cp server/bin/*.so "${INSTALL_PATH}/server/bin"
from lua-language-server.
Could you please help me update the osx.sh
?
from lua-language-server.
As said above and confirmed:
remove cp bin/*.so .
Change cp server/*.so "${INSTALL_PATH}/server"
to cp server/bin/*.so "${INSTALL_PATH}/server/bin"
(And then copying main.lua to the vscode extension folder). It works!
from lua-language-server.
You could edit it yourself, then open a pull request.
from lua-language-server.
@Letrab I updated osx.sh
, please help me test if it works correctly now.
from lua-language-server.
Fixed now. Thank you!
from lua-language-server.
@Letrab I updated
osx.sh
, please help me test if it works correctly now.
脚本这么写,如果我不用vs code就有问题了!还要安装一个vs code,然后安装插件才可以编译了!
from lua-language-server.
Nice, fully works now with 0.9.9 without copying files manually! Thanks!
from lua-language-server.
Related Issues (20)
- Trailing slash for rootUri will duplicate folder name HOT 1
- Do not shadow/re-inject fields in child-classes HOT 1
- @overload not as expected check param in class instance
- Possible typo when handling `workspace.library`
- [Feature request] Support for the upvalue limit HOT 1
- neovim补全项对比vscode下有缺漏
- generic in the loop HOT 1
- Collapsing of functions in the editor breaks if there is a comment before and after the function declaration
- How to link to treesitter folder from `workspace.library`? HOT 3
- VSCode pop-up error `Request textDocument/documentSymbol failed.` when typing
- When using alias values as its keys, Dictionary types don't give completion when defining an instance of that dictionary
- Error returning derived classes
- Optional not removed in if/elseif block for field in filter
- 目录重命名, 移动目录, 在自动修改req路径时, 新路径会出现多余字符, 或者不修改
- [Future Ruquest] Add tracking for `rawset()` in function runtime and etc
- [Feature Request] Support custom file extension
- Command line doc_out_path arg doesn't work
- Missing fields on inherited class not resulting in diagnostics warnings
- Function with generic variable return type loses typing after first return
- ---@class with function return question
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from lua-language-server.