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

pin FFI to < 1.17 for Ruby 2.7 #387

Merged
merged 1 commit into from
Nov 12, 2024
Merged

pin FFI to < 1.17 for Ruby 2.7 #387

merged 1 commit into from
Nov 12, 2024

Conversation

evgeni
Copy link
Member

@evgeni evgeni commented Nov 12, 2024

FFI 1.17 needs rubygems 3.3.22+, which is Ruby 3.0+ only

FFI 1.17 needs rubygems 3.3.22+, which is Ruby 3.0+ only
@@ -4,6 +4,9 @@ gemspec

gem 'gettext', '>= 3.1.3', '< 4.0.0'

# FFI 1.17 needs rubygems 3.3.22+, which is Ruby 3.0+ only
gem "ffi", "<1.17" if RUBY_VERSION < '3.0'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't we rather use:

Suggested change
gem "ffi", "<1.17" if RUBY_VERSION < '3.0'
gem "ffi", "<1.17" if Gem::Version.new(RUBY_VERSION) < Gem::Version.new('3.0')

?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Technically, maybe.
But we've used the exact same notation in other places (https://github.com/theforeman/foreman/blob/develop/Gemfile#L55) and it works fine.

Copy link
Member

@ofedoren ofedoren left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, @evgeni, if it works fine in Foreman then fine by me :)

@ofedoren ofedoren merged commit 63d8232 into master Nov 12, 2024
9 checks passed
@evgeni evgeni deleted the pin-ffi branch November 12, 2024 13:43
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.

2 participants