-
Notifications
You must be signed in to change notification settings - Fork 47
RBS setup #469
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
f584d28 to
b8baf4c
Compare
| with: | ||
| ruby-version: ${{ matrix.ruby }} | ||
| - uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # v4.2.3 | ||
| bundler-cache: true |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this line will do the following, so the lines below were removed
- Installs bundler
- Runs bundle install
- Caches the gems in vendor/bundle
|
I ran into some issues that might be related to switching to the nix based dev environment:
-> I temporarily added this to the gemspec which fixed the warning
-> I couldn't get this to work. I tried bumping the version of I'd love for this to work with the modernized dev env - let's pair on this after the break, |
|
Warning 2: FFI instance or class type error This is a bug in the ffi gem's bundled RBS files, not your project. Looking at your lock file, ffi is sourced directly from rubygems (type: rubygems), meaning RBS reads the .rbs files shipped with the gem itself. The ffi gem version 1.17.2 has invalid RBS syntax in its sig/ffi/struct.rbs file. Options to fix:
updating the gem fixed the issue |
The .gem_rbs_collection directory contains auto-generated RBS type signatures installed via `rbs collection install`. These files should not be committed as they are environment-specific and can be regenerated. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
In your rbs_collection.yaml, you've listed forwardable as a gem:
gems:
- name: forwardable
But forwardable is a Ruby standard library, not a gem. RBS correctly resolves it as type: stdlib in the lock file (line 176-179), but the warning occurs because RBS first tries to find it in Gemfile.lock as a gem before falling back to stdlib.
Fix: Remove forwardable from the gems list - it's automatically available as part of stdlib:
gems:
- name: bigdecimal
# Remove forwardable - it's stdlib, not a gem
Only adds
.rbsfiles to prevent editing source code. This is the best practice for gemsrake rbs:validaterake rbs:listrbs collection install(when a new gem is installed)This PR adds automatic RBS checks when running either
dev testorCI