Skip to content
This repository has been archived by the owner on Apr 14, 2021. It is now read-only.

[Lockfile] Make the BUNDLED WITH section backwards compatible #3623

Merged
merged 1 commit into from
May 7, 2015

Conversation

segiddins
Copy link
Member

This makes the lockfile compatible at least back to 1.3.x, I was too lazy to switch Rubies to check back even further. It also is the ugliest, wackiest possible fix I could think of :(.

@indirect
Copy link
Member

indirect commented May 7, 2015

Ugh, I still can't figure out how to reproduce the incompatibility. Can someone give me steps? // @segiddins @andremedeiros

@andremedeiros
Copy link
Member

Installing the first pre and bundleing something makes the Gemfile.lock not work on older versions. i got that yesterday when I reported it to @segiddins

@indirect
Copy link
Member

indirect commented May 7, 2015

@andremedeiros yeah, I saw that both of you managed to reproduce it, but I can't figure out how :/

$ dbundle install
Resolving dependencies...
Using rake 10.4.2
Using bundler 1.10.0.pre
Bundle complete! 1 Gemfile dependency, 2 gems now installed.
Use `bundle show [gemname]` to see where a bundled gem is installed.

$ cat Gemfile.lock
GEM
  specs:
    rake (10.4.2)

PLATFORMS
  ruby

DEPENDENCIES
  rake

BUNDLED WITH
  1.10.0.pre

$ bundle -v
Bundler version 1.9.5

$ bundle install
Resolving dependencies...
Using rake 10.4.2
Using bundler 1.9.5
Bundle complete! 1 Gemfile dependency, 2 gems now installed.
Use `bundle show [gemname]` to see where a bundled gem is installed.

$ bundle update
Resolving dependencies...
Using rake 10.4.2
Using bundler 1.9.5
Bundle updated!

$ cat Gemfile.lock
GEM
  specs:
    rake (10.4.2)

PLATFORMS
  ruby

DEPENDENCIES
  rake

@andremedeiros
Copy link
Member

Actually I tried it now and I can't reproduce it either. :-(

@andremedeiros
Copy link
Member

~/Source/sandbox/backwards-incompat
❯ dbundle
Using ansi 1.5.0
Using ast 2.0.0
Using ruby-ll 2.1.1
Using oga 0.3.4
Using bundler 1.10.0.pre
Bundle complete! 1 Gemfile dependency, 5 gems now installed.
Use `bundle show [gemname]` to see where a bundled gem is installed.

~/Source/sandbox/backwards-incompat
❯ bundle install --path vendor/bundle --deployment --clean
You are trying to install in deployment mode after changing
your Gemfile. Run `bundle install` elsewhere and add the
updated Gemfile.lock to version control.

You have deleted from the Gemfile:
* 1.10.0.pre

indirect added a commit that referenced this pull request May 7, 2015
[Lockfile] Make the BUNDLED WITH section backwards compatible
@indirect indirect merged commit acef4ba into master May 7, 2015
@indirect indirect deleted the seg-bundled-with-compatibility branch May 7, 2015 08:15
@dlovellrw
Copy link

This commit causes a git diff whenever running bundler, e.g.

+
+BUNDLED WITH
+   1.10.2

forcing developers on a team to either:

  1. ignore the Gemfile.lock in the diff - dangerous and annoying
  2. get into lockstep on their bundler version - possibly desirable, but invasive

What do you think?

@segiddins
Copy link
Member Author

@dlovellrw please read the most recent closed issues about this, as well as #3722, instead of commenting on an old merged PR

@dlovellrw
Copy link

Yeah, I got there. Thanks for putting the reference here. You guys opened a can of worms with this one, and you keep shutting down comment on it. Well, it's your world...

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants