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

Adding new method definition does not add the method to the symbol list #398

Closed
peret opened this issue Oct 23, 2018 · 0 comments
Closed

Comments

@peret
Copy link
Contributor

peret commented Oct 23, 2018

Your environment

  • vscode-ruby version: 0.20.0
  • Ruby version: 2.3.3
  • Ruby version manager (if any): RVM
  • VS Code version: 1.28.2
  • Operating System: Mac OS X
  • Using language server? No

Expected behavior

When I add a new method in one of my Ruby files and save the file, the new method's name should be available in the symbols list.

Actual behavior

This works for a while after starting VS Code but then stops working entirely. I.e. new methods don't appear in the symbols list AND the locations of other methods aren't updated, so jumping to the existing symbols is off by a few lines, depending on how much code was added.

I already debugged this issue and the problem is that the parseQueue in locate.js never clears items (it doesn't call the async-callback) and therefore becomes saturated and never executes later tasks. The fix is to just call the callback, I'll provide a PR.

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

No branches or pull requests

1 participant