ruby-core@ruby-lang.org archive (unofficial mirror)
 help / color / mirror / Atom feed
* [ruby-core:91622] [Ruby trunk Bug#15622] Default version of Bundler incorrectly invoked when using binstubs
       [not found] <redmine.issue-15622.20190225223847@ruby-lang.org>
@ 2019-02-25 22:38 ` richard.schneeman+ruby-lang
  2019-02-26  8:22 ` [ruby-core:91623] " mattduszynski
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 5+ messages in thread
From: richard.schneeman+ruby-lang @ 2019-02-25 22:38 UTC (permalink / raw)
  To: ruby-core

Issue #15622 has been reported by schneems (Richard Schneeman).

----------------------------------------
Bug #15622: Default version of Bundler incorrectly invoked when using binstubs 
https://bugs.ruby-lang.org/issues/15622

* Author: schneems (Richard Schneeman)
* Status: Open
* Priority: Normal
* Assignee: 
* Target version: 
* ruby -v: ruby 2.6.1p33 (2019-01-30 revision 66950) [x86_64-linux]
* Backport: 2.4: UNKNOWN, 2.5: UNKNOWN, 2.6: UNKNOWN
----------------------------------------
When trying to run a binstub with Ruby 2.6.1 with Bundler 2.0.1 on the system, the wrong version of Bundler gets loaded which then fails when the Gemfile.lock points to a 2.x version (since the default version that ships with Ruby is Bundler 1.x. While this was discovered on Heroku and is discussed in this issue https://github.com/heroku/heroku-buildpack-ruby/issues/856#issuecomment-467205932 I was able to replicate the problem fairly easily with docker. I've provided instructions below.

## Reproduction

Start a docker image with Ruby 2.6.1

```
docker run -it --rm ruby:2.6.1 bash
```

Install bundler, rails, make a new app, and remove the `begin/rescue/end` from the `bin/rake` binstub. To trigger the error run a `rake` command without `bundle exec`:

```
gem install bundler -v 2.0.1
gem install rails -v 6.0.0.beta1
rails new ruby-2-6-bundler-2-issue


cd ruby-2-6-bundler-2-issue

cat <<EOT > bin/rake
#!/usr/bin/env ruby
require_relative '../config/boot'
require 'rake'
Rake.application.run
EOT

rake -T
```

Output:

```
You must use Bundler 2 or greater with this lockfile.
```

Expected:

Bundler 2 is available on the system, and is the latest version, so it should be invoked instead of the default bundler version.





-- 
https://bugs.ruby-lang.org/

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [ruby-core:91623] [Ruby trunk Bug#15622] Default version of Bundler incorrectly invoked when using binstubs
       [not found] <redmine.issue-15622.20190225223847@ruby-lang.org>
  2019-02-25 22:38 ` [ruby-core:91622] [Ruby trunk Bug#15622] Default version of Bundler incorrectly invoked when using binstubs richard.schneeman+ruby-lang
@ 2019-02-26  8:22 ` mattduszynski
  2019-02-26  8:45 ` [ruby-core:91624] " hsbt
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 5+ messages in thread
From: mattduszynski @ 2019-02-26  8:22 UTC (permalink / raw)
  To: ruby-core

Issue #15622 has been updated by dzunk (Matt Duszynski).


I was able to reproduce this with the steps provided, and it seems to work after a `gem update --system`. Possibly a bug in a particular version of Rubygems?

----------------------------------------
Bug #15622: Default version of Bundler incorrectly invoked when using binstubs 
https://bugs.ruby-lang.org/issues/15622#change-76885

* Author: schneems (Richard Schneeman)
* Status: Open
* Priority: Normal
* Assignee: 
* Target version: 
* ruby -v: ruby 2.6.1p33 (2019-01-30 revision 66950) [x86_64-linux]
* Backport: 2.4: UNKNOWN, 2.5: UNKNOWN, 2.6: UNKNOWN
----------------------------------------
When trying to run a binstub with Ruby 2.6.1 with Bundler 2.0.1 on the system, the wrong version of Bundler gets loaded which then fails when the Gemfile.lock points to a 2.x version (since the default version that ships with Ruby is Bundler 1.x. While this was discovered on Heroku and is discussed in this issue https://github.com/heroku/heroku-buildpack-ruby/issues/856#issuecomment-467205932 I was able to replicate the problem fairly easily with docker. I've provided instructions below.

## Reproduction

Start a docker image with Ruby 2.6.1

```
docker run -it --rm ruby:2.6.1 bash
```

Install bundler, rails, make a new app, and remove the `begin/rescue/end` from the `bin/rake` binstub. To trigger the error run a `rake` command without `bundle exec`:

```
gem install bundler -v 2.0.1
gem install rails -v 6.0.0.beta1
rails new ruby-2-6-bundler-2-issue


cd ruby-2-6-bundler-2-issue

cat <<EOT > bin/rake
#!/usr/bin/env ruby
require_relative '../config/boot'
require 'rake'
Rake.application.run
EOT

rake -T
```

Output:

```
You must use Bundler 2 or greater with this lockfile.
```

Expected:

Bundler 2 is available on the system, and is the latest version, so it should be invoked instead of the default bundler version.





-- 
https://bugs.ruby-lang.org/

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [ruby-core:91624] [Ruby trunk Bug#15622] Default version of Bundler incorrectly invoked when using binstubs
       [not found] <redmine.issue-15622.20190225223847@ruby-lang.org>
  2019-02-25 22:38 ` [ruby-core:91622] [Ruby trunk Bug#15622] Default version of Bundler incorrectly invoked when using binstubs richard.schneeman+ruby-lang
  2019-02-26  8:22 ` [ruby-core:91623] " mattduszynski
@ 2019-02-26  8:45 ` hsbt
  2019-02-27  8:44 ` [ruby-core:91629] " deivid.rodriguez
  2019-03-08 11:41 ` [ruby-core:91715] " hsbt
  4 siblings, 0 replies; 5+ messages in thread
From: hsbt @ 2019-02-26  8:45 UTC (permalink / raw)
  To: ruby-core

Issue #15622 has been updated by hsbt (Hiroshi SHIBATA).

Assignee set to hsbt (Hiroshi SHIBATA)
Status changed from Open to Assigned

----------------------------------------
Bug #15622: Default version of Bundler incorrectly invoked when using binstubs 
https://bugs.ruby-lang.org/issues/15622#change-76886

* Author: schneems (Richard Schneeman)
* Status: Assigned
* Priority: Normal
* Assignee: hsbt (Hiroshi SHIBATA)
* Target version: 
* ruby -v: ruby 2.6.1p33 (2019-01-30 revision 66950) [x86_64-linux]
* Backport: 2.4: UNKNOWN, 2.5: UNKNOWN, 2.6: UNKNOWN
----------------------------------------
When trying to run a binstub with Ruby 2.6.1 with Bundler 2.0.1 on the system, the wrong version of Bundler gets loaded which then fails when the Gemfile.lock points to a 2.x version (since the default version that ships with Ruby is Bundler 1.x. While this was discovered on Heroku and is discussed in this issue https://github.com/heroku/heroku-buildpack-ruby/issues/856#issuecomment-467205932 I was able to replicate the problem fairly easily with docker. I've provided instructions below.

## Reproduction

Start a docker image with Ruby 2.6.1

```
docker run -it --rm ruby:2.6.1 bash
```

Install bundler, rails, make a new app, and remove the `begin/rescue/end` from the `bin/rake` binstub. To trigger the error run a `rake` command without `bundle exec`:

```
gem install bundler -v 2.0.1
gem install rails -v 6.0.0.beta1
rails new ruby-2-6-bundler-2-issue


cd ruby-2-6-bundler-2-issue

cat <<EOT > bin/rake
#!/usr/bin/env ruby
require_relative '../config/boot'
require 'rake'
Rake.application.run
EOT

rake -T
```

Output:

```
You must use Bundler 2 or greater with this lockfile.
```

Expected:

Bundler 2 is available on the system, and is the latest version, so it should be invoked instead of the default bundler version.





-- 
https://bugs.ruby-lang.org/

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [ruby-core:91629] [Ruby trunk Bug#15622] Default version of Bundler incorrectly invoked when using binstubs
       [not found] <redmine.issue-15622.20190225223847@ruby-lang.org>
                   ` (2 preceding siblings ...)
  2019-02-26  8:45 ` [ruby-core:91624] " hsbt
@ 2019-02-27  8:44 ` deivid.rodriguez
  2019-03-08 11:41 ` [ruby-core:91715] " hsbt
  4 siblings, 0 replies; 5+ messages in thread
From: deivid.rodriguez @ 2019-02-27  8:44 UTC (permalink / raw)
  To: ruby-core

Issue #15622 has been updated by deivid (David Rodríguez).


Forgot to comment here. I'm pretty sure this is the same as https://bugs.ruby-lang.org/issues/15582? The fix for it should be released in the next patch level version

For the moment `gem update --system` indeed workarounds it, since it forces the reinstallation of the default bundler gem, which is the culprit here (its gemspec's file list is incomplete).

----------------------------------------
Bug #15622: Default version of Bundler incorrectly invoked when using binstubs 
https://bugs.ruby-lang.org/issues/15622#change-76890

* Author: schneems (Richard Schneeman)
* Status: Assigned
* Priority: Normal
* Assignee: hsbt (Hiroshi SHIBATA)
* Target version: 
* ruby -v: ruby 2.6.1p33 (2019-01-30 revision 66950) [x86_64-linux]
* Backport: 2.4: UNKNOWN, 2.5: UNKNOWN, 2.6: UNKNOWN
----------------------------------------
When trying to run a binstub with Ruby 2.6.1 with Bundler 2.0.1 on the system, the wrong version of Bundler gets loaded which then fails when the Gemfile.lock points to a 2.x version (since the default version that ships with Ruby is Bundler 1.x. While this was discovered on Heroku and is discussed in this issue https://github.com/heroku/heroku-buildpack-ruby/issues/856#issuecomment-467205932 I was able to replicate the problem fairly easily with docker. I've provided instructions below.

## Reproduction

Start a docker image with Ruby 2.6.1

```
docker run -it --rm ruby:2.6.1 bash
```

Install bundler, rails, make a new app, and remove the `begin/rescue/end` from the `bin/rake` binstub. To trigger the error run a `rake` command without `bundle exec`:

```
gem install bundler -v 2.0.1
gem install rails -v 6.0.0.beta1
rails new ruby-2-6-bundler-2-issue


cd ruby-2-6-bundler-2-issue

cat <<EOT > bin/rake
#!/usr/bin/env ruby
require_relative '../config/boot'
require 'rake'
Rake.application.run
EOT

rake -T
```

Output:

```
You must use Bundler 2 or greater with this lockfile.
```

Expected:

Bundler 2 is available on the system, and is the latest version, so it should be invoked instead of the default bundler version.





-- 
https://bugs.ruby-lang.org/

^ permalink raw reply	[flat|nested] 5+ messages in thread

* [ruby-core:91715] [Ruby trunk Bug#15622] Default version of Bundler incorrectly invoked when using binstubs
       [not found] <redmine.issue-15622.20190225223847@ruby-lang.org>
                   ` (3 preceding siblings ...)
  2019-02-27  8:44 ` [ruby-core:91629] " deivid.rodriguez
@ 2019-03-08 11:41 ` hsbt
  4 siblings, 0 replies; 5+ messages in thread
From: hsbt @ 2019-03-08 11:41 UTC (permalink / raw)
  To: ruby-core

Issue #15622 has been updated by hsbt (Hiroshi SHIBATA).

Backport changed from 2.4: UNKNOWN, 2.5: UNKNOWN, 2.6: UNKNOWN to 2.4: DONTNEED, 2.5: DONTNEED, 2.6: DONTNEED
Status changed from Assigned to Rejected

@schneems

I couldn't reproduce the latest ruby_2_6 branch with fixed #15582. Please wait for releasing next stable version 2.6.2.

----------------------------------------
Bug #15622: Default version of Bundler incorrectly invoked when using binstubs 
https://bugs.ruby-lang.org/issues/15622#change-76987

* Author: schneems (Richard Schneeman)
* Status: Rejected
* Priority: Normal
* Assignee: hsbt (Hiroshi SHIBATA)
* Target version: 
* ruby -v: ruby 2.6.1p33 (2019-01-30 revision 66950) [x86_64-linux]
* Backport: 2.4: DONTNEED, 2.5: DONTNEED, 2.6: DONTNEED
----------------------------------------
When trying to run a binstub with Ruby 2.6.1 with Bundler 2.0.1 on the system, the wrong version of Bundler gets loaded which then fails when the Gemfile.lock points to a 2.x version (since the default version that ships with Ruby is Bundler 1.x. While this was discovered on Heroku and is discussed in this issue https://github.com/heroku/heroku-buildpack-ruby/issues/856#issuecomment-467205932 I was able to replicate the problem fairly easily with docker. I've provided instructions below.

## Reproduction

Start a docker image with Ruby 2.6.1

```
docker run -it --rm ruby:2.6.1 bash
```

Install bundler, rails, make a new app, and remove the `begin/rescue/end` from the `bin/rake` binstub. To trigger the error run a `rake` command without `bundle exec`:

```
gem install bundler -v 2.0.1
gem install rails -v 6.0.0.beta1
rails new ruby-2-6-bundler-2-issue


cd ruby-2-6-bundler-2-issue

cat <<EOT > bin/rake
#!/usr/bin/env ruby
require_relative '../config/boot'
require 'rake'
Rake.application.run
EOT

rake -T
```

Output:

```
You must use Bundler 2 or greater with this lockfile.
```

Expected:

Bundler 2 is available on the system, and is the latest version, so it should be invoked instead of the default bundler version.





-- 
https://bugs.ruby-lang.org/

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2019-03-08 11:41 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <redmine.issue-15622.20190225223847@ruby-lang.org>
2019-02-25 22:38 ` [ruby-core:91622] [Ruby trunk Bug#15622] Default version of Bundler incorrectly invoked when using binstubs richard.schneeman+ruby-lang
2019-02-26  8:22 ` [ruby-core:91623] " mattduszynski
2019-02-26  8:45 ` [ruby-core:91624] " hsbt
2019-02-27  8:44 ` [ruby-core:91629] " deivid.rodriguez
2019-03-08 11:41 ` [ruby-core:91715] " hsbt

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).