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

Fix puppet-lint namespace clash with new puppetlabs-lint gem #170

Closed
wants to merge 6 commits into from

Conversation

GSPatton
Copy link

Currently, the new puppet-lint gem and the old one clash as both compete for the PuppetLint namespace. This initial commit aims to solve this by intorducing the puppetlabs directory in lib so that resources are found in lib/puppetlabs/puppet-lint rather than lib/puppet-lint. This method is being tested first to avoid introducing changes that would require users to update their puppet-lint resource definitions

Summary

Provide a detailed description of all the changes present in this pull request.

Additional Context

Add any additional context about the problem here.

  • Root cause and the steps to reproduce. (If applicable)
  • Thought process behind the implementation.

Related Issues (if any)

Mention any related issues or pull requests.

Checklist

  • 🟢 Spec tests.
  • 🟢 Acceptance tests.
  • Manually verified.

@GSPatton GSPatton changed the title Fix puppet-lint namespace clash with new puppetlabs-puppet-lint gem (WIP) Fix puppet-lint namespace clash with new puppetlabs-puppet-lint gem Oct 20, 2023
@GSPatton GSPatton closed this Nov 7, 2023
@GSPatton GSPatton reopened this Nov 7, 2023
@GSPatton GSPatton marked this pull request as ready for review November 7, 2023 09:31
@GSPatton GSPatton requested review from bastelfreak and a team as code owners November 7, 2023 09:31
@GSPatton GSPatton changed the title (WIP) Fix puppet-lint namespace clash with new puppetlabs-puppet-lint gem Fix puppet-lint namespace clash with new puppetlabs-lint gem Nov 7, 2023
@bastelfreak
Copy link
Collaborator

@GSPatton can you please rebase? I think we should test one of the external plugins with this branch before merging.

Currently, the new puppet-lint gem and the old one clash as both compete for the PuppetLint namespace. This initial commit aims to solve this by intorducing the puppetlabs directory in lib so that resources are found in lib/puppetlabs/puppet-lint rather than lib/puppet-lint.
This method is being tested first to avoid introducing changes that would require users to update their puppet-lint resource definitions
@GSPatton GSPatton force-pushed the fix-namespace-clash branch from 3b7fbd8 to 5fe537f Compare November 8, 2023 09:49
@GSPatton
Copy link
Author

GSPatton commented Nov 8, 2023

hi @bastelfreak. Will test that out now

Copy link

@ekohl ekohl left a comment

Choose a reason for hiding this comment

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

I think all instances of PuppetLint need to be changed as well, otherwise it still overlaps with puppet-lint and can accidentally load the wrong files.

@ekohl
Copy link

ekohl commented Nov 14, 2023

Just a thought: perhaps pick a name that really is different, like puppet-cop (after RuboCop).

…int/plugins rather than lib/puppetlabs-lint/plugins - sacraficing consistency in naming here for minimal impact on users
@GSPatton
Copy link
Author

Hi @ekohl, instead of changing all instances of PuppetLint we added the puppetlabs directory into lib to change the directory structure and thereby hopefully not overlap namespaces with the old gem. This has been tested and works. But please test it out and let us know if you find anything.

@jordanbreen28
Copy link

jordanbreen28 commented Nov 21, 2023

Closing in favour of #177

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants