Testing issues due to credentials (ActiveSupport::MessageEncryptor::InvalidMessage) - ruby-on-rails

I'm having a problem with a project I recently cloned. When I run the rspec or rails test commands, everything works. On the other hand, if I want to run rails test:system, an error appears:
rails test:system
/Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/activesupport-7.0.2.3/lib/active_support/message_encryptor.rb:208:in `rescue in _decrypt': ActiveSupport::MessageEncryptor::InvalidMessage (ActiveSupport::MessageEncryptor::InvalidMessage)
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/activesupport-7.0.2.3/lib/active_support/message_encryptor.rb:185:in `_decrypt'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/activesupport-7.0.2.3/lib/active_support/message_encryptor.rb:159:in `decrypt_and_verify'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/activesupport-7.0.2.3/lib/active_support/messages/rotator.rb:22:in `decrypt_and_verify'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/activesupport-7.0.2.3/lib/active_support/encrypted_file.rb:92:in `decrypt'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/activesupport-7.0.2.3/lib/active_support/encrypted_file.rb:54:in `read'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/activesupport-7.0.2.3/lib/active_support/encrypted_configuration.rb:21:in `read'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/activesupport-7.0.2.3/lib/active_support/encrypted_configuration.rb:33:in `config'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/activesupport-7.0.2.3/lib/active_support/encrypted_configuration.rb:48:in `options'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/activesupport-7.0.2.3/lib/active_support/core_ext/module/delegation.rb:303:in `method_missing'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/activerecord-7.0.2.3/lib/active_record/railtie.rb:342:in `block in <class:Railtie>'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.2.3/lib/rails/initializable.rb:32:in `instance_exec'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.2.3/lib/rails/initializable.rb:32:in `run'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.2.3/lib/rails/initializable.rb:61:in `block in run_initializers'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/3.0.0/tsort.rb:228:in `block in tsort_each'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/3.0.0/tsort.rb:350:in `block (2 levels) in each_strongly_connected_component'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/3.0.0/tsort.rb:431:in `each_strongly_connected_component_from'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/3.0.0/tsort.rb:349:in `block in each_strongly_connected_component'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/3.0.0/tsort.rb:347:in `each'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/3.0.0/tsort.rb:347:in `call'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/3.0.0/tsort.rb:347:in `each_strongly_connected_component'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/3.0.0/tsort.rb:226:in `tsort_each'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/3.0.0/tsort.rb:205:in `tsort_each'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.2.3/lib/rails/initializable.rb:60:in `run_initializers'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.2.3/lib/rails/application.rb:372:in `initialize!'
from /Users/robin/freelance-projects/xxxx/config/environment.rb:5:in `<main>'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `require'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `block in require_with_bootsnap_lfi'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/loaded_features_index.rb:100:in `register'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require_with_bootsnap_lfi'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:31:in `require'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:54:in `require_relative'
from /Users/robin/freelance-projects/xxxx/test/test_helper.rb:2:in `<main>'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `require'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `block in require_with_bootsnap_lfi'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/loaded_features_index.rb:100:in `register'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require_with_bootsnap_lfi'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:31:in `require'
from /Users/robin/freelance-projects/xxxx/test/channels/application_cable/connection_test.rb:1:in `<main>'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `require'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `block in require_with_bootsnap_lfi'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/loaded_features_index.rb:100:in `register'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require_with_bootsnap_lfi'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:31:in `require'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.2.3/lib/rails/test_unit/runner.rb:47:in `block in load_tests'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.2.3/lib/rails/test_unit/runner.rb:47:in `each'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.2.3/lib/rails/test_unit/runner.rb:47:in `load_tests'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.2.3/lib/rails/test_unit/runner.rb:40:in `run'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.2.3/lib/rails/commands/test/test_command.rb:33:in `perform'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/thor-1.2.1/lib/thor/command.rb:27:in `run'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/thor-1.2.1/lib/thor/invocation.rb:127:in `invoke_command'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/thor-1.2.1/lib/thor.rb:392:in `dispatch'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.2.3/lib/rails/command/base.rb:87:in `perform'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.2.3/lib/rails/command.rb:48:in `invoke'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.2.3/lib/rails/commands.rb:18:in `<main>'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `require'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `block in require_with_bootsnap_lfi'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/loaded_features_index.rb:100:in `register'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require_with_bootsnap_lfi'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:31:in `require'
from bin/rails:4:in `<main>'
/Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/activesupport-7.0.2.3/lib/active_support/message_encryptor.rb:203:in `final': OpenSSL::Cipher::CipherError
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/activesupport-7.0.2.3/lib/active_support/message_encryptor.rb:203:in `_decrypt'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/activesupport-7.0.2.3/lib/active_support/message_encryptor.rb:159:in `decrypt_and_verify'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/activesupport-7.0.2.3/lib/active_support/messages/rotator.rb:22:in `decrypt_and_verify'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/activesupport-7.0.2.3/lib/active_support/encrypted_file.rb:92:in `decrypt'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/activesupport-7.0.2.3/lib/active_support/encrypted_file.rb:54:in `read'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/activesupport-7.0.2.3/lib/active_support/encrypted_configuration.rb:21:in `read'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/activesupport-7.0.2.3/lib/active_support/encrypted_configuration.rb:33:in `config'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/activesupport-7.0.2.3/lib/active_support/encrypted_configuration.rb:48:in `options'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/activesupport-7.0.2.3/lib/active_support/core_ext/module/delegation.rb:303:in `method_missing'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/activerecord-7.0.2.3/lib/active_record/railtie.rb:342:in `block in <class:Railtie>'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.2.3/lib/rails/initializable.rb:32:in `instance_exec'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.2.3/lib/rails/initializable.rb:32:in `run'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.2.3/lib/rails/initializable.rb:61:in `block in run_initializers'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/3.0.0/tsort.rb:228:in `block in tsort_each'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/3.0.0/tsort.rb:350:in `block (2 levels) in each_strongly_connected_component'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/3.0.0/tsort.rb:431:in `each_strongly_connected_component_from'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/3.0.0/tsort.rb:349:in `block in each_strongly_connected_component'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/3.0.0/tsort.rb:347:in `each'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/3.0.0/tsort.rb:347:in `call'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/3.0.0/tsort.rb:347:in `each_strongly_connected_component'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/3.0.0/tsort.rb:226:in `tsort_each'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/3.0.0/tsort.rb:205:in `tsort_each'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.2.3/lib/rails/initializable.rb:60:in `run_initializers'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.2.3/lib/rails/application.rb:372:in `initialize!'
from /Users/robin/freelance-projects/xxxx/config/environment.rb:5:in `<main>'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `require'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `block in require_with_bootsnap_lfi'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/loaded_features_index.rb:100:in `register'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require_with_bootsnap_lfi'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:31:in `require'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:54:in `require_relative'
from /Users/robin/freelance-projects/xxxx/test/test_helper.rb:2:in `<main>'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `require'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `block in require_with_bootsnap_lfi'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/loaded_features_index.rb:100:in `register'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require_with_bootsnap_lfi'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:31:in `require'
from /Users/robin/freelance-projects/xxxx/test/channels/application_cable/connection_test.rb:1:in `<main>'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `require'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `block in require_with_bootsnap_lfi'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/loaded_features_index.rb:100:in `register'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require_with_bootsnap_lfi'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:31:in `require'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.2.3/lib/rails/test_unit/runner.rb:47:in `block in load_tests'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.2.3/lib/rails/test_unit/runner.rb:47:in `each'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.2.3/lib/rails/test_unit/runner.rb:47:in `load_tests'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.2.3/lib/rails/test_unit/runner.rb:40:in `run'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.2.3/lib/rails/commands/test/test_command.rb:33:in `perform'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/thor-1.2.1/lib/thor/command.rb:27:in `run'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/thor-1.2.1/lib/thor/invocation.rb:127:in `invoke_command'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/thor-1.2.1/lib/thor.rb:392:in `dispatch'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.2.3/lib/rails/command/base.rb:87:in `perform'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.2.3/lib/rails/command.rb:48:in `invoke'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.2.3/lib/rails/commands.rb:18:in `<main>'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `require'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `block in require_with_bootsnap_lfi'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/loaded_features_index.rb:100:in `register'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require_with_bootsnap_lfi'
from /Users/robin/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:31:in `require'
from bin/rails:4:in `<main>'
I of course thought of a problem of credentials keys. The master key is the same as my colleagues. I deleted config/credentials.yml.enc and config/credentials/test.yml.enc, then I did the command EDITOR=nano rails credentials:edit and EDITOR=nano rails credentials:edit -e test, in order to recreate the files (config/master.key is not needed because I have an environment variable RAILS_MASTER_KEY).
After that, the system tests were working, but the others weren't working anymore, with the same error...
I no longer know where to look. I have exactly the same project as my colleagues. I copied/pasted the contents of their .env, their master key, the contents of their config/credentials.yml.enc and config/credentials/test.yml.enc files, but nothing to do, it doesn't want to work. I then reinstalled ruby, the gems and the app, in doubt, but that didn't work either.
Our stack:
ruby 3.0.3p157
rails 7.0.2.3
Has anyone come across this problem before? Any idea?
Thanks

To solve ActiveSupport::MessageEncryptor::InvalidMessage error in a rails application. Here is what we should do;
Delete the following files; config/master.key and config/credentails.yml.enc
Next, run the following command in code editor terminal EDITOR="mate --wait" bin/rails credentials:edit
Solved, now test and see if it is resolved
Thank you and I hope it helps, kindly reach out if you find otherwise

Related

Rails 7 - uninitialized constant Impressionist::Engine::ImpressionistController (NameError)

After upgrading to rails 7 I'm getting below error with the impressionist gem. When I start my local server.
Any help, please?
uninitialized constant Impressionist::Engine::ImpressionistController (NameError)
ruby "~> 3.0.1"
gem "rails", "~> 7.0.0"
gem "impressionist", git:
"https://github.com/charlotte-ruby/impressionist
I did bundle install and restarted rails server.
=> Booting Puma
=> Rails 7.0.1 application starting in development
=> Run `bin/rails server --help` for more startup options
Exiting
/Users/XXXX/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/bundler/gems/impressionist-e0db056a2ac0/lib/impressionist/engine.rb:15:in `block (2 levels) in <class:Engine>': uninitialized constant Impressionist::Engine::ImpressionistController (NameError)
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/activesupport-7.0.1/lib/active_support/lazy_load_hooks.rb:71:in `class_eval'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/activesupport-7.0.1/lib/active_support/lazy_load_hooks.rb:71:in `block in execute_hook'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/activesupport-7.0.1/lib/active_support/lazy_load_hooks.rb:61:in `with_execution_control'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/activesupport-7.0.1/lib/active_support/lazy_load_hooks.rb:66:in `execute_hook'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/activesupport-7.0.1/lib/active_support/lazy_load_hooks.rb:43:in `block in on_load'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/activesupport-7.0.1/lib/active_support/lazy_load_hooks.rb:42:in `each'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/activesupport-7.0.1/lib/active_support/lazy_load_hooks.rb:42:in `on_load'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/bundler/gems/impressionist-e0db056a2ac0/lib/impressionist/engine.rb:14:in `block in <class:Engine>'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.1/lib/rails/initializable.rb:32:in `instance_exec'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.1/lib/rails/initializable.rb:32:in `run'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.1/lib/rails/initializable.rb:61:in `block in run_initializers'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/3.0.0/tsort.rb:228:in `block in tsort_each'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/3.0.0/tsort.rb:350:in `block (2 levels) in each_strongly_connected_component'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/3.0.0/tsort.rb:431:in `each_strongly_connected_component_from'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/3.0.0/tsort.rb:349:in `block in each_strongly_connected_component'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/3.0.0/tsort.rb:347:in `each'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/3.0.0/tsort.rb:347:in `call'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/3.0.0/tsort.rb:347:in `each_strongly_connected_component'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/3.0.0/tsort.rb:226:in `tsort_each'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/3.0.0/tsort.rb:205:in `tsort_each'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.1/lib/rails/initializable.rb:60:in `run_initializers'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.1/lib/rails/application.rb:372:in `initialize!'
from /Users/xxxx/Dev/pro/config/environment.rb:5:in `<main>'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `require'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `block in require_with_bootsnap_lfi'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/loaded_features_index.rb:100:in `register'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require_with_bootsnap_lfi'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:31:in `require'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/zeitwerk-2.5.3/lib/zeitwerk/kernel.rb:35:in `require'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:54:in `require_relative'
from config.ru:3:in `block in <main>'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/rack-2.2.3/lib/rack/builder.rb:116:in `eval'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/rack-2.2.3/lib/rack/builder.rb:116:in `new_from_string'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/rack-2.2.3/lib/rack/builder.rb:105:in `load_file'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/rack-2.2.3/lib/rack/builder.rb:66:in `parse_file'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/rack-2.2.3/lib/rack/server.rb:349:in `build_app_and_options_from_config'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/rack-2.2.3/lib/rack/server.rb:249:in `app'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/rack-2.2.3/lib/rack/server.rb:422:in `wrapped_app'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.1/lib/rails/commands/server/server_command.rb:76:in `log_to_stdout'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.1/lib/rails/commands/server/server_command.rb:36:in `start'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.1/lib/rails/commands/server/server_command.rb:143:in `block in perform'
from <internal:kernel>:90:in `tap'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.1/lib/rails/commands/server/server_command.rb:134:in `perform'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/thor-1.2.1/lib/thor/command.rb:27:in `run'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/thor-1.2.1/lib/thor/invocation.rb:127:in `invoke_command'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/thor-1.2.1/lib/thor.rb:392:in `dispatch'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.1/lib/rails/command/base.rb:87:in `perform'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.1/lib/rails/command.rb:48:in `invoke'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/railties-7.0.1/lib/rails/commands.rb:18:in `<main>'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `require'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `block in require_with_bootsnap_lfi'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/loaded_features_index.rb:100:in `register'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require_with_bootsnap_lfi'
from /Users/xxxx/.rbenv/versions/3.0.3/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:31:in `require'
from bin/rails:4:in `<main>'
Try this:
# add to application.rb at the top
impressionist_dir = Gem::Specification.find_by_name('impressionist').gem_dir
require File.join(impressionist_dir, '/app/controllers/impressionist_controller.rb')

Poppler + Rails gives me an error on M1 Mac

App I am working on has Poppler as a gem. When I try to run the rails server after bundle install I get the following;
/Users/me/.rvm/gems/ruby-2.7.3/gems/poppler-3.4.4/lib/poppler/loader.rb:93:in `define_struct':
uninitialized constant Poppler::Loader::Action (NameError)
And I'm completely stuck.
I have attempted to brew install poppler which seemed to work fine, but the error is the same. All of my gems are up to date. My OS is up to date.
Others in my company aren't having this issue.
I'm terrible at solving this sort of things.. thoughts?
And to be through here is a complete error dump from rails s to exit:
(NULL)-WARNING **: Failed to load shared library 'libpoppler-glib.8.dylib' referenced by the typelib: dlopen(libpoppler-glib.8.dylib, 9): image not found
from /Users/me/.rvm/gems/ruby-2.7.3/gems/gobject-introspection-3.4.4/lib/gobject-introspection/loader.rb:561:in `load_union_info'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/gobject-introspection-3.4.4/lib/gobject-introspection/loader.rb:74:in `load_info'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/gobject-introspection-3.4.4/lib/gobject-introspection/loader.rb:43:in `block in load'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/gobject-introspection-3.4.4/lib/gobject-introspection/repository.rb:34:in `block (2 levels) in each'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/gobject-introspection-3.4.4/lib/gobject-introspection/repository.rb:33:in `times'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/gobject-introspection-3.4.4/lib/gobject-introspection/repository.rb:33:in `block in each'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/gobject-introspection-3.4.4/lib/gobject-introspection/repository.rb:32:in `each'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/gobject-introspection-3.4.4/lib/gobject-introspection/repository.rb:32:in `each'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/gobject-introspection-3.4.4/lib/gobject-introspection/loader.rb:42:in `load'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/poppler-3.4.4/lib/poppler.rb:27:in `<module:Poppler>'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/poppler-3.4.4/lib/poppler.rb:22:in `<main>'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `require'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `block in require_with_bootsnap_lfi'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require_with_bootsnap_lfi'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:31:in `require'
from /Users/me/.rvm/rubies/ruby-2.7.3/lib/ruby/site_ruby/2.7.0/bundler/runtime.rb:66:in `block (2 levels) in require'
from /Users/me/.rvm/rubies/ruby-2.7.3/lib/ruby/site_ruby/2.7.0/bundler/runtime.rb:61:in `each'
from /Users/me/.rvm/rubies/ruby-2.7.3/lib/ruby/site_ruby/2.7.0/bundler/runtime.rb:61:in `block in require'
from /Users/me/.rvm/rubies/ruby-2.7.3/lib/ruby/site_ruby/2.7.0/bundler/runtime.rb:50:in `each'
from /Users/me/.rvm/rubies/ruby-2.7.3/lib/ruby/site_ruby/2.7.0/bundler/runtime.rb:50:in `require'
from /Users/me/.rvm/rubies/ruby-2.7.3/lib/ruby/site_ruby/2.7.0/bundler.rb:173:in `require'
from /Users/me/Sites/ambiki/config/application.rb:7:in `<main>'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `require'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `block in require_with_bootsnap_lfi'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require_with_bootsnap_lfi'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:31:in `require'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/activesupport-6.1.3.2/lib/active_support/dependencies.rb:332:in `block in require'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/activesupport-6.1.3.2/lib/active_support/dependencies.rb:299:in `load_dependency'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/activesupport-6.1.3.2/lib/active_support/dependencies.rb:332:in `require'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/railties-6.1.3.2/lib/rails/commands/server/server_command.rb:138:in `block in perform'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/railties-6.1.3.2/lib/rails/commands/server/server_command.rb:135:in `tap'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/railties-6.1.3.2/lib/rails/commands/server/server_command.rb:135:in `perform'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/thor-1.1.0/lib/thor/command.rb:27:in `run'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/thor-1.1.0/lib/thor/invocation.rb:127:in `invoke_command'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/thor-1.1.0/lib/thor.rb:392:in `dispatch'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/railties-6.1.3.2/lib/rails/command/base.rb:69:in `perform'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/railties-6.1.3.2/lib/rails/command.rb:50:in `invoke'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/railties-6.1.3.2/lib/rails/commands.rb:18:in `<main>'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `require'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `block in require_with_bootsnap_lfi'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require_with_bootsnap_lfi'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:31:in `require'
from /Users/me/Sites/ambiki/bin/rails:9:in `<top (required)>'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/spring-2.1.1/lib/spring/client/rails.rb:28:in `load'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/spring-2.1.1/lib/spring/client/rails.rb:28:in `call'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/spring-2.1.1/lib/spring/client/command.rb:7:in `call'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/spring-2.1.1/lib/spring/client.rb:30:in `run'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/spring-2.1.1/bin/spring:49:in `<top (required)>'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/spring-2.1.1/lib/spring/binstub.rb:11:in `load'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/spring-2.1.1/lib/spring/binstub.rb:11:in `<top (required)>'
from /Users/me/Sites/ambiki/bin/spring:15:in `require'
from /Users/me/Sites/ambiki/bin/spring:15:in `<top (required)>'
from bin/rails:3:in `load'
from bin/rails:3:in `<main>'
(NULL)-WARNING **: Failed to load shared library 'libpoppler.111.dylib' referenced by the typelib: dlopen(libpoppler.111.dylib, 9): image not found
from /Users/me/.rvm/gems/ruby-2.7.3/gems/gobject-introspection-3.4.4/lib/gobject-introspection/loader.rb:561:in `load_union_info'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/gobject-introspection-3.4.4/lib/gobject-introspection/loader.rb:74:in `load_info'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/gobject-introspection-3.4.4/lib/gobject-introspection/loader.rb:43:in `block in load'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/gobject-introspection-3.4.4/lib/gobject-introspection/repository.rb:34:in `block (2 levels) in each'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/gobject-introspection-3.4.4/lib/gobject-introspection/repository.rb:33:in `times'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/gobject-introspection-3.4.4/lib/gobject-introspection/repository.rb:33:in `block in each'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/gobject-introspection-3.4.4/lib/gobject-introspection/repository.rb:32:in `each'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/gobject-introspection-3.4.4/lib/gobject-introspection/repository.rb:32:in `each'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/gobject-introspection-3.4.4/lib/gobject-introspection/loader.rb:42:in `load'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/poppler-3.4.4/lib/poppler.rb:27:in `<module:Poppler>'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/poppler-3.4.4/lib/poppler.rb:22:in `<main>'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `require'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `block in require_with_bootsnap_lfi'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require_with_bootsnap_lfi'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:31:in `require'
from /Users/me/.rvm/rubies/ruby-2.7.3/lib/ruby/site_ruby/2.7.0/bundler/runtime.rb:66:in `block (2 levels) in require'
from /Users/me/.rvm/rubies/ruby-2.7.3/lib/ruby/site_ruby/2.7.0/bundler/runtime.rb:61:in `each'
from /Users/me/.rvm/rubies/ruby-2.7.3/lib/ruby/site_ruby/2.7.0/bundler/runtime.rb:61:in `block in require'
from /Users/me/.rvm/rubies/ruby-2.7.3/lib/ruby/site_ruby/2.7.0/bundler/runtime.rb:50:in `each'
from /Users/me/.rvm/rubies/ruby-2.7.3/lib/ruby/site_ruby/2.7.0/bundler/runtime.rb:50:in `require'
from /Users/me/.rvm/rubies/ruby-2.7.3/lib/ruby/site_ruby/2.7.0/bundler.rb:173:in `require'
from /Users/me/Sites/ambiki/config/application.rb:7:in `<main>'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `require'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `block in require_with_bootsnap_lfi'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require_with_bootsnap_lfi'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:31:in `require'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/activesupport-6.1.3.2/lib/active_support/dependencies.rb:332:in `block in require'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/activesupport-6.1.3.2/lib/active_support/dependencies.rb:299:in `load_dependency'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/activesupport-6.1.3.2/lib/active_support/dependencies.rb:332:in `require'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/railties-6.1.3.2/lib/rails/commands/server/server_command.rb:138:in `block in perform'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/railties-6.1.3.2/lib/rails/commands/server/server_command.rb:135:in `tap'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/railties-6.1.3.2/lib/rails/commands/server/server_command.rb:135:in `perform'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/thor-1.1.0/lib/thor/command.rb:27:in `run'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/thor-1.1.0/lib/thor/invocation.rb:127:in `invoke_command'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/thor-1.1.0/lib/thor.rb:392:in `dispatch'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/railties-6.1.3.2/lib/rails/command/base.rb:69:in `perform'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/railties-6.1.3.2/lib/rails/command.rb:50:in `invoke'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/railties-6.1.3.2/lib/rails/commands.rb:18:in `<main>'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `require'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `block in require_with_bootsnap_lfi'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require_with_bootsnap_lfi'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:31:in `require'
from /Users/me/Sites/ambiki/bin/rails:9:in `<top (required)>'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/spring-2.1.1/lib/spring/client/rails.rb:28:in `load'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/spring-2.1.1/lib/spring/client/rails.rb:28:in `call'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/spring-2.1.1/lib/spring/client/command.rb:7:in `call'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/spring-2.1.1/lib/spring/client.rb:30:in `run'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/spring-2.1.1/bin/spring:49:in `<top (required)>'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/spring-2.1.1/lib/spring/binstub.rb:11:in `load'
from /Users/me/.rvm/gems/ruby-2.7.3/gems/spring-2.1.1/lib/spring/binstub.rb:11:in `<top (required)>'
from /Users/me/Sites/ambiki/bin/spring:15:in `require'
from /Users/me/Sites/ambiki/bin/spring:15:in `<top (required)>'
from bin/rails:3:in `load'
from bin/rails:3:in `<main>'
Traceback (most recent call last):
54: from bin/rails:3:in `<main>'
53: from bin/rails:3:in `load'
52: from /Users/me/Sites/ambiki/bin/spring:15:in `<top (required)>'
51: from /Users/me/Sites/ambiki/bin/spring:15:in `require'
50: from /Users/me/.rvm/gems/ruby-2.7.3/gems/spring-2.1.1/lib/spring/binstub.rb:11:in `<top (required)>'
49: from /Users/me/.rvm/gems/ruby-2.7.3/gems/spring-2.1.1/lib/spring/binstub.rb:11:in `load'
48: from /Users/me/.rvm/gems/ruby-2.7.3/gems/spring-2.1.1/bin/spring:49:in `<top (required)>'
47: from /Users/me/.rvm/gems/ruby-2.7.3/gems/spring-2.1.1/lib/spring/client.rb:30:in `run'
46: from /Users/me/.rvm/gems/ruby-2.7.3/gems/spring-2.1.1/lib/spring/client/command.rb:7:in `call'
45: from /Users/me/.rvm/gems/ruby-2.7.3/gems/spring-2.1.1/lib/spring/client/rails.rb:28:in `call'
44: from /Users/me/.rvm/gems/ruby-2.7.3/gems/spring-2.1.1/lib/spring/client/rails.rb:28:in `load'
43: from /Users/me/Sites/ambiki/bin/rails:9:in `<top (required)>'
42: from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:31:in `require'
41: from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require_with_bootsnap_lfi'
40: from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register'
39: from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `block in require_with_bootsnap_lfi'
38: from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `require'
37: from /Users/me/.rvm/gems/ruby-2.7.3/gems/railties-6.1.3.2/lib/rails/commands.rb:18:in `<main>'
36: from /Users/me/.rvm/gems/ruby-2.7.3/gems/railties-6.1.3.2/lib/rails/command.rb:50:in `invoke'
35: from /Users/me/.rvm/gems/ruby-2.7.3/gems/railties-6.1.3.2/lib/rails/command/base.rb:69:in `perform'
34: from /Users/me/.rvm/gems/ruby-2.7.3/gems/thor-1.1.0/lib/thor.rb:392:in `dispatch'
33: from /Users/me/.rvm/gems/ruby-2.7.3/gems/thor-1.1.0/lib/thor/invocation.rb:127:in `invoke_command'
32: from /Users/me/.rvm/gems/ruby-2.7.3/gems/thor-1.1.0/lib/thor/command.rb:27:in `run'
31: from /Users/me/.rvm/gems/ruby-2.7.3/gems/railties-6.1.3.2/lib/rails/commands/server/server_command.rb:135:in `perform'
30: from /Users/me/.rvm/gems/ruby-2.7.3/gems/railties-6.1.3.2/lib/rails/commands/server/server_command.rb:135:in `tap'
29: from /Users/me/.rvm/gems/ruby-2.7.3/gems/railties-6.1.3.2/lib/rails/commands/server/server_command.rb:138:in `block in perform'
28: from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:31:in `require'
27: from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require_with_bootsnap_lfi'
26: from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register'
25: from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `block in require_with_bootsnap_lfi'
24: from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `require'
23: from /Users/me/Sites/ambiki/config/application.rb:7:in `<main>'
22: from /Users/me/.rvm/rubies/ruby-2.7.3/lib/ruby/site_ruby/2.7.0/bundler.rb:173:in `require'
21: from /Users/me/.rvm/rubies/ruby-2.7.3/lib/ruby/site_ruby/2.7.0/bundler/runtime.rb:50:in `require'
20: from /Users/me/.rvm/rubies/ruby-2.7.3/lib/ruby/site_ruby/2.7.0/bundler/runtime.rb:50:in `each'
19: from /Users/me/.rvm/rubies/ruby-2.7.3/lib/ruby/site_ruby/2.7.0/bundler/runtime.rb:61:in `block in require'
18: from /Users/me/.rvm/rubies/ruby-2.7.3/lib/ruby/site_ruby/2.7.0/bundler/runtime.rb:61:in `each'
17: from /Users/me/.rvm/rubies/ruby-2.7.3/lib/ruby/site_ruby/2.7.0/bundler/runtime.rb:66:in `block (2 levels) in require'
16: from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:31:in `require'
15: from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require_with_bootsnap_lfi'
14: from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register'
13: from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `block in require_with_bootsnap_lfi'
12: from /Users/me/.rvm/gems/ruby-2.7.3/gems/bootsnap-1.7.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `require'
11: from /Users/me/.rvm/gems/ruby-2.7.3/gems/poppler-3.4.4/lib/poppler.rb:22:in `<main>'
10: from /Users/me/.rvm/gems/ruby-2.7.3/gems/poppler-3.4.4/lib/poppler.rb:27:in `<module:Poppler>'
9: from /Users/me/.rvm/gems/ruby-2.7.3/gems/gobject-introspection-3.4.4/lib/gobject-introspection/loader.rb:42:in `load'
8: from /Users/me/.rvm/gems/ruby-2.7.3/gems/gobject-introspection-3.4.4/lib/gobject-introspection/repository.rb:32:in `each'
7: from /Users/me/.rvm/gems/ruby-2.7.3/gems/gobject-introspection-3.4.4/lib/gobject-introspection/repository.rb:32:in `each'
6: from /Users/me/.rvm/gems/ruby-2.7.3/gems/gobject-introspection-3.4.4/lib/gobject-introspection/repository.rb:33:in `block in each'
5: from /Users/me/.rvm/gems/ruby-2.7.3/gems/gobject-introspection-3.4.4/lib/gobject-introspection/repository.rb:33:in `times'
4: from /Users/me/.rvm/gems/ruby-2.7.3/gems/gobject-introspection-3.4.4/lib/gobject-introspection/repository.rb:34:in `block (2 levels) in each'
3: from /Users/me/.rvm/gems/ruby-2.7.3/gems/gobject-introspection-3.4.4/lib/gobject-introspection/loader.rb:43:in `block in load'
2: from /Users/me/.rvm/gems/ruby-2.7.3/gems/gobject-introspection-3.4.4/lib/gobject-introspection/loader.rb:60:in `load_info'
1: from /Users/me/.rvm/gems/ruby-2.7.3/gems/gobject-introspection-3.4.4/lib/gobject-introspection/loader.rb:137:in `load_struct_info'
/Users/me/.rvm/gems/ruby-2.7.3/gems/poppler-3.4.4/lib/poppler/loader.rb:93:in `define_struct': uninitialized constant Poppler::Loader::Action (NameError)
Okay after days of fighting with it. There is a weird homebrew issue (I think) where it installs the libraries required for poppler at /opt/homebrew/lib/ but it after digging it needs to be /usr/local/lib/ so a couple sim links later, it appears to be running now..

