-
Notifications
You must be signed in to change notification settings - Fork 17
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Upgrade app configuration to Rails 7.1 #3500
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Commented below.
@@ -5,7 +5,7 @@ require "fileutils" | |||
APP_ROOT = File.expand_path("..", __dir__) | |||
|
|||
def system!(*args) | |||
system(*args) || abort("\n== Command #{args} failed ==") | |||
system(*args, exception: true) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Change made by Rails
@@ -1,4 +1,4 @@ | |||
ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../Gemfile", __dir__) | |||
|
|||
require "bundler/setup" # Set up gems listed in the Gemfile. | |||
require "bootsnap/setup" | |||
require "bootsnap/setup" # Speed up boot time by caching expensive operations. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This comment is from Rails.
@@ -6,7 +6,7 @@ | |||
# In the development environment your application's code is reloaded any time | |||
# it changes. This slows down response time but is perfect for development | |||
# since you don't have to restart the web server when you make code changes. | |||
config.cache_classes = false | |||
config.enable_reloading = true |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Rails changed the name of this option and reversed it, so enable_reloading=!cache_classes
@@ -47,6 +47,9 @@ | |||
# Tell Active Support which deprecation messages to disallow. | |||
config.active_support.disallowed_deprecation_warnings = [] | |||
|
|||
# Highlight code that enqueued background job in logs. | |||
config.active_job.verbose_enqueue_logs = true |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added by Rails.
@@ -56,6 +59,9 @@ | |||
# Annotate rendered view with file names. | |||
# config.action_view.annotate_rendered_view_with_filenames = true | |||
|
|||
# Raise error when a before_action's only/except options reference missing actions | |||
config.action_controller.raise_on_missing_callback_actions = true |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added by Rails.
logger.formatter = config.log_formatter | ||
config.logger = ActiveSupport::TaggedLogging.new(logger) | ||
end | ||
# Enable DNS rebinding protection and other `Host` header attacks. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added by Rails, commented by default.
@@ -8,8 +8,8 @@ | |||
Rails.application.configure do | |||
# Settings specified here will take precedence over those in config/application.rb. | |||
|
|||
# Turn false under Spring and add config.action_view.cache_template_loading = true. | |||
config.cache_classes = true | |||
# While tests run files are not watched, reloading is not necessary. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See above.
@@ -27,8 +27,8 @@ | |||
config.action_controller.perform_caching = false | |||
config.cache_store = :null_store | |||
|
|||
# Raise exceptions instead of rendering exception templates. | |||
config.action_dispatch.show_exceptions = false | |||
# Render exception templates for rescuable exceptions and raise for other exceptions. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
New Rails default for the test environment.
# f.usb :none | ||
# f.fullscreen :self | ||
# f.payment :self, "https://secure.example.com" | ||
# information see: https://developers.google.com/web/updates/2018/06/feature-policy |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Change by Rails.
@@ -54,4 +54,7 @@ | |||
|
|||
# Annotate rendered view with file names. | |||
# config.action_view.annotate_rendered_view_with_filenames = true | |||
|
|||
# Raise error when a before_action's only/except options reference missing actions |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See above.
Autoloaded paths are no longer in $LOAD_PATH. The file services.rb is in app/lib which is autoloaded.
Follow these steps if you are doing a Rails upgrade.
What
We need to upgrade our apps to the latest version of Rails.
How
Follow these steps: https://guides.rubyonrails.org/upgrading_ruby_on_rails.html#moving-between-versions
Trello ticket