Bug 1815115 - Puppet agent does not run on Fedora 32 beta due to upgrade to Ruby 2.7
Summary: Puppet agent does not run on Fedora 32 beta due to upgrade to Ruby 2.7
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: puppet
Version: 32
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
Assignee: Terje Røsten
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2020-03-19 14:13 UTC by Michael Watters
Modified: 2020-06-24 20:43 UTC (History)
8 users (show)

Fixed In Version: puppet-5.5.20-1.fc30 puppet-5.5.20-1.fc32 puppet-5.5.20-1.fc31
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2020-05-11 03:15:44 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)
Screenshot of puppet agent error. (19.48 KB, image/png)
2020-03-19 14:13 UTC, Michael Watters
no flags Details


Links
System ID Private Priority Status Summary Last Updated
PuppetLabs PUP-10247 0 None None None 2020-04-30 14:29:02 UTC

Description Michael Watters 2020-03-19 14:13:12 UTC
Created attachment 1671462 [details]
Screenshot of puppet agent error.

Description of problem:

Puppet agent will not run.  Running puppet agent -t results in an error as shown below.

/usr/share/ruby/vendor_ruby/puppet/util.rb:461: warning: URI.escape is obsolete
cannot load such file -- sync


Version-Release number of selected component (if applicable):

/usr/share/ruby/vendor_ruby/puppet/util.rb:461: warning: URI.escape is obsolete
cannot load such file -- sync

How reproducible:

This happens every time the agent is ran.

Steps to Reproduce:

dnf install puppet

Run the agent.

Comment 1 Michael Watters 2020-03-19 14:14:16 UTC
Here is the rpm package info.

[root@mdct-dev27-f32 ~]# rpm -qi puppet
Name        : puppet
Version     : 5.5.18
Release     : 1.fc32
Architecture: noarch
Install Date: Thu 19 Mar 2020 10:01:02 AM EDT
Group       : Unspecified
Size        : 1743
License     : ASL 2.0
Signature   : RSA/SHA256, Wed 05 Feb 2020 01:36:38 PM EST, Key ID 6c13026d12c944d0
Source RPM  : puppet-5.5.18-1.fc32.src.rpm
Build Date  : Wed 05 Feb 2020 01:36:09 PM EST
Build Host  : buildvm-armv7-20.arm.fedoraproject.org
Packager    : Fedora Project
Vendor      : Fedora Project
URL         : http://puppetlabs.com
Bug URL     : https://bugz.fedoraproject.org/puppet
Summary     : A network tool for managing many disparate systems
Description :
Puppet lets you centrally manage every important aspect of your system using a
cross-platform specification language that manages all the separate elements
normally aggregated in different files, like users, cron jobs, and hosts,
along with obviously discrete elements like packages, services, and files.

Comment 2 Terje Røsten 2020-03-19 15:33:34 UTC
puppet is borken after Ruby 2.7 update:

 https://fedoraproject.org/wiki/Changes/Ruby_2.7

Upstream tracker:

 https://tickets.puppetlabs.com/browse/PUP-10247
  
 Support ruby 2.7
 

puppet specs fail on ruby 2.7.0 because:

    sync was extracted into a different gem. But we don't actually need that code, so remove the require 'sync' statements.
    scanf was extracted into a different gem. We need to add a runtime dependency on that gem ~> 1.0 to puppet's .gemspec. We will need to update a few other projects first (puppetserver, r10k, etc) first.
    There many ruby deprecation warnings due to keyword argument vs positional argument handling. See https://www.ruby-lang.org/en/news/2019/12/12/separation-of-positional-and-keyword-arguments-in-ruby-3-0/

Comment 3 Michael Watters 2020-03-19 16:05:37 UTC
One thing to note is that the puppet-agent package yum.puppetlabs.com does work since it includes its own ruby environment.  I was able to get puppet running by installing the puppet-release-fedora-31 and puppet-agent packages from that site.

Comment 4 Terje Røsten 2020-03-19 18:19:57 UTC
Indeed, puppetlabs package includes "everything" and has very few deps, make sense for a bootstrap tool as puppet,
however fedora package should also work at some point.

Comment 5 Ed Marshall 2020-04-29 00:47:48 UTC
So just FYI, Fedora 32 just shipped with Ruby 2.7 and a broken Puppet.

Comment 6 Breno 2020-04-29 13:38:41 UTC
FYI

I have a proposal to upgrade puppet to the 6th version and afaik, apparently, it does support ruby > 2.3.0 [1].
There's a working testing environment that seems stable by now [2]. The only thing holding me back now is the review of 3 new rubygem packages [3, 4, 5] required by puppet.
After those packages are included, I will be able to ask the review of a new package, puppetserver. All the packages and their spec are in the aforementioned copr [2] repository.

Tbh, in the beginning, my main concern was EPEL 8.
After having puppet and puppetserver there, my next step would be to ask the community help to also maintain it for Fedora.
I say that because apparently I am the only maintainer current active in the puppet package, or the others don't bother responding emails.

