ruby / ruby/rbs

RBS collection cannot load signature for default gem.

Open
#2,226 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Ruby
Stars
2.2k
Forks
256
Avg merge
6d 17h
Merged PRs (30d)
37

Description

ruby: v3.4.1
rbs: v3.8.1

prism v1.2.0 is bundled as default gem with ruby v3.4. link

But rbs collection cannot found it.

RBS::EnvironmentLoader.gem_sig_path('prism', '1.2.0')
#=> nil

Gem::Specification.find_by_name('prism', '1.2.0').gem_dir
#=> "/Users/yuki.kurihara/.rbenv/versions/3.4.1/lib/ruby/gems/3.4.0/gems/prism-1.2.0"

Dir[Gem::Specification.find_by_name('prism', '1.2.0').gem_dir + "/*"]
#=> []

Even if the gem directory can be found, the sig directory is not synchronised by default gem and cannot be consulted.

https://github.com/ruby/ruby/blob/48d4efcb85000e1ebae42004e963b5d0cedddcf2/tool/sync_default_gems.rb#L376-L398

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with RBS::EnvironmentLoader.gem_sig_path('prism', '1.2.0') and inspect Ruby's tool/sync_default_gems.rb around the referenced lines. Reproduce the missing signature lookup with Ruby 3.4.1, then ensure signatures from the bundled prism default gem are synchronized and discoverable by RBS collection.

Written by the indexing model from the issue text.

Assessment

Tech stack
ruby
Domain
tooling
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.