Ticket/2.7.x/12256 module tool core changes#504
Merged
slippycheeze merged 4 commits intopuppetlabs:2.7.xfrom Feb 15, 2012
Merged
Ticket/2.7.x/12256 module tool core changes#504slippycheeze merged 4 commits intopuppetlabs:2.7.xfrom
slippycheeze merged 4 commits intopuppetlabs:2.7.xfrom
Conversation
Contributor
There was a problem hiding this comment.
Seems like this is open to a false positive if the JSON file contains an array, or a simple string, at the top level. That would be an easy mistake for a user to make if they use some tool other than ours to handle the file format. Should this be more robust?
Contributor
Author
There was a problem hiding this comment.
Probably in the future, but that's not the change we need now to make things work.
Contributor
Author
|
Daniel, added unless method_defined? :intersection to the monkey patch method. Based on our in person conversation, that should address your concerns that are addressable at this point. Thanks. |
Having range intersection allows easier checking of version constraints,
and new comparson operators allow for ranged version constraints like
you would expect from a typical packaging system (ex 1.2.x).
There is also a slight change to the way prerelease version numbers are
validated so that a dash is required between the patch version and
prerelease string. This was done to comply with the declared semver
spec:
A pre-release version number MAY be denoted by appending an arbitrary
string immediately following the patch version and a dash
This could affect forge module versions, or face versions, but neither
of these were found to be using prerelease versioning anyway.
Pieter van de Bruggen was the original author of these changes, but I'm
submitting them as part a larger rebase for module tool change. I've
also reviewed the changes.
Being able to figure out what other modules depend on a module is useful for resolving contraints when installing and preventing uninstalls of modules that are still required. And being able to tell if a module has local changes is useful to prevent accidentally losing those changes when upgrading or uninstalling a module.
Before this patch module requirements do not include version numbers. Since modules with the same name, but different version numbers, can be installed at the same time -- in different parts of the modulepath, there is no way to tell which module has the dependency. This patch fixes this issue by changing the data structure that represents module requirements from a two item Array to a Hash with three keys: name, version, and version_requirement. This patch includes updated spec tests related to this change.
In Ruby 1.9 Range's implementation of include? changed so that if the objects being compared were non-numeric it would iterate over them instead of doing a comparison with the endpoints. We're subclassing numeric to force non-discrete range behavior. Numeric doesn't allow singleton methods to be defined, so we had to change the way inspect worked when dealing with MIN and MAX values. Paired-with: Pieter van de Bruggen <pieter@puppetlabs.com>
slippycheeze
added a commit
that referenced
this pull request
Feb 15, 2012
…core_changes Ticket/2.7.x/12256 module tool core changes
melissa
pushed a commit
to melissa/puppet
that referenced
this pull request
Mar 30, 2018
(PCP-625) Skip beaker time sync on Windows Sever 2016
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
These are the changes the puppet module tool will need that potentially affect other parts of Puppet.