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

"go to the definition" does not find method definition #746

Closed
MathieuDerelle opened this issue Jun 18, 2021 · 3 comments
Closed

"go to the definition" does not find method definition #746

MathieuDerelle opened this issue Jun 18, 2021 · 3 comments
Labels

Comments

@MathieuDerelle
Copy link

MathieuDerelle commented Jun 18, 2021

Your environment

  • vscode-ruby version: v0.28.1
  • Ruby version: 2.4.10
  • Ruby version manager (if any): rvm
  • VS Code version: 1.57.0
  • Operating System: macOS Catalina 10.15.7 (Darwin x64 19.6.0)
  • Using language server? no

Expected behavior

# app/asynctasks/check_pending_collections.rb

    deadends = []
    UserCollection
      .uncompleted
      .includes(:collected_items, collection: :collection_items)
      .find_each do |uc|
        deadends << uc if uc.all_pieces_collected?
      end

cmd+clic on all_pieces_collected? should go to the definition of the method (or show all the definitions)

Actual behavior

The method definition is not found
image

but it's defined in a concern

# app/models/concerns/user_collections/completion.rb

    def all_pieces_collected?
      collected_item_ids.uniq.sort == collection.collection_item_ids.sort
    end

That's a big repo, is it possible that the files indexed are limited by the size of the repo ?
I've got other projects where "go to definitions" finds all the definitions for a given method name, list them all and let's me choose between them

@MathieuDerelle
Copy link
Author

I've found those issues

and I can confirm I have "ruby.intellisense": "rubyLocate",

@github-actions
Copy link

This issue has not had activity for 30 days. It will be automatically closed in 7 days.

@MathieuDerelle
Copy link
Author

still happening

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

No branches or pull requests

1 participant