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

Fixes #37145 - Ruby 3 support #10885

Merged
merged 1 commit into from
Feb 14, 2024
Merged

Fixes #37145 - Ruby 3 support #10885

merged 1 commit into from
Feb 14, 2024

Conversation

ofedoren
Copy link
Contributor

@ofedoren ofedoren commented Feb 9, 2024

What are the changes introduced in this pull request?

This is a POC as an alternative to #10861.

Considerations taken when implementing this change?

This PR tries to make Katello work on Ruby 3 with minimal changes in Katello, foreman-tasks and Dynflow.

Requires only theforeman/foreman-tasks#743 for now.

What are the testing steps for this pull request?

Run CI and hope for the best.

@@ -49,7 +49,7 @@ Gem::Specification.new do |gem|

# Pulp
gem.add_dependency "anemone"

gem.add_dependency "webrick"
Copy link
Member

Choose a reason for hiding this comment

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

In running a test build on EL9/Ruby 3, (https://download.copr.fedorainfracloud.org/results/@theforeman/katello-nightly-staging-scratch-73818885-106f-5885-9ea9-0a7072eddbe2/rhel-9-x86_64/07004419-rubygem-katello/builder-live.log.gz), I saw this error and wondered if that is what is being fixed here?

+ /usr/bin/rake 'plugin:assets:precompile[katello]' RAILS_ENV=production DATABASE_URL=nulldb://nohost --trace
Log file /builddir/build/BUILD/katello-4.12.0.pre.master/usr/share/foreman/log/production.log cannot be opened. Falling back to STDOUT
Gem loading error: cannot load such file -- webrick/cookie

Copy link
Member

Choose a reason for hiding this comment

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

I propose to get rid of anemone: https://projects.theforeman.org/issues/37159

Copy link
Member

Choose a reason for hiding this comment

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

If we merge this, perhaps add a note above it why we need it?

@ofedoren ofedoren force-pushed the ruby3-min branch 3 times, most recently from 4bcb9de to 15866fb Compare February 12, 2024 12:33
@ofedoren ofedoren changed the title Ruby 3 minimal changes Fixes #37145 - Ruby 3 support Feb 12, 2024
@ofedoren ofedoren marked this pull request as ready for review February 12, 2024 14:29
katello.gemspec Outdated
@@ -13,7 +13,7 @@ Gem::Specification.new do |gem|
gem.homepage = "http://www.katello.org"
gem.summary = "Content and Subscription Management plugin for Foreman"
gem.description = "Katello adds Content and Subscription Management to Foreman. For this it relies on Candlepin and Pulp."
gem.required_ruby_version = '~> 2.5'
gem.required_ruby_version = '>= 2.7'
Copy link
Member

Choose a reason for hiding this comment

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

Should this get an upper bound? In https://github.com/Katello/katello/pull/10861/files#diff-21cb8426e694930953a1fb66d2f1e4c0c4021bcadd760d9582423094a4dcaaceR16 you specificed < 3.1, in other plugins we used < 4.

@evgeni
Copy link
Member

evgeni commented Feb 14, 2024

An EL9 box with this PR and theforeman/foreman-tasks#743 applied (via packit) passes all bats tests \o/

@evgeni
Copy link
Member

evgeni commented Feb 14, 2024

/packit build

Copy link

Account evgeni has no write access nor is author of PR!

@jeremylenz
Copy link
Member

/packit build

@evgeni
Copy link
Member

evgeni commented Feb 14, 2024

super green fifth element

@jeremylenz jeremylenz merged commit 192800a into Katello:master Feb 14, 2024
15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants