Open gdelhumeau opened 11 months ago
Same as #620 and #618.
According to https://github.com/puppetlabs/puppetlabs-vcsrepo/pull/601 - Puppet 6 support is dropped, i had same issue - fixed by upgrading the agent to 7.x
I'm getting a similar error on an AlmaLinux 8 host running puppetserver 7.6.
Error: Could not retrieve catalog from remote server: Error 500 on SERVER: Server Error: Evaluation Error: Error while evaluating a Resource Statement, Evaluation Error: Error while evaluating a Type-Name, Could not autoload puppet/type/vcsrepo: Could not autoload puppet/provider/vcsrepo/cvs: /etc/puppetlabs/code/modules/vcsrepo/lib/puppet/provider/vcsrepo/cvs.rb:77: syntax error, unexpected '{ arg'
@rev = contents[1..]
^ (file: /etc/puppetlabs/code/local_environments/production/modules/custom/manifests/repo.pp, line: 110, column: 60) (file: /etc/puppetlabs/code/local_environments/production/modules/<redacted>, line: 43) on node <redacted>
The strange thing is that this happens only on the first catalog compilation that uses vcsrepo after a restart. Subsequent compilations that use vcsrepo (for either the same client or for other clients) are fine. Compilations of catalogs without vcsrepo have no effect either way.
This is running puppetserver from a puppetlabs RPM, so It should be using the vendored ruby (and jruby).
$ rpm -qa puppetserver
puppetserver-7.6.0-1.el8.noarch
For what it's worth, the system ruby is new enough as well:
$ ruby --version
ruby 2.5.9p229 (2021-04-05 revision 67939) [x86_64-linux]
I don't think this is the same bug as originally reported, but it's caused by the same commit: https://github.com/puppetlabs/puppetlabs-vcsrepo/commit/f91d02d41315f831b12fe24da9a038034e326457 Reverting that commit makes the problem go away.
I'm not currently in a position to try a newer puppetserver, but I wanted to write this issue down somewhere, for now.
@bugfood that might be fixed by doing a puppet generate types
or restarting puppetserver.
@bugfood that might be fixed by doing a
puppet generate types
or restarting puppetserver.
Thanks, but this problem manifests immediately after a restart of puppetserver--and then goes away after the first time it happens.
I don't know about puppet generate types
. I've never run this before, but it seems to have something to do with environment isolation, which we don't use.
https://www.puppet.com/docs/puppet/7/environment_isolation.html#env_generate_types
According to #601 - Puppet 6 support is dropped, i had same issue - fixed by upgrading the agent to 7.x
This was also the fix for me.
As an enhancement, I urge that this line (77) which fails with puppet6 on the agent (not the puppetserver, as suggested above, and which for my own environment had previously been upgraded to 7), be wrapped in a try...catch which links to this thread and advises an upgrade of puppet on the client.
Describe the Bug
I cannot clone a repository.
Expected Behavior
It should clone the repository.
Steps to Reproduce
This is my manifest:
I get the following error, when I execute
/opt/puppetlabs/puppet/bin/puppet agent -t
on the agent:Environment (on the agent)
Environment (on the server)