You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a gem that depends on Bcrypt and because I do not check in the Gemfile.lock for my gems my CI server just started failing. This failure may be truly on our side, but when I went to trace down my dependencies I found bcrypt and bcrypt-ruby; via Ruby Gems the source code links both point to this repo. The gems on disk are obviously not the same.
Can you explain a little about what is going on with the dependency between bcrypt and bcrypt-ruby (specifically for the java impl)? Right now if I change my gemspec to force bcrypt-ruby 3.1.2 everything passes, obviously pessimistic includes grab the change you just released (which looks safe).
I am using jruby and verified the same behavior on 1.7.8 - 10
I will do some more digging into this and see if there is a bug on my side (there probably is something with a require that we were getting lucky with), but I wanted to open a thread in case other people find similar issue. I'm happy to move this to a discussion group if you like.
Ok -- follow up I think something is corrupting your bcrypt.rb file for java. The one I am pulling down is garbage and if I replace that with what I see on github master all works.
I'm sure this is just an oversight, you have three work arounds right now:
lock your gem back to 3.1.2 (this is what I did)
where you previously require 'bcrypt' you need to require the files you see in bcrypt.rb (including the jar for jruby), the corruption is only bcrypt.rb that I can see
patch a local version and install locally or to a local gemserver and use this until fixed
Can you explain a little about what is going on with the dependency between bcrypt and bcrypt-ruby
The gem was renamed from bcrypt-ruby to simply bcrypt -- see #86
To attempt backwards compatibility, a new version of the bcrypt-ruby gem was pushed that was an empty dummy gem, but has a dependency on bcrypt to load it.
However, this problem seems to happen on JRuby even when just bcrypt is installed, so I think -- think -- it's unrelated. But I'm looking into it. Thanks for reporting.
@moofish32 You're right, something seemed to be corrupt with the bcrypt.rb file, but just in the Java version. It appeared to be entirely unrelated to the renaming.
Activity
moofish32 commentedon Feb 22, 2014
Ok -- follow up I think something is corrupting your bcrypt.rb file for java. The one I am pulling down is garbage and if I replace that with what I see on github master all works.
lephyrius commentedon Feb 22, 2014
Im also seeing this problem in jruby-1.7.10 / Rails 4 .
murrekatt commentedon Feb 22, 2014
Same problem. bcrypt-ruby contains only a single constant: Dummy. No other BCrypt stuff available, hence the uninitialized constant for Password.
murrekatt commentedon Feb 22, 2014
I use ruby 1.9.3 and Rails 3
moofish32 commentedon Feb 22, 2014
I'm sure this is just an oversight, you have three work arounds right now:
tjschuck commentedon Feb 25, 2014
The gem was renamed from
bcrypt-rubyto simplybcrypt-- see #86To attempt backwards compatibility, a new version of the
bcrypt-rubygem was pushed that was an empty dummy gem, but has a dependency onbcryptto load it.However, this problem seems to happen on JRuby even when just
bcryptis installed, so I think -- think -- it's unrelated. But I'm looking into it. Thanks for reporting.tjschuck commentedon Feb 25, 2014
@moofish32 You're right, something seemed to be corrupt with the
bcrypt.rbfile, but just in the Java version. It appeared to be entirely unrelated to the renaming.I just rebuilt and pushed version 3.1.7 of
bcryptto RubyGems -- please let me know if that fixes things for you.Thanks! ❤️
moofish32 commentedon Feb 25, 2014
@tjschuck - 3.1.7 works backwards compatible to the former bcrypt-ruby 3.1.2 for jruby (1.7.8-10).
Thanks for the quick fix and the details.