rodjek / librarian-puppet

http://librarian-puppet.com
MIT License
693 stars 209 forks source link

Issues when merging dependencies #291

Closed fatmcgav closed 9 years ago

fatmcgav commented 9 years ago

Firstly, thanks for fixing #282. However I still seem to be having issues with the merging of duplicate dependencies...

The following is the log output when running librarian-puppet install:

librarian-puppet install --path=spec/fixtures/modules/ Dependency 'fatmcgav-glassfish' duplicated for module act-base, merging: ["fatmcgav-glassfish (>= 0.3.0) https://github.com/fatmcgav/fatmcgav-glassfish.git#develop", "fatmcgav-glassfish (>= 0.3.0) http://forge.puppetlabs.com"] Dependency 'cescoffier-nexus' duplicated for module act-base, merging: ["cescoffier-nexus (>= 0.0.1) https://github.com/cescoffier/puppet-nexus.git#master", "cescoffier-nexus (>= 0.0.1) http://forge.puppetlabs.com"] Dependency 'ripienaar-module_data' duplicated for module act-base, merging: ["ripienaar-module_data (>= 0.0.4) https://github.com/ripienaar/puppet-module-data.git#master", "ripienaar-module_data (>= 0.0.4) http://forge.puppetlabs.com"] Dependency 'datacentred-ldap' duplicated for module act-base, merging: ["datacentred-ldap (>= 0.3.0) https://github.com/datacentred/datacentred-ldap.git#master", "datacentred-ldap (>= 0.3.0) http://forge.puppetlabs.com"] Unable to find module 'cescoffier-nexus' on http://forge.puppetlabs.com rake aborted!

Now I thought that the merge behaviour should use the first source specified, which is the Git source. However the failure line suggests it's trying to use forge, and failing...

Edit: This is using Librarian-puppet 1.5.0, with librarianp 0.6.2.

Any ideas?

Cheers Gavin

fatmcgav commented 9 years ago

I did a bit more poking around, and it looks like the behaviour of Librarianp changed in this commit: befb958a to use the last source, not the first...

I'm guessing there was a logical reason for the change?

Will try downgrading librarianp to 0.5.x...

Cheers Gavin

fatmcgav commented 9 years ago

Hmm, I'm still struggling to get this working reliably...

I'm now getting the following error: json_pure-1.8.2/lib/json/common.rb:155:in```parse': 757: unexpected token at '' (JSON::ParserError)

Full stack is here: https://gist.github.com/fatmcgav/1587220f46a5d1d5bd6a

Any pointers?

Cheers Gavin

fatmcgav commented 9 years ago

That last comment might've been an issue with Puppet Forge....

Could still do with some confirmation on expected behaviour above though...

Cheers Gav

carlossg commented 9 years ago

the reason for merging to default to the last is so you can override dependencies in your Puppetfile putting them at the end