rubygems / bundler-features

Bundler feature requests and discussion
28 stars 8 forks source link

Only use Major and Minor version in BUNDLED_WITH #89

Closed rafaelfranca closed 9 years ago

rafaelfranca commented 9 years ago

Given the number of workflow problems that BUNDLED_WITH change created, I think it would be great to it use only Major and Minor version segments.

This would keep the advantage pointed by @indirect here https://github.com/bundler/bundler/issues/3726#issuecomment-109875181, but also would make easier to most projects keep their workflows.

Given that bundler team is so obsessive to backward compatibility and behavior should not change in patch releases can we change BUNDLED_WITH to not include patch releases?

Example:

BUNDLED_WITH
  0.10

Related https://github.com/bundler/bundler/issues/3726 and https://github.com/bundler/bundler/issues/3697

segiddins commented 9 years ago

Since patch releases can contain critical bug fixes, I'm not in favor of this.

rafaelfranca commented 9 years ago

You mean that patch releases of bundler can break backward compatibility?

faun commented 9 years ago

I'm with @rafaelfranca on this one. I came here to file an issue for this, but alas, I can stand on the shoulders of giants.

indirect commented 9 years ago

@rafaelfranca yes, patch releases can break backwards compatibility (and have many times in the past). We then issue another patch release to restore backwards compatibility, which is why the patch release matters a lot.

Including only the minor version will not help the 1.9 to 1.10 migration in the slightest, and once everyone has migrated to 1.10, patch level upgrades will not dirty the lock file. Please see this comment for a little bit more explanation.

rafaelfranca commented 9 years ago

@indirect thanks, the comment clarifies a lot but I still don't get one thing. You said:

Once everyone on your team is running Bundler 1.10, the lock will only change when the running version of Bundler is greater than the version saved in the lock.

In this case what happens if someone of my team is using a older version than the one that is on the lock? Will they be able to run bundler commands without any error or warning? If that is the case I don't see the point on keeping the patch level on the Gemfile.lock.

segiddins commented 9 years ago

@rafaelfranca they will get a warning if running a bundler version older than the locked version.

rafaelfranca commented 9 years ago

Great! Now it makes sense. Thanks.

indirect commented 9 years ago

Anyone looking for a longer explanation of why we decided not to do this, and an explanation of how to resolve BUNDLED WITH pain, can read about it on the Bundler blog.

faun commented 9 years ago

Thanks @indirect!