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
bundle update --conservative performs several un-necessary updates (Including MAJORS) #4319
Comments
Hi @luke-hill! Thanks for reporting this issue! I totally agree with your expectations. The I looked at the It's definitly worth digging into history to see why this option was introduced, and why it was introduced with this particular meaning, but my initial take is to change its behavior to what everyone intuitively expects: update only top-level dependencies. |
After reading through rubygems/bundler-features#122 and rubygems/bundler#4980, I don't see anything in there suggesting this is actually expected, except for this one line in the commit message, and the relative "unlock shared dependencies" naming:
Just to confirm that I'll be treating this as a plain bug without any backwards compatibility concerns. |
Hei @luke-hill! I have a question for you. Did you maybe edit the lockfile directly to share this repro case? I'm asking because you shared a lockfile that includes an incorrect resolution 😬. I really hope bundler is not generating this lockfile automatically 🤞. The error in the lockfile is that it includes |
Yep I did. So if there's one or two inconsistencies ignore it. The OP stands. There was some stuff that I ran that shouldn't be committed so I removed it. |
That's great to hear. I created #4459 to warn this situation. |
@luke-hill It took me a while to get to this, but #4692 should fix this! |
Around the time this went in was around the time I was switching jobs / on holiday. So forgot to say thanks / well done. :) Top work! |
Describe the problem as clearly as you can
Running
bundle update --conservative
on my gemfile performs an un-necessary major version update to a dependent gem.Post steps to reproduce the problem
Gemfile
Gemfile.lock
Which command did you run?
bundle update --conservative
What were you expecting to happen?
All gems in my gemfile to be updated, all dependencies not to be updated unless they were directly required to
What actually happened?
Extra updates happened. Below is the git diff
Gem updates and expectations
ast
2.4.1 -> 2.4.2. - UNEXPECTEDcapybara
3.34.0 -> 3.35.0 - EXPECTED (This changed regexp_parser's restrictions, but still shouldn't edit it)concurrent-ruby
1.1.7 -> 1.1.8 - UNEXPECTEDmailosaur
7.0.2 -> 7.1.0 - EXPECTEDregexp_parser
- 1.8.2 -> 2.0.3 - UNEXPECTEDrubocop
- 1.0.0 -> 1.8.1 - EXPECTED (This changed regexp_parser, rubocop-ast and unicode_display_width restrictions, but still shouldn't edit any of them, as their previous versions were valid)rubocop-ast
1.4.0 -> 1.4.1 - UNEXPECTEDthor
1.0.1 -> 1.1.0 - UNEXPECTEDunicode-display_width
1.7.0 -> 2.0.0 - UNEXPECTEDview_component - 2.24.0 -> 2.25.0 - UNEXPECTED
webdrivers` 4.4.2 -> 4.5.0 - EXPECTEDIf not included with the output of your command, run
bundle env
and paste the output belowWas the same as above basically
The text was updated successfully, but these errors were encountered: