After upgrading to Rails 7 executing this command opens rdb debug console:
EDITOR=nano rails credentials:edit --environment production
Output:
$ EDITOR=nano rails credentials:edit --environment production
/home/ubuntu/.rbenv/versions/3.0.0/lib/ruby/3.0.0/x86_64-linux/continuation.so: warning: callcc is obsolete; use Fiber instead
Debug.rb
Emacs support available.
/home/ubuntu/.rbenv/versions/3.0.0/lib/ruby/gems/3.0.0/gems/bootsnap-1.12.0/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:31: Bootsnap::LoadPathCache.loaded_features_index.register(string_path, resolved)
(rdb:1)
If I type exit
I get this:
/home/ubuntu/.rbenv/versions/3.0.0/lib/ruby/3.0.0/debug.rb:240:in `synchronize': deadlock; recursive locking (ThreadError)
from /home/ubuntu/.rbenv/versions/3.0.0/lib/ruby/3.0.0/debug.rb:240:in `check_suspend'
from /home/ubuntu/.rbenv/versions/3.0.0/lib/ruby/3.0.0/debug.rb:838:in `trace_func'
from /home/ubuntu/.rbenv/versions/3.0.0/lib/ruby/3.0.0/debug.rb:1104:in `block in <class:DEBUGGER__>'
from /home/ubuntu/.rbenv/versions/3.0.0/lib/ruby/gems/3.0.0/gems/bootsnap-1.12.0/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in `require'
from bin/rails:4:in `<main>'
Why it's not working?
CodePudding user response:
Use this command instead:
EDITOR=nano RAILS_ENV=production rails credentials:edit
CodePudding user response:
I find it is necessary to quote the EDITOR value to ensure it is a string.
EDITOR='nano' rails credentials:edit --environment production