Comments (26)
@axelson I don’t remember for sure, but it should be one of these two (probably the second one):
-
https://marketplace.visualstudio.com/items?itemName=saratravi.elixir-formatter
-
https://marketplace.visualstudio.com/items?itemName=sammkj.vscode-elixir-formatter
It was a very old one, I don’t remember when I’ve installed it. I’ve just found to have it, I removed it, and everything worked as expected.
from vscode-elixir-ls.
Okay, well if you figure it out please report back! Best of luck :)
from vscode-elixir-ls.
I had this same issue and realized it was because I had set my default formatter to Prettier in my user settings. So prettier was trying to format my elixir files instead of vscode-elixir-ls.
from vscode-elixir-ls.
I'm experiencing the same with Formatter.
from vscode-elixir-ls.
@minibikini it turned out the problem (at least in my own case) was caused by an old elixir-formatter
extension which was installed along with elixir-ls
.
Removing that extension solved the problem, formatter works again.
Maybe I should close this issue.
from vscode-elixir-ls.
Hm, I don't have elixir-formatter
, my formatter is elixir-lsp.elixir-ls
.
from vscode-elixir-ls.
@andreapavoni can you send a link to that incompatible formatter that you were using? I'd like to add it to the list of incompatible extensions.
@minibikini Can you send details of your setup? You can get initial details by running the "ElixirLS Fork: Copy Debug Info" command. Also please list your installed extensions and check your logs (via View->Output->ElixirLS Fork) for any potentially relevant info.
from vscode-elixir-ls.
@axelson not sure what happened but it works fine now.
Visual Studio Code
Version: 1.44.0
Commit: 2aae1f26c72891c399f860409176fe435a154b13
Date: 2020-04-08T08:23:56.137Z (5 days ago)
Electron: 7.1.11
Chrome: 78.0.3904.130
Node.js: 12.8.1
V8: 7.8.279.23-electron.0
OS: Darwin x64 18.7.0
ElixirLS Fork: Copy Debug Info
* Elixir & Erlang versions (elixir --version): Erlang/OTP 22 [erts-10.7.1] [source] [64-bit] [smp:8:8] [ds:8:8:10] [async-threads:1] [hipe] [dtrace]
Elixir 1.10.2 (compiled with Erlang/OTP 22)
* VSCode ElixirLS Fork version: 0.3.2
* Operating System Version: darwin 18.7.0
Installed extentions
karunamurti.haml-1.3.0
kumar-harsh.graphql-for-vscode-1.15.3
marcostazi.vs-code-vagrantfile-0.0.7
mauve.terraform-1.4.0
mrmlnc.vscode-stylefmt-2.5.0
mrorz.language-gettext-0.1.1
ms-azuretools.vscode-docker-1.0.0
ms-python.python-2020.3.71659
ms-vscode.theme-markdownkit-0.1.4
nuuf.theme-hackershaze-2.0.1
octref.vetur-0.24.0
pgourlain.erlang-0.5.2
rebornix.ruby-0.27.0
ricard.postcss-2.0.0
riussi.code-stats-vscode-1.0.18
robinbentley.sass-indented-1.5.1
rust-lang.rust-0.7.0
sammkj.vscode-elixir-formatter-0.2.0
samverschueren.final-newline-0.3.2
sensourceinc.vscode-sql-beautify-0.0.4
shanoor.vscode-nginx-0.6.0
shinnn.stylelint-0.51.0
stefanjarina.vscode-eex-snippets-0.0.6
streetsidesoftware.code-spell-checker-1.8.0
streetsidesoftware.code-spell-checker-russian-0.2.4
TeddyDD.fish-0.0.4
wingrunr21.vscode-ruby-0.27.0
yzhang.markdown-all-in-one-2.8.0
zhuangtongfa.material-theme-3.2.5
from vscode-elixir-ls.
Formatter still hangs for me. Nothing in the ElixirLS logs. :/
from vscode-elixir-ls.
@minibikini have you tried to uninstall your elixir-formatter extension at all? Your files should be formatted anyway.
from vscode-elixir-ls.
@andreapavoni I think my formatter is part of ElixirLS and I can't uninstall it separately. I could disable formatting but prefer to keep it and restart vscode once in an hour (it helps in my case).
from vscode-elixir-ls.
@minibikini Please uninstall sammkj.vscode-elixir-formatter-0.2.0
and try again. Installing that extension reproduced your issue for me and the next version of vscode-elixir-ls will give a warning if it is installed.
from vscode-elixir-ls.
Oh, right. I thought I already uninstalled that.
from vscode-elixir-ls.
thanks, @axelson!
from vscode-elixir-ls.
You're welcome! I'm glad that fixed it!
from vscode-elixir-ls.
@axelson Looks like the formatter still hangs for me 😢
Nothing suspicions in logs.
from vscode-elixir-ls.
After looking again at the logs I found something which looks like ElixirLS error:
[Info - 6:38:25 PM] Returning location struct
[Info - 6:38:26 PM] [ElixirLS Dialyzer] Analysis finished in 3934 milliseconds
[Info - 6:38:27 PM] Dialyzer analysis is up to date
/usr/local/Cellar/erlang/22.3.2/lib/erlang/lib/kernel-6.5.2/src/os.erl:
at line 26:
can't find include file "file.hrl"
[Warn - 6:38:27 PM] docsh error: error
[{edoc,'-check_forms/3-fun-0-',3,[{file,"edoc.erl"},{line,712}]},
{lists,foreach,2,[{file,"lists.erl"},{line,1338}]},
{edoc,read_source,2,[{file,"edoc.erl"},{line,581}]},
{edoc_extract,source,3,[{file,"edoc_extract.erl"},{line,57}]},
{docsh_edoc,to_internal,2,
[{file,"/home/jason/dev/forks/vscode-elixir-ls/elixir-ls/deps/docsh/src/docsh_edoc.erl"},
{line,43}]},
{docsh_lib,convert_one,1,
[{file,"/home/jason/dev/forks/vscode-elixir-ls/elixir-ls/deps/docsh/src/docsh_lib.erl"},
{line,42}]},
{lists,flatmap,2,[{file,"lists.erl"},{line,1250}]},
{docsh_lib,convert,3,
[{file,"/home/jason/dev/forks/vscode-elixir-ls/elixir-ls/deps/docsh/src/docsh_lib.erl"},
{line,37}]}]
[Info - 6:38:29 PM] [ElixirLS Dialyzer] Writing manifest...
[Info - 6:38:31 PM] [ElixirLS Dialyzer] Done writing manifest in 3623 milliseconds.
[Info - 6:38:40 PM] [ElixirLS WorkspaceSymbols] Indexing...
Compiling with Mix env test
RUM enabled: false
[Info - 6:38:41 PM] [ElixirLS WorkspaceSymbols] Module discovery complete
[Info - 6:38:43 PM] [ElixirLS WorkspaceSymbols] 773 callbacks added to index
[Info - 6:38:53 PM] Compile took 12967 milliseconds
[Info - 6:38:53 PM] [ElixirLS Dialyzer] Checking for stale beam files
[Info - 6:38:54 PM] [ElixirLS WorkspaceSymbols] 2614 modules added to index
[Info - 6:38:54 PM] [ElixirLS Dialyzer] Found 0 changed files in 132 milliseconds
[Info - 6:38:57 PM] [ElixirLS WorkspaceSymbols] 1622 types added to index
[Info - 6:38:59 PM] [ElixirLS Dialyzer] Analyzing 0 modules: []
[Info - 6:38:59 PM] [ElixirLS Dialyzer] Analysis finished in 4763 milliseconds
[Info - 6:39:00 PM] Dialyzer analysis is up to date
[Info - 6:39:02 PM] [ElixirLS Dialyzer] Writing manifest...
[Info - 6:39:03 PM] [ElixirLS Dialyzer] Done writing manifest in 3647 milliseconds.
[Info - 6:39:28 PM] [ElixirLS WorkspaceSymbols] 30707 functions added to index
from vscode-elixir-ls.
@minibikini what OS are you running and how did you install Elixir and Erlang? Maybe you have an incomplete installation of Erlang.
from vscode-elixir-ls.
- OSX 10.14.6
- Erlang/OTP 22 [erts-10.7.1] [source] [64-bit] [smp:8:8] [ds:8:8:10] [async-threads:1] [hipe] [dtrace]
- Elixir 1.10.2 (compiled with Erlang/OTP 22)
I'll try to reinstall it, thanks.
from vscode-elixir-ls.
@minibikini but how did you install elixir/erlang? homebrew? asdf? etc.
from vscode-elixir-ls.
Homebrew
from vscode-elixir-ls.
@minibikini Did reinstalling help? I'm not able to reproduce when using elixir installed via homebrew. Does it also fail if you install elixir and erlang via asdf?
from vscode-elixir-ls.
Hopefully, yes - so far it works fine.
I didn't try asdf
. Will do if the the issue occur again.
from vscode-elixir-ls.
@axelson formatter still hangs, but it's probably not ElixirLS fault because I've noticed that erlang formatter hangs too. I've tried to install elixir and erlang via asdf, also reinstalled VSCode.
from vscode-elixir-ls.
Hello! This is happening to me fairly reliably. I do not have any other formatters installed or set to my default formatter. My debug info is
* Elixir & Erlang versions (elixir --version): Erlang/OTP 24 [erts-12.1.5] [source] [64-bit] [smp:8:8] [ds:8:8:10] [async-threads:1]
Elixir 1.13.0 (compiled with Erlang/OTP 24)
* VSCode ElixirLS version: 0.9.0
* Operating System Version: darwin 20.6.0
Elixir and erlang are installed via asdf.
Closing and reopening vscode seems to "fix" the formatter for one formatting action before it begins to hang again. Same with reshimming asdf. There is no other output in the dev console.
from vscode-elixir-ls.
Out of curiosity, I downgraded to 0.8.1 and this still occurs. I was able to format twice in quick succession, but after making some edits and attempting to format again it hung.
from vscode-elixir-ls.
Related Issues (20)
- dialyzerEnabled flag config is ignored after ElixirLS is restarted HOT 4
- LanguageClientOptions.synchronize.configurationSection is deprecated
- Configuration synchronisation stops working after server restart HOT 1
- Syntax for vars is probably invalid
- elixir-ls for vscode keeps crashing when using fish as the default shell HOT 7
- Phoenix LiveView + Hot reload crashes the app HOT 1
- ElixirLS on Windows seems to silently not work HOT 2
- chris
- chris
- xxc HOT 1
- Launch configuration env not respected in folderless debug session HOT 7
- "There is no formatter for 'elixir' files installed" HOT 16
- Syntax highlighting changes in 0.17.0 HOT 42
- Rollback the syntax highlighter and plot a more comprehensive and community engaged course for its future HOT 3
- Autocomplete spacing between Module and type (e.g. struct/behaviour) HOT 3
- ElixirLS v0.17.1 in VSCode significantly changes token scopes, affecting syntax highlighting HOT 7
- Support for language server running inside a docker container HOT 9
- Document an example devcontainer setup
- Task runner and multi-root workspaces
- Diagnostics do not disappear after server restart
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 vscode-elixir-ls.