padrino / padrino-framework

Padrino is a full-stack ruby framework built upon Sinatra.
http://www.padrinorb.com
MIT License
3.37k stars 508 forks source link

NoMethodError: undefined method `config' for #<ActiveRecord::DatabaseConfigurations::HashConfig:0x0000555c961722d8> #2255

Closed chuckwagoncomputing closed 1 year ago

chuckwagoncomputing commented 2 years ago

I'm trying to create a new project. After using the configuration in #2238 I get this error when running bundle exec rake db:create

NoMethodError: undefined method `config' for #<ActiveRecord::DatabaseConfigurations::HashConfig:0x0000555c961722d8>
/home/webmaster/.rvm/gems/ruby-2.7.4/bundler/gems/padrino-framework-6288cd14022e/padrino-gen/lib/padrino-gen/padrino-tasks/activerecord.rb:432:in `block in with_database'
/home/webmaster/.rvm/gems/ruby-2.7.4/bundler/gems/padrino-framework-6288cd14022e/padrino-gen/lib/padrino-gen/padrino-tasks/activerecord.rb:431:in `each'
/home/webmaster/.rvm/gems/ruby-2.7.4/bundler/gems/padrino-framework-6288cd14022e/padrino-gen/lib/padrino-gen/padrino-tasks/activerecord.rb:431:in `with_database'
/home/webmaster/.rvm/gems/ruby-2.7.4/bundler/gems/padrino-framework-6288cd14022e/padrino-gen/lib/padrino-gen/padrino-tasks/activerecord.rb:36:in `block (2 levels) in <top (required)>'
/home/webmaster/.rvm/gems/ruby-2.7.4/gems/rake-13.0.6/exe/rake:27:in `<top (required)>'
/home/webmaster/.rvm/gems/ruby-2.7.4/bin/ruby_executable_hooks:22:in `eval'
/home/webmaster/.rvm/gems/ruby-2.7.4/bin/ruby_executable_hooks:22:in `<main>'
Tasks: TOP => db:create => ar:create
jkowens commented 1 year ago

This should be resolved in v0.15.2.