-
-
Notifications
You must be signed in to change notification settings - Fork 132
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
Incompatability with ruby 3.1.0 #325
Comments
It's also not compatible with Ruby 3.0: #326 |
Although there are ways to work around this, making this compatible with Ruby 3.0+ will be helpful as some Linux distributions have moved to Ruby 3.x and no longer maintain Ruby 2.x packages. |
I totally agree. I currentl do not have a lot of time. Are you able to provide a PR for this? |
Unfortunately not at this time. If that changes, I will let you know.
…On Sun, Feb 6, 2022 at 3:52 PM Tim Meusel ***@***.***> wrote:
I totally agree. I currentl do not have a lot of time. Are you able to
provide a PR for this?
—
Reply to this email directly, view it on GitHub
<#325 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ABSS7YKH64BGK5CNZD2J3R3UZ3NRFANCNFSM5MMZBBNQ>
.
Triage notifications on the go with GitHub Mobile for iOS
<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675>
or Android
<https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub>.
You are receiving this because you commented.Message ID:
***@***.***>
|
The build failure there is because Puppet 6 is not ruby 3.0 compatible. Perhaps it passes with 7 though? |
I'm really not a Ruby programmer, nor do I have a desire to become one, but given the clues in rubygems/rubygems#5235 (comment) I was able to get eyaml working on Ubuntu 22.04 (not yet released) with Ruby 3.0.2p107 with this simple change:
I hope someone with real Ruby knowledge can take on from here and make a proper PR. I'm sure there are backwards compatibility issues to handle here. |
Chiming in from a FreeBSD perspective, hiera-eyaml still uses ruby 2.7, but the recently updated ruby27-gems sits at 3.3.7 causing a similar breakage (Bug 262351 - sysutils/rubygem-hiera-eyaml: broken)
I made a crude patch but I’m not sure about which version of rubygems (gem::VERSION) introduced the regression. It is similar to @fredrikt ‘s one, but tries to be a bit more forward/backwards compatible with regards to different ruby/rubygem versions. It also follows a similar pattern seen some lines above this patch. --- /usr/local/lib/ruby/gems/2.7/gems/hiera-eyaml-3.2.2/lib/hiera/backend/eyaml/plugins.rb.orig 2022-03-30 19:25:36.581974000 +0200
+++ /usr/local/lib/ruby/gems/2.7/gems/hiera-eyaml-3.2.2/lib/hiera/backend/eyaml/plugins.rb 2022-03-30 19:30:40.726838000 +0200
@@ -33,6 +33,7 @@
specs.each do |spec|
next if @@plugins.include? spec
+ spec = Gem::VERSION >= "3.3.7" ? spec.to_spec() : spec
dependency = spec.dependencies.find { |d| d.name == "hiera-eyaml" }
next if dependency && !dependency.requirement.satisfied_by?( this_version ) Would this be the preferred way to fix this? Best regards, |
I tried to install hiera-eyaml on my M1 Mac and got the following error using ruby 3.1.0:
Switching back to ruby 2.7.5. resolved the issue for me.
The text was updated successfully, but these errors were encountered: