Closed dLobatog closed 7 years ago
Thank you for this PR:
ERROR: While executing gem ... (Gem::Resolver::Molinillo::CircularDependencyError)
There is a circular dependency between stomp and stomp
At least locking stomp to the previous versions (gem 'stomp', '1.4.1'
) allows bundle to succeed.
Yeah, a new patch version even just with these changes would be nice I think, as otherwise anything that has an unpinned dependency in stomp will not load
Did you hand edit the gemspec file ??
Regardless, there is a problem.
However your PR as it is does not seem to address the entire issue:
$ ruby -v
ruby 2.3.2p113 (2016-04-26 revision 54786) [x86_64-linux]
$ git log -1 --pretty=oneline
8bf8a46459fcf23d4fe815748c6ab61130b96009 Remove self-dependency on stomp
$ rake build
WARN: Unresolved specs during Gem::Specification.reset:
nokogiri (>= 1.5.10)
rack (< 3, >= 1.2)
WARN: Clearing out unresolved specs.
Please report a bug if this causes problems.
WARNING: See http://guides.rubygems.org/specification-reference/ for help
rake aborted!
Gem::InvalidSpecificationException: duplicate dependency on rspec (>= 2.14.1, development), (>= 2.14.1) use:
add_development_dependency 'rspec', '>= 2.14.1', '>= 2.14.1'
Tasks: TOP => build
(See full trace by running task with --trace)
$ rake install
WARN: Unresolved specs during Gem::Specification.reset:
nokogiri (>= 1.5.10)
rack (< 3, >= 1.2)
WARN: Clearing out unresolved specs.
Please report a bug if this causes problems.
WARNING: See http://guides.rubygems.org/specification-reference/ for help
rake aborted!
Gem::InvalidSpecificationException: duplicate dependency on rspec (>= 2.14.1, development), (>= 2.14.1) use:
add_development_dependency 'rspec', '>= 2.14.1', '>= 2.14.1'
Tasks: TOP => install => build
(See full trace by running task with --trace)
Using 'rake build' actually works on ruby 1.8.7 (2014-01-28 patchlevel 376), rake, version 0.9.2.2. Which is how 1.4.2 made it out the door in the first place. I will add 'rake install' to release procedures to make sure this does not happen again.
In the mean time, I am looking at what it will take to completely fix this. And ask that you do the same.
The gem has traditionally used jeweler to generate the gemspec. That goes back to ..... around the time of my first commit, although I did not add jeweler to the mix. See 8ffa3414265169d6c529e282525a72b7d70c2bd4 for when jeweler was added. Gemspec generation is accomplished by:
rake gemspec:generate
This install failure is apparently triggered by both:
If both of those conditions are present, it causes the insertion of dependencies into the gemspec file. A number of those dependencies seem nonsensical to me. e.g.:
s.add_dependency(%q<stomp>, [">= 0"])
Additionally spurious (duplicate) dependencies are also added to the gemspec:
s.add_dependency(%q<rspec>, [">= 2.14.1"])
s.add_dependency(%q<rspec>, [">= 2.14.1"])
I am thinking the use of jeweler needs to be reevaluated. The jeweler gem is in somewhat of a state of flux. See:
for some of that discussion.
However, I am not going to do that immediately. I want to examine alternatives more closely in a more leisurely fashion.
A quick (and perhaps somewhat ugly) way of fixing the current install problems is:
If that is done, the gemspec is generated properly, and the failure to install disappears completely.
In order to get an installable version out on the street now, I am likely to go with that approach and examine alternatives in a less stressful way. The Gemfile was very recently added, and removal should not cause too much pain I hope.
I do appreciate your efforts on this issue, thank you. I will let this PR dangle for a while. However, as far as I can see the PR is not a total solution to install failures.
Try an install of 1.4.3, which is on rubygems.
Thanks @gmallard , the current gemspec is looking good again. I'm not very interested on jeweler, though, I prefer to do gemspecs by hand, so if you don't mind I'll close this one out
In the meantime I have tracked down why the jeweler and Gemfile mix was causing the install failure.
I will do some more testing, but will likely add the Gemfile back again in the future if that testing goes well.
Currently installing 1.4.2 through 'gem install stomp' or 'bundle install' breaks. The reason is just that stomp relies on itself on the gemspec, the error we get is:
This change simply removes that dependency that I believe should not be there, and also removes the double dev dependency on rspec. Rake is already required in the gemspec so I removed it from the Gemfile.
Notice the current double 'rspec' requirement and the self-requirement of 'stomp' produce warning/errors already: