librarian-puppet icon indicating copy to clipboard operation
librarian-puppet copied to clipboard

Inconsistent ordering of dependency constraints in Puppetfile.lock

Open benpillet opened this issue 6 years ago • 2 comments

Sometimes librarian-puppet install will update the Puppetfile.lock with the constraint in a different order than the original Puppetfile.lock. e.g. before:

...
puppet-archive (1.3.0)
    puppetlabs-stdlib (>= 4.6.0, < 5.0.0)
...

after:

...
puppet-archive (1.3.0)
    puppetlabs-stdlib (< 5.0.0, >= 4.6.0)
...

There's no logical difference in the dependency, but when the ordering changes, the diff changes and makes for git commit's that are long with many lines changing that obscure actual changes.

This may be an issue in librarianp, not librarian-puppet, but it I'm opening this to start the digging.

benpillet avatar May 29 '19 20:05 benpillet

I am facing a similar issue and have changed my workflow to update the lock file manually. Below is the information on my setup:

$ ruby --version
ruby 2.5.3p105 (2018-10-18 revision 65156) [x86_64-linux]
$
$ bundle exec ruby --version
ruby 2.5.3p105 (2018-10-18 revision 65156) [x86_64-linux]
$ 
$ bundle exec librarian-puppet version
librarian-puppet v3.0.0
$ 

apatelKmd avatar Dec 11 '19 17:12 apatelKmd

I know this is an old thread, but I think this issue might be related to this https://github.com/rubygems/rubygems/pull/3889 Which means that you require a gems version above 3.2.0.rc.2 You can install the latest version with gem update --system

bvalente avatar Sep 09 '22 15:09 bvalente