Rails aborted! ArgumentError: wrong number of arguments (given 0, expected 1..2)

I am trying to to do a production migration and get the above error. In Dev mode they work fine but when I try to migrate to production I get this error.
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/activesupport-5.2.4.1/lib/active_support/cache/file_store.rb:24:in `initialize'
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/activesupport-5.2.4.1/lib/active_support/cache.rb:60:in `new'
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/activesupport-5.2.4.1/lib/active_support/cache.rb:60:in `lookup_store'
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/railties-5.2.4.1/lib/rails/application/bootstrap.rb:67:in `block in <module:Bootstrap>'
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/railties-5.2.4.1/lib/rails/initializable.rb:32:in `instance_exec'
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/railties-5.2.4.1/lib/rails/initializable.rb:32:in `run'
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/railties-5.2.4.1/lib/rails/initializable.rb:61:in `block in run_initializers'
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/railties-5.2.4.1/lib/rails/initializable.rb:60:in `run_initializers'
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/railties-5.2.4.1/lib/rails/application.rb:361:in `initialize!'
/home/Steven.Cahill/Brighter/Adviser/config/environment.rb:7:in `<main>'
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require'
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `block in require_with_bootsnap_lfi'
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register'
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in `require_with_bootsnap_lfi'
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in `require'
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:291:in `block in require'
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:257:in `load_dependency'
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:291:in `require'
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/railties-5.2.4.1/lib/rails/application.rb:337:in `require_environment!'
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/railties-5.2.4.1/lib/rails/application.rb:520:in `block in run_tasks_blocks'
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/railties-5.2.4.1/lib/rails/commands/rake/rake_command.rb:23:in `block in perform'
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/railties-5.2.4.1/lib/rails/commands/rake/rake_command.rb:20:in `perform'
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/railties-5.2.4.1/lib/rails/command.rb:48:in `invoke'
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/railties-5.2.4.1/lib/rails/commands.rb:18:in `<main>'
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require'
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `block in require_with_bootsnap_lfi'
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register'
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in `require_with_bootsnap_lfi'
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/bootsnap-1.4.5/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in `require'
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:291:in `block in require'
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:257:in `load_dependency'
/home/Steven.Cahill/.rvm/gems/ruby-2.6.5/gems/activesupport-5.2.4.1/lib/active_support/dependencies.rb:291:in `require'
Check out Brighter/Adviser/config/environment.rb:7:in `'
This error indicates that rvm is having issues with requiring a few dependencies.
Check out your rvm setup
You need specify correctly number of arguments when call this command

Impossible to launch rails s after a scaffold regeneration

I've delete scaffolded files after a renaming my Company class to Organization, using:
rails destroy scaffold Company -f
then
rails generate scaffold Organization
From now, I can't run rails s and have the following errors:
rails s
=> Booting Puma
=> Rails 5.2.1 application starting in development
=> Run `rails server -h` for more startup options
Exiting
/.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/active_support.rb:74:in `block in load_missing_constant': uninitialized constant Organization (NameError)
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/active_support.rb:8:in `without_bootsnap_cache'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/active_support.rb:74:in `rescue in load_missing_constant'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/active_support.rb:56:in `load_missing_constant'
from /Projects/myapp/app/admin/organizations.rb:1:in `<main>'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:50:in `load'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:50:in `load'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/activeadmin-1.4.3/lib/active_admin/application.rb:130:in `block in load'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/activeadmin-1.4.3/lib/active_admin/error.rb:41:in `capture'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/activeadmin-1.4.3/lib/active_admin/application.rb:130:in `load'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/activeadmin-1.4.3/lib/active_admin/application.rb:122:in `block in load!'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/activeadmin-1.4.3/lib/active_admin/application.rb:122:in `each'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/activeadmin-1.4.3/lib/active_admin/application.rb:122:in `load!'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/activeadmin-1.4.3/lib/active_admin/application.rb:148:in `routes'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/activeadmin-1.4.3/lib/active_admin.rb:77:in `routes'
from /Projects/myapp/config/routes.rb:3:in `block in <main>'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/actionpack-5.2.1/lib/action_dispatch/routing/route_set.rb:432:in `instance_exec'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/actionpack-5.2.1/lib/action_dispatch/routing/route_set.rb:432:in `eval_block'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/actionpack-5.2.1/lib/action_dispatch/routing/route_set.rb:414:in `draw'
from /Projects/myapp/config/routes.rb:1:in `<main>'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:50:in `load'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:50:in `load'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/railties-5.2.1/lib/rails/application/routes_reloader.rb:41:in `block in load_paths'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/railties-5.2.1/lib/rails/application/routes_reloader.rb:41:in `each'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/railties-5.2.1/lib/rails/application/routes_reloader.rb:41:in `load_paths'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/railties-5.2.1/lib/rails/application/routes_reloader.rb:20:in `reload!'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/railties-5.2.1/lib/rails/application/routes_reloader.rb:30:in `block in updater'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/activesupport-5.2.1/lib/active_support/file_update_checker.rb:83:in `execute'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/railties-5.2.1/lib/rails/application/routes_reloader.rb:10:in `execute'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/railties-5.2.1/lib/rails/application/finisher.rb:130:in `block in <module:Finisher>'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/railties-5.2.1/lib/rails/initializable.rb:32:in `instance_exec'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/railties-5.2.1/lib/rails/initializable.rb:32:in `run'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/railties-5.2.1/lib/rails/initializable.rb:61:in `block in run_initializers'
from /.rbenv/versions/2.4.5/lib/ruby/2.4.0/tsort.rb:228:in `block in tsort_each'
from /.rbenv/versions/2.4.5/lib/ruby/2.4.0/tsort.rb:350:in `block (2 levels) in each_strongly_connected_component'
from /.rbenv/versions/2.4.5/lib/ruby/2.4.0/tsort.rb:431:in `each_strongly_connected_component_from'
from /.rbenv/versions/2.4.5/lib/ruby/2.4.0/tsort.rb:349:in `block in each_strongly_connected_component'
from /.rbenv/versions/2.4.5/lib/ruby/2.4.0/tsort.rb:347:in `each'
from /.rbenv/versions/2.4.5/lib/ruby/2.4.0/tsort.rb:347:in `call'
from /.rbenv/versions/2.4.5/lib/ruby/2.4.0/tsort.rb:347:in `each_strongly_connected_component'
from /.rbenv/versions/2.4.5/lib/ruby/2.4.0/tsort.rb:226:in `tsort_each'
from /.rbenv/versions/2.4.5/lib/ruby/2.4.0/tsort.rb:205:in `tsort_each'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/railties-5.2.1/lib/rails/initializable.rb:60:in `run_initializers'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/railties-5.2.1/lib/rails/application.rb:361:in `initialize!'
from /Projects/myapp/config/environment.rb:5:in `<main>'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in `require'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in `block in require_with_bootsnap_lfi'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/loaded_features_index.rb:65:in `register'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:20:in `require_with_bootsnap_lfi'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:29:in `require'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:44:in `require_relative'
from config.ru:3:in `block in <main>'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/rack-2.0.6/lib/rack/builder.rb:55:in `instance_eval'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/rack-2.0.6/lib/rack/builder.rb:55:in `initialize'
from config.ru:in `new'
from config.ru:in `<main>'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/rack-2.0.6/lib/rack/builder.rb:49:in `eval'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/rack-2.0.6/lib/rack/builder.rb:49:in `new_from_string'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/rack-2.0.6/lib/rack/builder.rb:40:in `parse_file'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/rack-2.0.6/lib/rack/server.rb:319:in `build_app_and_options_from_config'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/rack-2.0.6/lib/rack/server.rb:219:in `app'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/railties-5.2.1/lib/rails/commands/server/server_command.rb:27:in `app'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/rack-2.0.6/lib/rack/server.rb:354:in `wrapped_app'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/railties-5.2.1/lib/rails/commands/server/server_command.rb:89:in `log_to_stdout'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/railties-5.2.1/lib/rails/commands/server/server_command.rb:51:in `start'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/railties-5.2.1/lib/rails/commands/server/server_command.rb:147:in `block in perform'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/railties-5.2.1/lib/rails/commands/server/server_command.rb:142:in `tap'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/railties-5.2.1/lib/rails/commands/server/server_command.rb:142:in `perform'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/thor-0.20.3/lib/thor/command.rb:27:in `run'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/thor-0.20.3/lib/thor/invocation.rb:126:in `invoke_command'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/thor-0.20.3/lib/thor.rb:387:in `dispatch'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/railties-5.2.1/lib/rails/command/base.rb:65:in `perform'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/railties-5.2.1/lib/rails/command.rb:46:in `invoke'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/railties-5.2.1/lib/rails/commands.rb:18:in `<main>'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in `require'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in `block in require_with_bootsnap_lfi'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/loaded_features_index.rb:65:in `register'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:20:in `require_with_bootsnap_lfi'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:29:in `require'
from /Projects/myapp/bin/rails:9:in `<top (required)>'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/spring-2.0.2/lib/spring/client/rails.rb:28:in `load'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/spring-2.0.2/lib/spring/client/rails.rb:28:in `call'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/spring-2.0.2/lib/spring/client/command.rb:7:in `call'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/spring-2.0.2/lib/spring/client.rb:30:in `run'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/spring-2.0.2/bin/spring:49:in `<top (required)>'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/spring-2.0.2/lib/spring/binstub.rb:31:in `load'
from /.rbenv/versions/2.4.5/lib/ruby/gems/2.4.0/gems/spring-2.0.2/lib/spring/binstub.rb:31:in `<top (required)>'
from /.rbenv/versions/2.4.5/lib/ruby/2.4.0/rubygems/core_ext/kernel_require.rb:68:in `require'
from /.rbenv/versions/2.4.5/lib/ruby/2.4.0/rubygems/core_ext/kernel_require.rb:68:in `require'
from /Projects/myapp/bin/spring:15:in `<top (required)>'
from bin/rails:3:in `load'
from bin/rails:3:in `<main>'
MacBook-Pro-de-Benjami$
Any clue?

Rails 5.2 fails to load in Production Environment

I'm trying to run my new app in production, but I get a strange error.
$ rails server --environment=production
=> Booting Puma
=> Rails 5.2.2 application starting in production
=> Run `rails server -h` for more startup options
Exiting
/Users/user/.rvm/gems/ruby-2.4.1/gems/activerecord-5.2.2/lib/active_record/dynamic_matchers.rb:22:in `method_missing': undefined method `has_one_attached' for #<Class:0x007fc50e4e3e70> (NoMethodError)
from /Users/user/.rvm/gems/ruby-2.4.1/gems/activestorage-5.2.2/app/models/active_storage/blob/representable.rb:7:in `block in <module:Representable>'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/activesupport-5.2.2/lib/active_support/concern.rb:122:in `class_eval'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/activesupport-5.2.2/lib/active_support/concern.rb:122:in `append_features'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/activestorage-5.2.2/app/models/active_storage/blob.rb:23:in `include'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/activestorage-5.2.2/app/models/active_storage/blob.rb:23:in `<class:Blob>'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/activestorage-5.2.2/app/models/active_storage/blob.rb:16:in `<main>'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in `require'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in `block in require_with_bootsnap_lfi'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/loaded_features_index.rb:65:in `register'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:20:in `require_with_bootsnap_lfi'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:29:in `require'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/activesupport-5.2.2/lib/active_support/dependencies.rb:291:in `block in require'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/activesupport-5.2.2/lib/active_support/dependencies.rb:257:in `load_dependency'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/activesupport-5.2.2/lib/active_support/dependencies.rb:291:in `require'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/activesupport-5.2.2/lib/active_support/dependencies.rb:378:in `block in require_or_load'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/activesupport-5.2.2/lib/active_support/dependencies.rb:37:in `block in load_interlock'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/activesupport-5.2.2/lib/active_support/dependencies/interlock.rb:14:in `block in loading'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/activesupport-5.2.2/lib/active_support/concurrency/share_lock.rb:151:in `exclusive'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/activesupport-5.2.2/lib/active_support/dependencies/interlock.rb:13:in `loading'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/activesupport-5.2.2/lib/active_support/dependencies.rb:37:in `load_interlock'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/activesupport-5.2.2/lib/active_support/dependencies.rb:356:in `require_or_load'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/active_support.rb:46:in `block in require_or_load'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/active_support.rb:16:in `allow_bootsnap_retry'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/active_support.rb:45:in `require_or_load'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/activesupport-5.2.2/lib/active_support/dependencies.rb:334:in `depend_on'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/active_support.rb:80:in `depend_on'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/activesupport-5.2.2/lib/active_support/dependencies.rb:246:in `require_dependency'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/railties-5.2.2/lib/rails/engine.rb:478:in `block (2 levels) in eager_load!'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/railties-5.2.2/lib/rails/engine.rb:477:in `each'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/railties-5.2.2/lib/rails/engine.rb:477:in `block in eager_load!'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/railties-5.2.2/lib/rails/engine.rb:475:in `each'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/railties-5.2.2/lib/rails/engine.rb:475:in `eager_load!'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/railties-5.2.2/lib/rails/engine.rb:356:in `eager_load!'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/railties-5.2.2/lib/rails/application/finisher.rb:69:in `each'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/railties-5.2.2/lib/rails/application/finisher.rb:69:in `block in <module:Finisher>'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/railties-5.2.2/lib/rails/initializable.rb:32:in `instance_exec'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/railties-5.2.2/lib/rails/initializable.rb:32:in `run'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/railties-5.2.2/lib/rails/initializable.rb:61:in `block in run_initializers'
from /Users/user/.rvm/rubies/ruby-2.4.1/lib/ruby/2.4.0/tsort.rb:228:in `block in tsort_each'
from /Users/user/.rvm/rubies/ruby-2.4.1/lib/ruby/2.4.0/tsort.rb:350:in `block (2 levels) in each_strongly_connected_component'
from /Users/user/.rvm/rubies/ruby-2.4.1/lib/ruby/2.4.0/tsort.rb:431:in `each_strongly_connected_component_from'
from /Users/user/.rvm/rubies/ruby-2.4.1/lib/ruby/2.4.0/tsort.rb:349:in `block in each_strongly_connected_component'
from /Users/user/.rvm/rubies/ruby-2.4.1/lib/ruby/2.4.0/tsort.rb:347:in `each'
from /Users/user/.rvm/rubies/ruby-2.4.1/lib/ruby/2.4.0/tsort.rb:347:in `call'
from /Users/user/.rvm/rubies/ruby-2.4.1/lib/ruby/2.4.0/tsort.rb:347:in `each_strongly_connected_component'
from /Users/user/.rvm/rubies/ruby-2.4.1/lib/ruby/2.4.0/tsort.rb:226:in `tsort_each'
from /Users/user/.rvm/rubies/ruby-2.4.1/lib/ruby/2.4.0/tsort.rb:205:in `tsort_each'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/railties-5.2.2/lib/rails/initializable.rb:60:in `run_initializers'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/railties-5.2.2/lib/rails/application.rb:361:in `initialize!'
from /Users/user/Projects/My App/app-name/config/environment.rb:5:in `<main>'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in `require'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in `block in require_with_bootsnap_lfi'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/loaded_features_index.rb:65:in `register'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:20:in `require_with_bootsnap_lfi'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:29:in `require'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/activesupport-5.2.2/lib/active_support/dependencies.rb:291:in `block in require'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/activesupport-5.2.2/lib/active_support/dependencies.rb:257:in `load_dependency'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/activesupport-5.2.2/lib/active_support/dependencies.rb:291:in `require'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:44:in `require_relative'
from config.ru:3:in `block in <main>'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/rack-2.0.6/lib/rack/builder.rb:55:in `instance_eval'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/rack-2.0.6/lib/rack/builder.rb:55:in `initialize'
from config.ru:in `new'
from config.ru:in `<main>'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/rack-2.0.6/lib/rack/builder.rb:49:in `eval'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/rack-2.0.6/lib/rack/builder.rb:49:in `new_from_string'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/rack-2.0.6/lib/rack/builder.rb:40:in `parse_file'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/rack-2.0.6/lib/rack/server.rb:319:in `build_app_and_options_from_config'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/rack-2.0.6/lib/rack/server.rb:219:in `app'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/railties-5.2.2/lib/rails/commands/server/server_command.rb:27:in `app'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/rack-2.0.6/lib/rack/server.rb:354:in `wrapped_app'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/rack-2.0.6/lib/rack/server.rb:283:in `start'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/railties-5.2.2/lib/rails/commands/server/server_command.rb:53:in `start'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/railties-5.2.2/lib/rails/commands/server/server_command.rb:147:in `block in perform'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/railties-5.2.2/lib/rails/commands/server/server_command.rb:142:in `tap'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/railties-5.2.2/lib/rails/commands/server/server_command.rb:142:in `perform'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/thor-0.20.3/lib/thor/command.rb:27:in `run'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/thor-0.20.3/lib/thor/invocation.rb:126:in `invoke_command'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/thor-0.20.3/lib/thor.rb:387:in `dispatch'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/railties-5.2.2/lib/rails/command/base.rb:65:in `perform'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/railties-5.2.2/lib/rails/command.rb:46:in `invoke'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/railties-5.2.2/lib/rails/commands.rb:18:in `<main>'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in `require'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:21:in `block in require_with_bootsnap_lfi'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/loaded_features_index.rb:65:in `register'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:20:in `require_with_bootsnap_lfi'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/bootsnap-1.3.2/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:29:in `require'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/activesupport-5.2.2/lib/active_support/dependencies.rb:291:in `block in require'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/activesupport-5.2.2/lib/active_support/dependencies.rb:257:in `load_dependency'
from /Users/user/.rvm/gems/ruby-2.4.1/gems/activesupport-5.2.2/lib/active_support/dependencies.rb:291:in `require'
from bin/rails:4:in `<main>'
The usual googling hasn't turned up and helpful answers. Does anyone have an idea of how I can get this to run in the production environment?
Interestingly, the stack trace points to line 5 of environment.rb, which hasn't changed from the default, but has this line.
Rails.application.initialize!
When I comment that out, the server finally starts, but the fails as soon as I load any page (obviously).
Any pointers would be greatly appreciated! I'm not using any has_one_attached methods in my app, so I’m not sure where to look next!
Whelp. You know what? It looks like it was down to my incorrect config on the production: section of the database.yml file.

Resources