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

Remove Puppet-debugger customisation #313

Closed
wants to merge 1 commit into from

Conversation

davidsandilands
Copy link
Member

This is no longer needed as the version has increased since it was added and will create an issue when updating to PDK 2.6 which enforces Debugger to 1 and above

This is no longer needed and will create an issue when updating to PDK 2.6
@davidsandilands davidsandilands requested a review from a team as a code owner January 17, 2023 13:19
@@ -2,8 +2,6 @@
Gemfile:
required:
':development':
- gem: 'puppet-debugger'
Copy link
Contributor

Choose a reason for hiding this comment

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

@davidsandilands I wonder if this is still a requirement for PDK versions <= 2.5.0

Copy link
Member Author

Choose a reason for hiding this comment

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

Hmm this gets messy.... we haven't updated since "pdk-version": "2.2.0", and 2.5.0 is also broken with the

pdk (FATAL):

[!] There was an error parsing `Gemfile`: You cannot specify the same gem twice with different version requirements.
You specified: puppet-debugger (~> 1.0) and puppet-debugger (>= 0.18.0). Bundler cannot continue.

 #  from /root/puppetlabs-peadm/Gemfile:37
 #  -------------------------------------------
 #    gem "rb-readline", '= 0.5.5',                        require: false, platforms: [:mswin, :mingw, :x64_mingw]
 >    gem "puppet-debugger", '>= 0.18.0',                  require: false
 #    gem "bolt", '>= 3.10.0',                             require: false
 #  -------------------------------------------

pdk (FATAL): Unable to resolve Gemfile dependencies.

but if I used this fix with PDK 2.5 running validate goes horribly wrong when trying to run commands

Don't run Bundler as root. Bundler can ask for sudo if it is needed, and installing your bundle as root will break this application
for all non-root users on this machine.
The dependency rb-readline (= 0.5.5) will be unused by any of the platforms Bundler is installing for. Bundler is installing for ruby but the dependency is only for x86-mswin32, x86-mingw32, x64-mingw32. To add those platforms to the bundle, run `bundle lock --add-platform x86-mswin32 x86-mingw32 x64-mingw32`.
Gem::Ext::BuildError: ERROR: Failed to build gem native extension.

    current directory: /root/.pdk/cache/ruby/2.7.0/gems/unf_ext-0.0.8.2/ext/unf_ext
/opt/puppetlabs/pdk/private/ruby/2.7.6/bin/ruby -I /opt/puppetlabs/pdk/private/ruby/2.7.6/lib/ruby/site_ruby/2.7.0 -r
./siteconf20230117-626-4tc8lc.rb extconf.rb
checking for -lstdc++... no
creating Makefile

current directory: /root/.pdk/cache/ruby/2.7.0/gems/unf_ext-0.0.8.2/ext/unf_ext
make "DESTDIR=" clean

current directory: /root/.pdk/cache/ruby/2.7.0/gems/unf_ext-0.0.8.2/ext/unf_ext
make "DESTDIR="
compiling unf.cc
make: g++: Command not found
make: *** [Makefile:213: unf.o] Error 127

make failed, exit code 2

Gem files will remain installed in /root/.pdk/cache/ruby/2.7.0/gems/unf_ext-0.0.8.2 for inspection.
Results logged to /root/.pdk/cache/ruby/2.7.0/extensions/x86_64-linux/2.7.0/unf_ext-0.0.8.2/gem_make.out

An error occurred while installing unf_ext (0.0.8.2), and Bundler cannot continue.
Make sure that `gem install unf_ext -v '0.0.8.2' --source 'https://rubygems.org/'` succeeds before bundling.

In Gemfile:
  puppet_litmus was resolved to 0.34.4, which depends on
    rspec_honeycomb_formatter was resolved to 0.2.1, which depends on
      honeycomb-beeline was resolved to 2.11.0, which depends on
        libhoney was resolved to 2.2.0, which depends on
          http was resolved to 5.1.1, which depends on
            http-cookie was resolved to 1.0.5, which depends on
              domain_name was resolved to 0.5.20190701, which depends on
                unf was resolved to 0.1.4, which depends on
                  unf_ext

pdk (FATAL): Unable to install missing Gemfile dependencies.

@timidri
Copy link
Contributor

timidri commented Jan 17, 2023 via email

@davidsandilands
Copy link
Member Author

@timidri not yet I thought it was something I could quickly fix but I will need to come back to this to review it in full

@davidsandilands
Copy link
Member Author

This has been covered in #321

@davidsandilands davidsandilands deleted the davidsandilands-sync-update branch February 3, 2023 14:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants