-
-
Notifications
You must be signed in to change notification settings - Fork 852
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error executing lua Failed to load parser: uv_dlopen: cpp.so is not a valid Win32 application. #1985
Comments
IDK what was actually the problem but the followed the instructions in the Troubleshooting section of the following link (https://github.com/nvim-treesitter/nvim-treesitter/wiki/Windows-support) and now everything is working fine. |
yeah, sometime I have that error too, when this error happen again, just update nvim-treesitter, neovim-nightly and reinstall parser |
same issue on m1 mac @maxxnino how do you reinstall parser? |
@geofflangenderfer in neovim type |
I am still facing this problem I have installed clang version 14.0.0 add to path but still I get error cannot run html.so file in win32 |
I use :TSInstall vue online and everything is fine, then copy entire directory to the machine offline, get error vue.so is not a valid win32 file. I still find the approach to use it in offline. |
I'm having the extract same issue here and :TSUpdate shows All parsers are up-to-date. :TSInstall all shows everything installed properly. |
I found it. From :checkhealth I see compiler select gcc in online circumstance and clang in offline, and ABI different one is 13 and another 14. and then reinstall and recompile in online, copy parser to offline, everything is find. |
You need a 64 bit parser because neovim is 64 bit but you likely have 32 bit MinGW. So downloading 64 bit MinGW should fix (it did for me). |
Just want to add suggestion for other who had same issue. Installing zig as compiler would be a faster solution (for Windows user). This method assume you had installed Steps:
For me, this solution works and its quite easy. Have a good day 🙏 |
Worked perfectly for me on Windows!!! Thank you |
Saved my life. |
This installation can also be done by using chocolatey: |
THANKS !!!!!!!!!!!!!!!!! |
Ran into similar issue on a Linux machine when I ran the |
this doesnt work at all. when i try to add the compiler i get this Error detected while processing C:\Users\me\AppData\Local\nvim\init.lua: |
try it like this |
Thank you so much. It took me so much time and finally this helped |
You have done syntax mistake in config file check again |
Thank you very much! I tried all other compilers but |
Before reporting
:TSUpdate
Describe the bug
When ever try to open my .cpp file which contains Win32 code in it with neovide (or nvim) from command-prompt or any other .cpp file I get an error saying:
"Error_ detected while processing FileType Autocommands for "*":
E5108: Error executing lua Failed to load parser: uv_dlopen: C:\Users\Swagat\AppData\Local\nvim\plugged\nvim-treesitter\parser\cpp.so is not a valid Win32 application."
pics:->
![error1](https://user-images.githubusercontent.com/72545910/140612461-488985ef-b0ef-4545-88c1-ea34e4cd09e0.PNG)
and there is no syntax highlighting for the Win32 api code.
pics:->
But when I do the same thing from Cmder or Git (I use neovide. Since nvim do not works properly with cmder) I get No-Errors and also get a proper syntax highlighting for the code.
pics:->
![g1](https://user-images.githubusercontent.com/72545910/140612613-03d9dd7f-8359-4a00-a6b8-6e491c71d0e5.PNG)
To Reproduce
Expected behavior
I Expect that the neovim and neovide to show me proper syntax highlighting for my Win32 code and no errors like the following. I want the same behaviour when I open the file with Neovide and Neovim from Command prompt, just like when I do the same thing from Cmder Or Git.
Output of
:checkhealth nvim-treesitter
Output of
nvim --version
Additional context
As you can see I use Windows 10 (x64), here is my configuration for tree-sitter :
"nvim-treesitter settings
lua <<EOF
require'nvim-treesitter.configs'.setup
{
ensure_installed = "maintained", -- one of "all", "maintained" (parsers with maintainers), or a list of languages
}
require('nvim-treesitter.install').compilers = { "cl", "clang", "gcc" }
EOF
The text was updated successfully, but these errors were encountered: