config/secrets.yml.encを更新してもAPIキーがnilのまま
console
$ rails c
Loading development environment(Rails 5.1.ホニャララ)
>> Rails.application.secrets
=>{:secret_key_base=>nil :secret_token=>nil}
実はconfig/environments/development.rbで「encrypted secretsを使うよ」って設定してやる必要があったらしい
config/environments/development.rb
Rails.application.configure do
(いろいろな設定)
...
config.read_encrypted_secrets = true ←これ
end