Skip to content
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

Fix compiling in ruby 3.0 #3

Merged
merged 2 commits into from
Mar 28, 2023
Merged

Fix compiling in ruby 3.0 #3

merged 2 commits into from
Mar 28, 2023

Conversation

IAPark
Copy link
Owner

@IAPark IAPark commented Mar 28, 2023

Fixes #1 which highlighted that builds are failing in Ruby 3.0. I think this was because while this project started with rb_sys I'd briefly experimented with the native rust extension support available in Ruby 3.1+. While it worked I did end up switching back, but it looks like I never switched the gemspec file back.

@IAPark
Copy link
Owner Author

IAPark commented Mar 28, 2023

@petergoldstein if you have a sec to see if this seems right to you I'd appreciate it

@IAPark IAPark marked this pull request as ready for review March 28, 2023 04:03
@petergoldstein
Copy link
Contributor

@IAPark Do you need to update the README as well?

@petergoldstein
Copy link
Contributor

I'm honestly not sure. Looking at @ankane 's tokenizers-ruby, I'm not sure the switch from compile to build is actually needed. The gemspec change looks correct though.

@IAPark
Copy link
Owner Author

IAPark commented Mar 28, 2023

I think build should just add packaging the gem into a .gem file so it does sound right that it isn't actually needed to run specs or to test in development, but I think I prefer having having the CI fail in the situation where the gemspec was messed up like it was here

@IAPark IAPark merged commit 1cdb0ed into main Mar 28, 2023
@IAPark IAPark deleted the fix-ruby-3.0.0-support branch March 28, 2023 07:29
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.

Can't compile on Ruby 3.0: No builder for extension 'ext/tiktoken_ruby/Cargo.toml'
2 participants