If I can help somehow or if you guys think you can help me somehow, please let me know.

Thanks.

1 https://github.com/puppetlabs/puppet/blob/master/.gemspec
2 https://copr.fedorainfracloud.org/coprs/brandfbb/puppet6-stable-el8-fedora/builds/
3 https://bugzilla.redhat.com/show_bug.cgi?id=1811775
4 https://bugzilla.redhat.com/show_bug.cgi?id=1811774
5 https://bugzilla.redhat.com/show_bug.cgi?id=1811777

Comment 7 Breno 2020-04-29 14:02:01 UTC
Adding more information to the previous comment, https://puppet.com/docs/puppet/latest/about_agent.html#puppet-agent-component-version-numbers.
So I am not sure if puppet 6 would or would not work along with ruby 2.7.
It should, but puppetlabs seems to guarantee 2.5.

Comment 8 Terje Røsten 2020-04-29 20:26:01 UTC
puppet on ruby 2.7 status:

 https://tickets.puppetlabs.com/browse/PUP-10247

Comment 9 Ben Cotton 2020-04-30 14:29:02 UTC
(reverting status back to NEW. VERIFIED is generally for when a _fix_ is verified. Adding a link to the upstream tracker in the BZ metadata)

Comment 10 Fedora Update System 2020-05-02 11:08:13 UTC
FEDORA-2020-da25c6a4c9 has been submitted as an update to Fedora 32. https://bodhi.fedoraproject.org/updates/FEDORA-2020-da25c6a4c9

Comment 11 Fedora Update System 2020-05-02 11:08:14 UTC
FEDORA-2020-7998927f10 has been submitted as an update to Fedora 30. https://bodhi.fedoraproject.org/updates/FEDORA-2020-7998927f10

Comment 12 Fedora Update System 2020-05-02 11:08:15 UTC
FEDORA-2020-f54f6fd68c has been submitted as an update to Fedora 31. https://bodhi.fedoraproject.org/updates/FEDORA-2020-f54f6fd68c

Comment 13 Fedora Update System 2020-05-03 07:07:10 UTC
FEDORA-2020-f54f6fd68c has been pushed to the Fedora 31 testing repository.
In short time you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2020-f54f6fd68c`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2020-f54f6fd68c

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 14 Fedora Update System 2020-05-03 07:31:40 UTC
FEDORA-2020-da25c6a4c9 has been pushed to the Fedora 32 testing repository.
In short time you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2020-da25c6a4c9`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2020-da25c6a4c9

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 15 Fedora Update System 2020-05-03 07:50:37 UTC
FEDORA-2020-7998927f10 has been pushed to the Fedora 30 testing repository.
In short time you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --advisory=FEDORA-2020-7998927f10`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2020-7998927f10

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 16 Fedora Update System 2020-05-11 03:15:44 UTC
FEDORA-2020-7998927f10 has been pushed to the Fedora 30 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 17 Fedora Update System 2020-05-11 04:29:28 UTC
FEDORA-2020-da25c6a4c9 has been pushed to the Fedora 32 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 18 Fedora Update System 2020-05-11 06:08:25 UTC
FEDORA-2020-f54f6fd68c has been pushed to the Fedora 31 stable repository.
If problem still persists, please make note of it in this bug report.

Comment 19 Michael Watters 2020-05-11 14:29:36 UTC
The agent runs now however there are several warnings printed out on the console when applying the catalog.  For example:

```
/usr/share/ruby/vendor_ruby/puppet/util.rb:461: warning: URI.escape is obsolete
/usr/share/ruby/vendor_ruby/puppet/indirector/request.rb:283: warning: URI.unescape is obsolete
/usr/share/ruby/vendor_ruby/puppet/util.rb:461: warning: URI.escape is obsolete
/usr/share/ruby/vendor_ruby/puppet/util.rb:461: warning: URI.escape is obsolete
/usr/share/ruby/vendor_ruby/puppet/indirector/request.rb:283: warning: URI.unescape is obsolete
```

Is there any way to avoid this or would the issue need to be fixed upstream?

Comment 20 Terje Røsten 2020-05-12 05:39:12 UTC
Its no completely trivial way to fix this in pupppet it seems.

Comment 21 Michael Watters 2020-06-24 20:43:50 UTC
(In reply to Breno from comment #7)
> Adding more information to the previous comment,
> https://puppet.com/docs/puppet/latest/about_agent.html#puppet-agent-
> component-version-numbers.
> So I am not sure if puppet 6 would or would not work along with ruby 2.7.
> It should, but puppetlabs seems to guarantee 2.5.

Are there any plans to release an updated puppet package for Fedora 32?  The puppet code appears to have been fixed to work with ruby 2.7 in the upstream repos but we would need to have a new package built for the Fedora repos to take advantage of this.


Note You need to log in before you can comment on or make changes to this bug.