You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Whenever I change my Gemfile (add/remove a gem), I see the error popup:
Warning
Connection to server got closed. Server will not be restarted.
Load a Ruby on Rails project
Ruby LSP starts just fine
Make a change to the Gemfile, add or remove a gem
See the warning (above)
See the log output below:
Code snippet or error message
2025-01-09 14:25:12.145 [info] (my-project-name) Restarting the Ruby LSP because /Users/jakeonrails/source/my-project-name/Gemfile.lock changed, matching {Gemfile.lock,gems.locked}
2025-01-09 14:25:12.653 [info] (my-project-name) /Users/jakeonrails/.asdf/installs/ruby/3.3.1/lib/ruby/gems/3.3.0/gems/ruby-lsp-0.23.3/lib/ruby_lsp/base_server.rb:123:in `join': No live threads left. Deadlock? (fatal)
2 threads, 2 sleeps current:0x000000013360a340 main thread:0x000000013360a340
* #<Thread:0x0000000104e6b298 sleep_forever>
rb_thread_t:0x000000013360a340 native:0x00000001ea80cc00 int:0
* #<Thread:0x00000001270145a0 /Users/jakeonrails/.asdf/installs/ruby/3.3.1/lib/ruby/gems/3.3.0/gems/ruby-lsp-0.23.3/lib/ruby_lsp/base_server.rb:26 sleep_forever>
rb_thread_t:0x0000000132876ae0 native:0x000000016b2ef000 int:0 mutex:0x000000013360ac60 cond:1
depended by: tb_thread_id:0x000000013360a340
from /Users/jakeonrails/.asdf/installs/ruby/3.3.1/lib/ruby/gems/3.3.0/gems/ruby-lsp-0.23.3/lib/ruby_lsp/base_server.rb:123:in `run_shutdown'
from /Users/jakeonrails/.asdf/installs/ruby/3.3.1/lib/ruby/gems/3.3.0/gems/ruby-lsp-0.23.3/lib/ruby_lsp/base_server.rb:99:in `block (2 levels) in start'
from /Users/jakeonrails/.asdf/installs/ruby/3.3.1/lib/ruby/gems/3.3.0/gems/ruby-lsp-0.23.3/lib/ruby_lsp/global_state.rb:64:in `synchronize'
from /Users/jakeonrails/.asdf/installs/ruby/3.3.1/lib/ruby/gems/3.3.0/gems/ruby-lsp-0.23.3/lib/ruby_lsp/global_state.rb:64:in `synchronize'
from /Users/jakeonrails/.asdf/installs/ruby/3.3.1/lib/ruby/gems/3.3.0/gems/ruby-lsp-0.23.3/lib/ruby_lsp/base_server.rb:96:in `block in start'
from /Users/jakeonrails/.asdf/installs/ruby/3.3.1/lib/ruby/gems/3.3.0/gems/language_server-protocol-3.17.0.3/lib/language_server/protocol/transport/io/reader.rb:20:in `read'
from /Users/jakeonrails/.asdf/installs/ruby/3.3.1/lib/ruby/gems/3.3.0/gems/ruby-lsp-0.23.3/lib/ruby_lsp/base_server.rb:46:in `start'
from /Users/jakeonrails/.asdf/installs/ruby/3.3.1/lib/ruby/gems/3.3.0/gems/ruby-lsp-0.23.3/exe/ruby-lsp:154:in `<top (required)>'
from /Users/jakeonrails/.asdf/installs/ruby/3.3.1/bin/ruby-lsp:25:in `load'
from /Users/jakeonrails/.asdf/installs/ruby/3.3.1/bin/ruby-lsp:25:in `<top (required)>'
from /Users/jakeonrails/.asdf/installs/ruby/3.3.1/lib/ruby/gems/3.3.0/gems/bundler-2.5.23/lib/bundler/cli/exec.rb:58:in `load'
from /Users/jakeonrails/.asdf/installs/ruby/3.3.1/lib/ruby/gems/3.3.0/gems/bundler-2.5.23/lib/bundler/cli/exec.rb:58:in `kernel_load'
from /Users/jakeonrails/.asdf/installs/ruby/3.3.1/lib/ruby/gems/3.3.0/gems/bundler-2.5.23/lib/bundler/cli/exec.rb:23:in `run'
from /Users/jakeonrails/.asdf/installs/ruby/3.3.1/lib/ruby/gems/3.3.0/gems/bundler-2.5.23/lib/bundler/cli.rb:456:in `exec'
from /Users/jakeonrails/.asdf/installs/ruby/3.3.1/lib/ruby/gems/3.3.0/gems/bundler-2.5.23/lib/bundler/vendor/thor/lib/thor/command.rb:28:in `run'
from /Users/jakeonrails/.asdf/installs/ruby/3.3.1/lib/ruby/gems/3.3.0/gems/bundler-2.5.23/lib/bundler/vendor/thor/lib/thor/invocation.rb:127:in `invoke_command'
from /Users/jakeonrails/.asdf/installs/ruby/3.3.1/lib/ruby/gems/3.3.0/gems/bundler-2.5.23/lib/bundler/vendor/thor/lib/thor.rb:527:in `dispatch'
from /Users/jakeonrails/.asdf/installs/ruby/3.3.1/lib/ruby/gems/3.3.0/gems/bundler-2.5.23/lib/bundler/cli.rb:35:in `dispatch'
from /Users/jakeonrails/.asdf/installs/ruby/3.3.1/lib/ruby/gems/3.3.0/gems/bundler-2.5.23/lib/bundler/vendor/thor/lib/thor/base.rb:584:in `start'
from /Users/jakeonrails/.asdf/installs/ruby/3.3.1/lib/ruby/gems/3.3.0/gems/bundler-2.5.23/lib/bundler/cli.rb:29:in `start'
from /Users/jakeonrails/.asdf/installs/ruby/3.3.1/lib/ruby/gems/3.3.0/gems/bundler-2.5.23/exe/bundle:28:in `block in <top (required)>'
from /Users/jakeonrails/.asdf/installs/ruby/3.3.1/lib/ruby/gems/3.3.0/gems/bundler-2.5.23/lib/bundler/friendly_errors.rb:117:in `with_friendly_errors'
from /Users/jakeonrails/.asdf/installs/ruby/3.3.1/lib/ruby/gems/3.3.0/gems/bundler-2.5.23/exe/bundle:20:in `<top (required)>'
from /Users/jakeonrails/.asdf/installs/ruby/3.3.1/bin/bundle:25:in `load'
from /Users/jakeonrails/.asdf/installs/ruby/3.3.1/bin/bundle:25:in `<main>'
2025-01-09 14:25:12.653 [info] (my-project-name) Shutting down Ruby LSP...
2025-01-09 14:25:12.701 [info] (my-project-name) [Error - 2:25:12 PM] Server process exited with code 1.
2025-01-09 14:25:12.701 [info] (my-project-name) [Error - 2:25:12 PM] Connection to server got closed. Server will not be restarted.
2025-01-09 14:25:12.701 [info] (my-project-name) [Error - 2:25:12 PM] Stopping server failed
2025-01-09 14:25:12.701 [info] (my-project-name) Message: Pending response rejected since connection got disposed
Code: -32097
2025-01-09 14:25:12.701 [error] (my-project-name) Error restarting the server: Pending response rejected since connection got disposed
Note:
I am also running Guard with the plugin to run bundler on Gemfile changes. What I noticed is it seems that if guard-bundler updates the Gemfile.lock or if I manually run bundler, it triggers the above failure.
The text was updated successfully, but these errors were encountered:
jakeonrails
added
bug
Something isn't working
vscode
This pull request should be included in the VS Code extension's release notes
labels
Jan 9, 2025
Description
Ruby LSP Information
VS Code Version
1.96.2
Ruby LSP Extension Version
0.8.17
Ruby LSP Server Version
0.23.3
Ruby LSP Add-ons
Ruby Version
3.3.1
Ruby Version Manager
asdf
Installed Extensions
Click to expand
Ruby LSP Settings
Click to expand
Workspace
User
Reproduction steps
Whenever I change my Gemfile (add/remove a gem), I see the error popup:
Warning
Connection to server got closed. Server will not be restarted.
Code snippet or error message
Note:
I am also running Guard with the plugin to run bundler on Gemfile changes. What I noticed is it seems that if
guard-bundler
updates theGemfile.lock
or if I manually run bundler, it triggers the above failure.The text was updated successfully, but these errors were encountered: