Skip to content
This repository has been archived by the owner on Jul 31, 2023. It is now read-only.

Intellisense not working #120

Closed
sepehr500 opened this issue Feb 14, 2017 · 18 comments
Closed

Intellisense not working #120

sepehr500 opened this issue Feb 14, 2017 · 18 comments
Labels
autocomplete question Question about project

Comments

@sepehr500
Copy link

Your environment

vscode-ruby version:
Ruby version: ruby 2.3.1
VS Code version: 1.9
Operating System: Ubuntu 16.04
Expected behavior

Hitting Ctrl+Space after ``[1,2,3].e` should bring up Intellisense

Actual behavior

Nothing happens, just the basic word suggestion appears.

Steps to reproduce the problem

``[1,2,3].e` should bring up Intellisense, but only brings up standard auto complete

@wagenet
Copy link

wagenet commented Feb 15, 2017

I'm having this issue as well.

@raldred
Copy link

raldred commented Feb 16, 2017

Same on OSX.
Linters work fine, just missing autocomplete.
I have rcodetools installed.

VScode 1.9.1 (f9d0c687ff2ea7aabd85fb9a43129117c0ecf519)
Ruby Ext: 0.10.4
Ruby 2.4.0

@HookyQR
Copy link
Contributor

HookyQR commented Feb 17, 2017

rcodetools is somewhat iffy. Install methods can be an issue too. Have you installed it with bundler? Are you using a ruby version manager?

You can add the (fully qualified) command path if you're having problems: "ruby.rctComplete.commandPath": "/path/to/rct-complete" in your VS Code settings Cmd + ,

@sepehr500
Copy link
Author

How do I find where my rctComplete in installed?

@raldred
Copy link

raldred commented Feb 17, 2017

@sepehr500 which rctComplete

@HookyQR I use RVM, ruby 2.4.0 is my --default ruby and definitely has rcodetools installed
I installed it using the Integrated Terminal

"ruby.rctComplete.commandPath": "/Users/robaldred/.rvm/gems/ruby-2.4.0/bin/rct-complete"

Not seeing any errors or logging, is there any other manual way I can check or help debug?

@ivcosla
Copy link

ivcosla commented Mar 24, 2017

@raldred I found that rct-complete asked me for a ruby interpreter I didn't have (/usr/local/bin/ruby18). I just created a symbolic link between my interpreter and the one that rct-complete asked me for:

sudo ln -s /usr/bin/ruby /usr/local/bin/ruby18

I think it would be better to have the interpreter for ruby18, im just linking my ruby2.3, but my intellisense is working now. By the way, I can't tell if it is fully working or not.

edit: It seems that you can tell rct-complete to use another interpreter just by telling it with -S your_interpreter flag.

@rebornix rebornix added the question Question about project label Apr 17, 2017
@jgroeneveld
Copy link

i have the same issue. sometimes it works kinda outside of functions but as soon as the file contains code that is project related (so non standard lib constants) i have a uninitialized constant error. do i need to configure the workspace or something?

@rvong
Copy link

rvong commented Oct 25, 2017

Still doesn't work.

@raldred
Copy link

raldred commented Oct 26, 2017

I have moved to using solargraph
https://github.com/castwide/vscode-solargraph

@alexishida
Copy link

+1

@basicBrogrammer
Copy link

image

This is what happens for me.

@AndrewKiri
Copy link

AndrewKiri commented Dec 28, 2017

+1, intellisense didn't show up for string methods.
Steps to reproduce: create variable with any string value. Try to type somevar., whereas after typing dot the intellisense should be invoked.

  • macOS High Sierra 10.13.2
  • VSCode 1.19.1
  • Ruby version 2.4.1

@castwide
Copy link
Contributor

castwide commented Feb 1, 2018

#248 should resolve this issue. It adds the Solargraph extension that @raldred mentioned as a dependency.

@yanivps
Copy link

yanivps commented Feb 9, 2018

Can someone guide please how to make this work if I am working on vscode installed on windows and my ruby is installed on WSL (Bash on Windows) ?
I think the problem is that extention is trying to run all commands in the context of the Windows OS and not the Linux, but ruby is not installed on windows.
I tried to workaround this with adding a folder to windows PATH and add .bat file per gem I have (including ruby, rct-complete and solargraph) and the content of the bat file was this:
@echo off
bash -c '~/.rbenv/shims/solargraph %*'
but unfortunately it didn't work.

@nascimento
Copy link

+1

@castwide
Copy link
Contributor

I commented on the WSL issue here: #100

@yanivps
Copy link

yanivps commented Feb 22, 2018

The only solution I can suggest you for now is to install Xming which enables you to run UI applications on WSL. Then you can install vscode on your Ubuntu on Windows and run it (use this thread for instructions)
For this to succeed, you will have to update Windows 10 to 17063 build which is not official yet so you will have to enable Windows insider program and update

I chose not to perform this update through Windows insider program and wait for the next official Windows 10 update which should include this build (Per microsoft it should come in April)

@wingrunr21
Copy link
Collaborator

Closing for issue cleanup. Apologies if this is still an issue. We are working to improve the core extension experience.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
autocomplete question Question about project
Projects
None yet
Development

No branches or pull requests