Skip to content

Update Rails reading and writing configurations to a modern standard - #44

Merged
kaisensan merged 2 commits into
enova:mainfrom
bubket:rails-7-update
Feb 9, 2026
Merged

kaisensan merged 2 commits into
enova:mainfrom
bubket:rails-7-update

Conversation

@bubket

@bubket bubket commented Sep 29, 2025

Copy link
Copy Markdown
Contributor

No description provided.

Comment thread lib/prodder/prodder.rake Outdated
task :load => dependencies do
as("superuser", in: ENV['RAILS_ENV'] || Rails.env) do
config = ActiveRecord::Base.configurations[ENV['RAILS_ENV'] || Rails.env].with_indifferent_access
config = ActiveRecord::Base.configurations.configs_for(env_name: ENV['RAILS_ENV'] || Rails.env).first.configuration_hash.with_indifferent_access

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't we use find_db_config instead?

Suggested change
config = ActiveRecord::Base.configurations.configs_for(env_name: ENV['RAILS_ENV'] || Rails.env).first.configuration_hash.with_indifferent_access
config = ActiveRecord::Base.configurations.find_db_config(ENV['RAILS_ENV'] || Rails.env).configuration_hash.with_indifferent_access

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

updated

@kaisensan kaisensan changed the title updating the rails configurations reading and writing to a modern standard Update Rails reading and writing configurations to a modern standard Feb 9, 2026
@kaisensan
kaisensan merged commit b48efa0 into enova:main Feb 9, 2026
15 of 16 checks passed
@kaisensan kaisensan mentioned this pull request Feb 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants