question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Doesn't work on WSL2

See original GitHub issue

On WSL2 with rvm, rubocop fails to start with the following error:

/home/andrew/.rvm/rubies/ruby-2.6.3/lib/ruby/site_ruby/2.6.0/rubygems.rb:284: in `find_spec_for_exe': can't find gem rubocop (>= 0.a) with executable rubocop (Gem::GemNotFoundException) from /home/andrew/.rvm/rubies/ruby-2.6.3/lib/ruby/site_ruby/2.6.0/rubygems.rb:303:in `activate_bin_path' from /home/andrew/.rvm/gems/ruby-2.6.3@senitron/bin/rubocop:23:in `<main>'

using path:

"ruby.rubocop.executePath": "/home/andrew/.rvm/gems/ruby-2.6.3@senitron/bin/"

Issue Analytics

  • State:open
  • Created 4 years ago
  • Comments:8

github_iconTop GitHub Comments

1reaction
sharq1commented, Jul 27, 2020

Still doesn’t work for me - neither standalone or using solargraph. It doesn’t show any execution errors (nothing in problems / output tabs) in VS code but doesn’t highlight any code either. Using rbenv and tweaked execute path to /home/sharq/.rbenv/shims/. Tried toggling use bundler option but the result is the same.

Edit: Just managed to get it work using just the Ruby extension 🎉 🎉 🎉 I have this config now:

  "ruby.rubocop.useBundler": true,
  "ruby.lint": {
    "rubocop": {
      "useBundler": true // enable rubocop via bundler
    }
  },
1reaction
CharlieIGGcommented, Apr 22, 2020

Thanks @rajdeep26 !

Read more comments on GitHub >

github_iconTop Results From Across the Web

Troubleshooting Windows Subsystem for Linux | Microsoft Learn
This is likely because your machine has not yet taken the backport for WSL 2. The simplest way to resolve this is by...
Read more >
WSL2 terminal won't start · Issue #5912 · microsoft/WSL - GitHub
the new Terminal > Ctrl + , > Ubuntu > Disable Use parent process directory . Open VScode > search for official extension...
Read more >
How to Install WSL 2 on Windows 10 (Updated) - OMG! Ubuntu!
Once done you can open the 'Ubuntu' app from the Start Menu to get started, or install the Microsoft Terminal app to start...
Read more >
Fix Windows Subsystem for Linux Errors, Problems and Issues
This post covers all Windows Subsystem for Linux (WSL2) Error Messages and Codes and how to troubleshoot Errors, Problems and Issues.
Read more >
WSL2 is installed but won't launch - Super User
If you installed WSL purely for Docker, then you likely have no "user" distribution installed. Go to PowerShell and run: wsl -l -v....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found