-
Notifications
You must be signed in to change notification settings - Fork 145
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
(CAT-2113) Adjusting minimum ruby version required #481
Conversation
Following investigation on an issue that prevented puppet-resource_api from consuming latest puppetlabs_spec_helper, it was noted that this repository assumes Ruby 2.7 as the minimum required version, causing some repositories to fail their testing environment builds due to the fact that they are consuming some form of Ruby 2.6 in order to test properly against puppetserver. This commit adjusts the required Ruby version to the standard used across other modules/tools of the ecosystem.
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #481 +/- ##
=======================================
Coverage 43.95% 43.95%
=======================================
Files 10 10
Lines 662 662
=======================================
Hits 291 291
Misses 371 371 ☔ View full report in Codecov by Sentry. |
Why does the resource API still need to support Ruby 2.6 but also latest puppetlabs_spec_helper? |
# Offense count: 1 | ||
# Configuration parameters: Severity, Include. | ||
# Include: **/*.gemspec | ||
Gemspec/RequiredRubyVersion: | ||
Exclude: | ||
- 'puppetlabs_spec_helper.gemspec' |
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.
I'd consider this poor practice. You are telling RuboCop to assume you can use Ruby 2.7 features while being Ruby 2.6 compatible. It's just a matter of time before that breaks IMHO.
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.
Yes. I think the resource-api needs to drop Ruby 2.6 support
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.
I think you misunderstood the issue. IIRC the real issue is that JRuby used in Puppetserver 7 is officially only Ruby 2.6 compatible so I'm guessing some of Perforce's internal CI jobs run with Ruby 2.6.
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.
Yes. But that's EoL in three days: https://www.puppet.com/products/puppet-enterprise/support-lifecycle. So why does resource-api now need to use latest puppetlabs_spec_helper + Ruby 2.6?
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.
That's something I can't answer.
@bastelfreak @ekohl So my idea was to release one last minor version compatible with 2.6 before major changes happen once Puppet 7 is EOL (a "just in case someone needs it" scenario). After chatting with my team, we agreed it makes sense to just wait until P7 EOL and just remove the unsupported Ruby testing. So I'll be closing down this PR. |
Following investigation on an issue that prevented puppet-resource_api from consuming latest puppetlabs_spec_helper, it was noted that this repository assumes Ruby 2.7 as the minimum required version, causing some repositories to fail their testing environment builds due to the fact that they are consuming some form of Ruby 2.6 in order to test properly against puppetserver.
This commit adjusts the required Ruby version to the standard used across other modules/tools of the ecosystem.