Initialize signature showing Object.new signature but not the specific class signature
Nobody has claimed this yet.
- Dominant language
- Ruby
- Stars
- 2k
- Forks
- 281
- Avg merge
- 2h 14m
- Merged PRs (30d)
- 6
Description
Description
Reproduction steps
- Create a class with an initialize method, give it no documentation.
- In another place, instantiate this class
- The signature help displays
class.rbshelp. It doesn't matter if the signature is different or no. - I would expect at least to see the signature.
This may be an issue with the neovim/lsp configuration, I'm wondering if other people see this too. I have seen this with my classes, but also with gems. The classes for the gems are loaded correctly, however when I try to instantiate it, I don't see the signature. Could be related to https://github.com/Shopify/ruby-lsp/pull/2553 ?
I've created a Dockerfile where you can see this happening. There are some annoying warnings, I need to update the Dockerfile.
curl -o Dockerfile https://gist.githubusercontent.com/dgmora/f869b0692db5fafdf6d43090ec9cb46f/raw/Dockerfile && \
docker build -t lazyvim-lsp . && \
docker run -it lazyvim-lsp
# `nvim` to start neovim
# inside:
# `<space>` to see available keymaps (and wait)
# `<space>e` to toggle filetree
# `a` to create a file in the file tree
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by using the linked Dockerfile to reproduce the signature-help behavior in Neovim, then inspect the reported relationship to ruby-lsp PR #2553. Compare instantiating a class with an undocumented initialize method against the displayed Object.new or class.rbs signature; done means signature help shows the specific class signature for local classes and gems.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- docker, neovim, ruby
- Domain
- developer-experience, tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100