2024/05/24分のコミットです。
CHANGELOGにのったコミットは以下の通りです。
update sqlite3 adapter tests to accept error messages from v3.46.0
activerecord/test/cases/adapters/sqlite3/sqlite3_adapter_test.rb
の修正です。
SQLite v3.46.0で指定されたカラムが無い場合のエラーメッセージが変更になっており、その変更後のエラーメッセージでもテストが通るようメッセージのチェック処理を修正しています。
Enable Rails minitest plugin in our rake tasks
テストの修正です。
各コンポーネントのテスト実行時にRails内部のminitest pluginがロードされなくなってしまっていたのを、ロードされるよう修正しています。
Point to the right executable when warning about --profile
railties/lib/minitest/rails_plugin.rb
の修正です。
profile
オプションに不正な値を指定した場合のエラーメッセージで、テスト実行用のexeを指定するのにRails::TestUnitReporter.executable
の値を使用するよう修正しています。
chore: remove webpack from yarn dependencies in Rails dev
package.json
の修正です。
使用していないwebpack
のdependencyを削除しています。
fix the direct upload class example
rails guideのActive Storage Overview
の修正です。
Integrating with Libraries or Frameworks
セクションにあるDirectUpload
を使用したexampleコードが実際には動作しないコードになっていたのを修正しています。
Merge pull request #51822 from excid3/plugin-github-actions
railtiesの修正です。
pluginを新規に作成した際に、CI(GitHub Actions)とRubocopの設定を含むよう修正しています。
Look up route from requirements (#51850)
actionpack/lib/action_dispatch/routing/route_set.rb
の修正です。
requirementからrouteを検索するためのfrom_requirements
メソッドを追加しています。
Rails.application.routes.from_requirements(controller: "posts", action: "show")
Ruby LSP Railsでroutesのcode lensを表示出来るようにするために追加、したとの事です。
参考:Add code lens for mapping actions to routes
Move plumbing to enable yjit to inside the framework
railtiesの修正です。
YJITを有効化するかどうかの設定をinitializerで設定するようにしていたのを、それ用のconfig(config.yjit
)を追加し、そのconfig経由で指定出来るよう修正しています。処理の詳細をアプリケーション側で保持する必要はないだろう、との事です。
Merge pull request #51880 from Shopify/devcontainer-generator
railtiesの修正です。
Dev Containersのサポートをオプトイン機能に変更しています。そのため、デフォルトではDev Containers用のファイルは生成されず、rails new
に--devcontainer
を指定した場合のみ生成されるよう変更しています。
Don't enable automatically_invert_plural_associations by default
activerecord/lib/active_record/reflection.rb
の修正です。
pluralized nameに対するinverse relationsの検索を自動で行うかどうかのconfig(automatically_invert_plural_associations
)のデフォルトをfalseに変更しています。この変更に関するissueが沢山きており、デフォルトで有効にするのはまずそう、という事のようです。
Use the --devcontainer
option when generating a new Rails app in the guide
rails guideのGetting Started with Dev Containers
の修正です。
サンプル用のアプリケーションを作成するためのコマンドに--devcontainer
引数を追加しています。
Use released version of RDoc v6.7.0
Gemfile
の修正です。
リリース済みのrdoc gemを使用するよう修正しています。forkを使用する理由になった修正を含むバージョンがリリースされたため。
Private methods do not need :nodoc: to be private API
actionpack/lib/action_controller/metal/request_forgery_protection.rb
の修正です。
private methodsに対する不要な:nodoc:
の指定を削除しています。
Fix railtie config test for sqlite 3.46.0
railties/test/application/configuration_test.rb
の修正です。
SQLite v3.46.0で指定されたカラムが無い場合のエラーメッセージが変更に伴う対応で、修正が漏れていた箇所があったのを修正しています。
Merge pull request #51898 from flavorjones/51699-improve-store-accessor-for
activerecord/lib/active_record/store.rb
の修正です。
structured(hstore、json) typeでない、かつ、ActiveRecord.store
でserializeを定義していないattributeをActiveRecord::Store
に指定した場合に、attribute参照時に不正な値である事がわかる明示的なエラー(ActiveRecord::ConfigurationError
)をraiseするよう修正してます。
fix colspan for HtmlTableFormatter and dynamic search for routes
actionpack/lib/action_dispatch/middleware/templates/routes/_table.html.erb
、
actionpack/lib/action_dispatch/routing/inspector.rb
の修正です。
dynamic route search用のtemplateのcolspan
の指定が誤っていたのを修正しています。
Revert "Merge pull request #51614 from gmcgibbon/defer_route_drawing"
eager_load
がfalseの場合、最初のrequestかurl_helpers
が実行されるまでrouteのdrawingを遅らせるよう修正した、Defer route drawing to the first request, or when url_helpers calledをRevertしています。eager_load
がfalseの場合に幾つかのrouting処理が正しく動作しない、というissueがきている為。