Skip to main content

rails generate devise:install hangs

Rails • Asked by Felender Hlungwani
58733e746bea4a0b6e0320684c9e6414

I ran into this issue today whilst I was trying to deploy jumpstart template into my Rails 5.2.1 App

When I ran rails generate devise:install nothing happened. No errors, no output – nothing. Normally, this completes in seconds. In the end I aborted the rails generate task with a Ctrl-C. I noticed that the following output was barfed out to the screen:

generate  devise:install

/Users/felendernukeri/.rvm/rubies/ruby-2.5.1/lib/ruby/2.5.0/fileutils.rb:90: warning: already initialized constant FileUtils::VERSION
/Users/felendernukeri/.rvm/gems/ruby-2.5.1/gems/fileutils-1.1.0/lib/fileutils.rb:92: warning: previous definition of VERSION was here
/Users/felendernukeri/.rvm/rubies/ruby-2.5.1/lib/ruby/2.5.0/fileutils.rb:1188: warning: already initialized constant FileUtils::Entry_::S_IF_DOOR
/Users/felendernukeri/.rvm/gems/ruby-2.5.1/gems/fileutils-1.1.0/lib/fileutils.rb:1267: warning: previous definition of S_IF_DOOR was here
/Users/felendernukeri/.rvm/rubies/ruby-2.5.1/lib/ruby/2.5.0/fileutils.rb:1446: warning: already initialized constant FileUtils::Entry_::DIRECTORY_TERM
/Users/felendernukeri/.rvm/gems/ruby-2.5.1/gems/fileutils-1.1.0/lib/fileutils.rb:1541: warning: previous definition of DIRECTORY_TERM was here
/Users/felendernukeri/.rvm/rubies/ruby-2.5.1/lib/ruby/2.5.0/fileutils.rb:1448: warning: already initialized constant FileUtils::Entry_::SYSCASE
/Users/felendernukeri/.rvm/gems/ruby-2.5.1/gems/fileutils-1.1.0/lib/fileutils.rb:1543: warning: previous definition of SYSCASE was here
/Users/felendernukeri/.rvm/rubies/ruby-2.5.1/lib/ruby/2.5.0/fileutils.rb:1501: warning: already initialized constant FileUtils::OPT_TABLE
/Users/felendernukeri/.rvm/gems/ruby-2.5.1/gems/fileutils-1.1.0/lib/fileutils.rb:1596: warning: previous definition of OPT_TABLE was here
/Users/felendernukeri/.rvm/rubies/ruby-2.5.1/lib/ruby/2.5.0/fileutils.rb:1555: warning: already initialized constant FileUtils::LOW_METHODS
/Users/felendernukeri/.rvm/gems/ruby-2.5.1/gems/fileutils-1.1.0/lib/fileutils.rb:1650: warning: previous definition of LOW_METHODS was here
/Users/felendernukeri/.rvm/rubies/ruby-2.5.1/lib/ruby/2.5.0/fileutils.rb:1562: warning: already initialized constant FileUtils::METHODS
/Users/felendernukeri/.rvm/gems/ruby-2.5.1/gems/fileutils-1.1.0/lib/fileutils.rb:1657: warning: previous definition of METHODS was here
RAILS_ENV=development environment is not defined in config/webpacker.yml, falling back to production environment
Running via Spring preloader in process 11760

Full errors:
https://imgur.com/S5OMubu
https://imgur.com/Lu5uo26
https://imgur.com/0gpv1ey
https://imgur.com/hLckCui

I didn’t think anything of this at first, and assumed I had a dodgy install of devise, or rails or something.

So I uninstalled and reinstalled devise, warden and rails – and reran rails generate devise:install.

Nothing happened. I hit Ctrl-C, and got the same


Ce795239ba5dd2384fc2f88ffaff5451

Try running "spring stop" in the new app folder, delete the folder, and then try again. Spring will cache files like that and do weird things.


58733e746bea4a0b6e0320684c9e6414

I resolved the problem by doing the following:

gem uninstall fileutils
Successfully uninstalled fileutils-1.1.0
gem update --default
Updating installed gems
Updating fileutils
Fetching: fileutils-1.1.0.gem (100%)
Successfully installed fileutils-1.1.0

Login or Create An Account to join the conversation.

Subscribe to the newsletter

Join 18,000+ developers who get early access to new screencasts, articles, guides, updates, and more.

By clicking this button, you agree to the GoRails Terms of Service and Privacy Policy.

More of a social being? We're also on Twitter and YouTube.