Skip to content

Upgrade magnus and rb-sys for Ruby 4.0 support#16

Merged
cpetersen merged 2 commits intomainfrom
ruby-4
Mar 24, 2026
Merged

Upgrade magnus and rb-sys for Ruby 4.0 support#16
cpetersen merged 2 commits intomainfrom
ruby-4

Conversation

@cpetersen
Copy link
Copy Markdown
Member

Summary

  • Upgrade magnus from 0.6 to 0.8 and rb-sys from 0.9.117 to 0.9.124 to support Ruby 4.0
  • Migrate all Rust source files from deprecated magnus 0.6 APIs to the new Ruby-handle-based 0.8 APIs
  • Zero deprecation warnings, 458/459 tests pass (1 pre-existing failure from benchmark gem removed from Ruby 4 stdlib)

Test plan

  • cargo check passes with zero warnings
  • bundle exec rake compile succeeds on Ruby 4.0.1
  • bundle exec rspec — 458 pass, 1 pre-existing failure unrelated to this change

🤖 Generated with Claude Code

cpetersen and others added 2 commits March 23, 2026 13:59
rb-sys 0.9.117 did not support Ruby 4.0's C API changes, causing
"Failed to setup stable API" during native extension compilation.

- Update magnus from 0.6 to 0.8 in Cargo.toml
- Update rb-sys from 0.9.117 to 0.9.124 in Cargo.lock
- Migrate all Rust source files from deprecated magnus 0.6 APIs to
  the new Ruby-handle-based 0.8 APIs (Ruby::get().unwrap() pattern)
- Zero deprecation warnings

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@cpetersen cpetersen merged commit 77c931e into main Mar 24, 2026
1 check passed
@cpetersen cpetersen deleted the ruby-4 branch March 24, 2026 01:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant