Issue appears when using virtual attribute validation:
validates :agreement, acceptance: true
When removing it, assets precompilation no longer requires a database connection.
Any ideas how to save validation and do not precompile assets locally?
You have two options:
Prevent assets being precompiled when initializing your application in config/application.rb
config.assets.initialize_on_precompile = false
or allow them to be initialized and add the heroku labs user-env-compile:
heroku labs:enable user-env-compile -a myapp
Read more:
https://devcenter.heroku.com/articles/rails-asset-pipeline
https://devcenter.heroku.com/articles/labs-user-env-compile
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With