2017/10/09分のコミットです。
CHANGELOGにのったコミットは以下の通りです。
actioncable/CHANGELOG.md
activejob/CHANGELOG.md
Merge pull request #30802 from khall/30662_long_variant_filenames
activestorage/app/models/active_storage/variant.rbの修正です。
keyを生成する際に、keyそのままではなく、ハッシュ値(Digest::SHA256.hexdigestを使用)を使用するよう修正しています。
def key - "variants/#{blob.key}/#{variation.key}" + "variants/#{blob.key}/#{Digest::SHA256.hexdigest(variation.key)}" end
keyをそのまま使用すると、生成されたファイル名が長い場合にErrno::ENAMETOOLONGのエラーが発生してしまう可能性がある為。
Merge pull request #30789 from erichmachado/file-store-cache-cleanup-fix
activesupport/lib/active_support/cache/file_store.rbの修正です。
ActiveSupport::Cache::FileStore#cleanupでexpireしかファイルが実際には削除されないバグがあったのを修正しています。
Distinguish missing adapter gems from load errors within the adapter
actioncable/lib/action_cable/server/configuration.rb、
activerecord/lib/active_record/connection_adapters/connection_specification.rbの修正です。
Action Cable、及び、Active Recordで指定されたadapterに対応するgemが見つからない場合(adapterにPostgreSQLを指定しているがpg gemをGemfileに指定していない場合等)に、エラーメッセージに詳細な情報を出力するよう修正しています。
Action Cable、Active Job、railtiesの修正です。
Action Cable、Active Jobがredis-rb 4系で動作するよう修正しています(Active Jobはテストの修正だけ)。
合わせて、rails newで生成されるGemfileでredis-rb 4系を使用するよう修正しています。
Remove passing redundant self to internal apply_join_dependency etc
activerecord/lib/active_record/relation/finder_methods.rbの修正です。
ActiveRecord::FinderMethods#construct_relation_for_exists、#apply_join_dependencyメソッドの引数から、不要なrelation引数を削除しています。同じクラスからしか呼ばれないメソッドであり、レシーバーの明示的な指定は不要な為。
Fix typo in loading error message
activerecord/lib/active_record/connection_adapters/connection_specification.rbの修正です。
指定されたadapterに対応するgemが見つからない場合に表示するエラーメッセージでタイポしていたのを修正しています。
Missing revision 5efd21bb7ee4b326d9c0d26fccad10fc59dd51f0 in redis-rb-4.0 branch
Gemfile.lockの修正です。
resque-scheduler gemを使用するのにGitHubのリポジトリ(https://github.com/jeremy/resque-scheduler)を直接指定しているのですが、そののリポジトリrevisionの指定に誤りがあったのを修正しています。どうやらコミットした後からrebaseしたもよう。
Fix relation.exists? with has_many through associations
activerecord/lib/active_record/relation/finder_methods.rbの修正です。
has_many through associationをjoinした際に、relation.exists?メソッドが正しいaliasを参照しないバグがあったのを修正しています。
Fix the result of rails routes in Guide [ci skip]
rails guideのGetting Started with Railsの修正です。
rails routesの実行結果のexampleが、実際の内容と異なっていたのを修正しています。
Remove meaningless named construct_relation_for_association_calculations
activerecord/lib/active_record/relation/calculations.rb、
activerecord/lib/active_record/relation/finder_methods.rbの修正です。
FinderMethods#construct_relation_for_association_calculationsメソッドを削除しています。
上記メソッドはjoin dependencyのapply処理のラップ(apply_join_dependencyメソッドを呼び出すだけ)しか行っていない、かつ、内部でだけ使用するメソッドなので、apply_join_dependencyメソッドを直接呼び出した方がわかりやすいだろう、という事で削除されたようです。
Use form_with instead of form_for in engine guide [ci skip]
rails guideのAction Controller Overview、Getting Started with Enginesの修正です。
form_forメソッドを使用していた箇所をform_withメソッドを使用するよう修正しています。
All test cases for exists? places in finder_test.rb to ease to find the test cases
activerecord/test/cases/finder_test.rb、
activerecord/test/cases/relations_test.rbの修正です。
exists?メソッドに関するテストを全てactiverecord/test/cases/finder_test.rbに移動しています。
元々finder_test.rbに殆どのテストがあって、一部テストだけrelations_test.rbにある状態でした。それだとわかりずらいだろうという事でfinder_test.rbに移動したようです。
Joined tables in association scope doesn't use the same aliases with the parent relation's aliases
Active Recordの修正です。
join dependencyのassociation scopeを生成する際に、親relationのaliasを参照出来るよう修正しています。親relationで定義されているaliasと同じaliasを定義するのを避ける為(同じaliasがあるとエラーになる)、のようです。
Use released sidekiq instead of master version
Gemfileの修正です。
sidekiqを使用するのにGitHubのmaterブランチを直接指定していたのを、リリース済みのgemを使用するよう修正しています。