Password fields not shown for the first admin user with Ruby 2.1

177 views
Skip to first unread message

nile...@gmail.com

unread,
Apr 19, 2014, 1:13:16 AM4/19/14
to hobo...@googlegroups.com
Hi,

I know Hobo does not support Ruby 2.1. Just noting down this issue for others' reference.

When I create a new application with Ruby 2.1, Rails 4.0, only "name" and "email" fields are shown on the welcome page for creating the admin user. Also, UnknownAttributeError is thrown while signing up as a regular user.

With Ruby 2.0, it works fine (both password and password_confirmation fields are shown on the welcome page).

regards
nilesh



Ignacio Huerta

unread,
May 3, 2014, 1:16:28 PM5/3/14
to hobo...@googlegroups.com
Hi!

I finally fixed this bug. Now Hobo should be compatible with Ruby 2.1. If you want to test it, just edit your Gemfile with:

gem 'hobo', github: 'Hobo/hobo'

That will make you use the latest code from the repository.

Warm regards,
Ignacio

Stefan Haslinger

unread,
May 5, 2014, 12:18:55 PM5/5/14
to hobo...@googlegroups.com
Yes they show up again!

I testet quite a lot of stuff today with Ruby 2.1.1, everything's fine.

I learned one thing (not Hobo related, but Rails related):
If you have an integer attribute, let's say position and try to validate it
validates :position, numericality: { only_integer: true }

then the test
it {should validate_numericality_of(:position).only_integer}
now fails.

The reason: if the column is of type integer (not decimal) the validation does NOT fail, 
because writing to the attribute
@instance.attribute = 3.3 
does not raise, but now stores 3 in the attribute (I assume something like 3.3.to_i).
No idea, when this changed (I was sloppy running my tests ...).

If the column is of type decimal, the validations raise and fail as expected.
Again, this is NOT Hobo related, I tested in a Rails only app as well, same behaviour there.

A big THANKS to Ignacio for updating. I keep developing on 2.1.1 and see how it goes.

Ciao,
Stefan

Stefan Haslinger

unread,
May 14, 2014, 5:13:59 AM5/14/14
to hobo...@googlegroups.com
Ok, so nine days later now, i.e. 6 full working days with Ruby 2.1.1 and no issues with Hobo so far.

The only thing I"m noticing (which also happens for Rails - non-Hobo Apps):
continue after hitting a break point every now and then crashed Ruby with a core dump.
Am I the only one experiencing this? (Ubuntu 14.04, Rails 4.0.x and Rails 3.2.x, Thin)

That's the reason why I wouldn't run Ruby 2.1.1 in production right now.
I just saw, I had an old version of debugger gem. Maybe that's the reason...

Cheers,
Stefan

Ignacio Huerta

unread,
May 15, 2014, 2:37:31 AM5/15/14
to hobo...@googlegroups.com
Hi Stefan,

I have not seen this but I have not work with Ruby 2.1.1 too much yet.
Usually a core dump indicates a bug in Ruby as far as I know. By the
way, they just releases Ruby 2.1.2, maybe they fixed the issue.

If you can prepare a simple test case please share it and I'll try to
reproduce it too.

Warm regards,
Ignacio

El 14/05/14 11:13, Stefan Haslinger escribió:
> Ok, so nine days later now, i.e. 6 full working days with Ruby 2.1.1 and
> no issues with Hobo so far.
>
> The only thing I"m noticing (which also happens for Rails - non-Hobo Apps):
> *continue* after hitting a break point every now and then crashed Ruby
> with a core dump.
> Am I the only one experiencing this? (Ubuntu 14.04, Rails 4.0.x and
> Rails 3.2.x, Thin)
>
> That's the reason why I wouldn't run Ruby 2.1.1 in production right now.
> I just saw, I had an old version of debugger gem. Maybe that's the reason...
>
> Cheers,
> Stefan
>
> --
> You received this message because you are subscribed to the Google
> Groups "Hobo Users" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to hobousers+...@googlegroups.com
> <mailto:hobousers+...@googlegroups.com>.
> To post to this group, send email to hobo...@googlegroups.com
> <mailto:hobo...@googlegroups.com>.
> Visit this group at http://groups.google.com/group/hobousers.
> For more options, visit https://groups.google.com/d/optout.

Stefan Haslinger

unread,
May 21, 2014, 7:03:15 AM5/21/14
to hobo...@googlegroups.com
Hi folks,

I  just learned when updating to ruby 2.1.2 that debugger gem is not supporting ruby 2.x 
Byebug gem is the/a way to go. (https://github.com/deivid-rodriguez/byebug)

So to update using rvm you should:
rvm get stable
gem uninstall debugger
rvm upgrade 2.1.1 2.1.2
gem install byebug 

Without uninstalling debugger gem upgrade breaks.

Furthermore my dumps seem to have gone. Yeah!

Cheers,
Stefan

Ignacio Huerta

unread,
May 22, 2014, 3:06:10 AM5/22/14
to hobo...@googlegroups.com
Nice tip Stefan!

El 21/05/14 13:03, Stefan Haslinger escribió:
Reply all
Reply to author
Forward
0 new messages