2019/09/1 はコミットはありませんでした。
rails commit log流し読み(2019/08/31)
2019/08/31分のコミットです。
CHANGELOGへの追加はありませんでした。
Fix grammar for attached? method doc
activestorage/lib/active_storage/attached/many.rb
のdocの修正です。
Attached::Many#attached?
メソッドのdocのグラマーの修正を行っています。
rails commit log流し読み(2019/08/30)
2019/08/30分のコミットです。
CHANGELOGへの追加はありませんでした。
No need to stringify event names (= method names) that always are Symbols
activesupport/lib/active_support/subscriber.rb
の修正です。
Subscriber
クラスでevent名(メソッド名)をStringとして扱っていたのを、Symbolとして扱うよにして不要な変換を行わなわないよう修正しています。
Extend test_can_write_while_reading_from_replicas_if_explicit
activerecord/test/cases/database_selector_test.rb
の修正です。
test_can_write_while_reading_from_replicas_if_explicit
でconnected_to
+ prevent_writes: false
を指定した後のconnectionの状態についてもテストするよう修正しています。
rails commit log流し読み(2019/08/29)
2019/08/29分のコミットです。
CHANGELOGにのったコミットは以下の通りです。
This is no longer a fact in Rails 3+
rails guideのActive Support Core Extensions
の修正です。
parameterize
メソッドについて説明している箇所に、戻り値はActiveSupport::Multibyte::Chars
にラップされた値になっている旨説明があったのですが、これは古い挙動で現状は違う為、該当部分の説明を削除しています。
Constantize a constant array in a method
activesupport/lib/active_support/inflector/transliterate.rb
の修正です。
transliterate
メソッドで処理出来るencodingの一覧を変数で保持していたのを、定数で保持するよう修正しています。
Fix docs to update ruby version in reference URLs [ci skip]
rails guideのActive Record and PostgreSQL
の修正です。
Rubyのcoreライブラリについてのdocのリンクをhttps://ruby-doc.org/core-2.2.2
からhttps://ruby-doc.org/stdlib-2.5.0
に修正しています。Rails 6.0がサポートしているRubyのバージョンが2.5以上な為。
US_ASCII strings are always UTF_8 compatible
activesupport/lib/active_support/core_ext/string/multibyte.rb
の修正です。
is_utf8?
メソッドでencodingがEncoding::US_ASCII
の場合、不要なforce_encoding(Encoding::UTF_8)
を実行しないよう修正しています。
Merge pull request #37065 from eileencodes/push-while_preventing_writes-into-connected_to
activerecord/lib/active_record/connection_handling.rb
、
activerecord/lib/active_record/middleware/database_selector/resolver.rb
の修正です。
connected_to
メソッドの中からwhile_preventing_writes
を直接呼び出すよう修正しています。
while_preventing_writes
メソッドに渡す引数もconnected_to
メソッドから渡せるようになっており、これで書き込みの禁止 / 許可をミドルウェアではなくアプリで制御出来るようになっています。
ミドルウェアレベルだとアプリ側でconnected_to
を使用された場合に競合状態になって正しく書き込み処理のハンドリングが出来ないケースがあった為。
Fix missing close code tick mark in AR changelog [ci skip]
activerecord/CHANGELOG.md
の修正です。
メソッド名に対するクォートが不足していたのを修正しています。
Remove mysql2 specific rescue in abstract adapter
activerecord/lib/active_record/connection_adapters/abstract_mysql_adapter.rb
、
activerecord/lib/active_record/connection_adapters/mysql2_adapter.rb
の修正です。
AbstractMysqlAdapter#translate_exception
メソッドでmysql2
固有のエラーに関する処理があったのを、mysql2
固有のエラーについてはMysql2Adapter
クラスで行うよう修正しています。
rails commit log流し読み(2019/08/28)
2019/08/28分のコミットです。
CHANGELOGにのったコミットは以下の通りです。
Disallow all non-numerics as Duration.build input, Fixes #37012
activesupport/lib/active_support/duration.rb
の修正です。
ActiveSupport::Duration.build
の引数にNumeric
以外の値を指定した場合TypeError
をraiseするよう修正しています。
元々String
を指定してもDuration
のインスタンスを生成出来るようになっていたのですが、String
を指定した場合のインスタンスはNumeric
を指定した場合のインスタンスとの比較処理が正しく行えない、という問題がありました。
それは振る舞いとしてよくないよねという話になり、という事でそもそもNumeric
以外の値は指定出来ないよう修正されました。
Changed controller name (Typo fix) in rails engines documentation [ci skip]
rails guideのGetting Started with Engines
の修正です。
Using a Class Provided by the Application
の項のexampleコードのコントローラ名をタイポしていたのを修正しています。
Add doc about I18n support for :placeholder option [ci skip]
actionview/lib/action_view/helpers/form_tag_helper.rb
のdocの修正です。
text_field_tag
メソッドのdocに:placeholder
オプションについての説明を追加しています。
Fix a document to update postgresql version for rails6 [ci skip]
rails guideのThe Rails Command Line
の修正です。
Rails with Databases and SCM
の項にある、rails new
で生成されるconfig/database.yml
の内容が実際の内容と異なっていたのを修正しています。
Clarify severe security issues maintenance policy [ci skip]
rails guideのMaintenance Policy for Ruby on Rails
の修正です。
Severe Security Issues
の項の説明の言い回しを修正しています。
Update stale issue comment to mention 6-0-stable
.github/stale.yml
の修正です。
stale botがコメントする、まだissueが再現するかどうかを確認するブランチを5-2-stable
から6-0-stable
に修正しています。
Merge pull request #37047 from dvandersluis/37044-fix-exception-message
actionpack/lib/action_controller/metal/exceptions.rb
、
activerecord/lib/active_record/associations.rb
の修正です。
MethodNotAllowed
、HasManyThroughSourceAssociationNotFoundError
exceptionでエラーメッセージを構築する際に、to_sentence
メソッドでen
localeを強制的に使用していたのを、使用しないよう修正しています。
en
localeの設定が無い環境でエラー(
I18n::InvalidLocale`)になってしまう為。
rails commit log流し読み(2019/08/27)
2019/08/27分のコミットです。
CHANGELOGにのったコミットは以下の通りです。
actionmailer/CHANGELOG.md
Escape email addresses with name
actionmailer/lib/action_mailer/base.rb
の修正です。
名前付きのemailを作成する為のemail_address_with_name
メソッドを追加しています・
email_address_with_name("sunny@example.org", "Sunny") #=> "Sunny <sunny@example.com>"
activesupport/lib/active_support/cache.rb
、
activesupport/lib/active_support/cache/redis_cache_store.rb
の修正です。
cacheから複数データをまとめて削除する為のdelete_multi
メソッドを追加しています。
Reduce Hash creation in FormHelper
actionview/lib/action_view/helpers/form_helper.rb
の修正です。
FormHelper#objectify_options
でmerge
メソッドを使用するのを避けて、Hashオブジェクトの生成を減らすようにしています。
No need to count an Array because Array knows its length
activesupport/lib/active_support/core_ext/string/output_safety.rb
の修正です。
SafeBuffer#[]=
メソッドで引数の数を数えるのにcount
を使用していたのをlength
を使用するよう修正し、不要なループが実行されないよう修正していmす。
Skip tidying bytes for ascii_only strings
activesupport/lib/active_support/multibyte/unicode.rb
の修正です。
Unicode#tidy_bytes
メソッドでStringがASCIIだけの場合不要な変換処理を行わないよう修正しています。
No need to dup && freeze an already frozen sql string
activerecord/lib/active_record/connection_adapters/abstract/database_statements.rb
の修正です。
DatabaseStatements#to_sql_and_binds
メソッドでSQL Stringがfreezeな場合、不要なdup + freeze処理を実行しないよう修正しています。
Giving a Symbol here might be a very little bit efficient than giving a String
activerecord/lib/active_record/core.rb
の修正です。
connection handlerを保持するスレッドローカル変数に使用するkeyをStringからSymbolに変更しています。keyは後の処理でSymbolに変更される為、最初からSymbolを使用した方が不要な変換が行われない為。
Fix rdoc of ActiveRecord::Associations::CollectionProxy#replace [ci skip]
activerecord/lib/active_record/associations/collection_proxy.rb
のdocの修正です。
ActiveRecord::Associations::CollectionProxy#replace
メソッドのdoc内のexampleコードで、括弧が不足している箇所があったのを修正しています。
Fix assertion in test_delete_multi
activesupport/test/cache/behaviors/cache_store_behavior.rb
の修正です。
delete_multi
メソッドのテストでチェックするkey名に誤りがあったのを修正しています。
Ignore SQLite3 database files generated by parallel testing
gitignoreの対象にparallel testingで生成するSQLite3のDBファイル(sqlite3-
+ 数字)を追加しています。
rails commit log流し読み(2019/08/26)
2019/08/26分のコミットです。
CHANGELOGへの追加はありませんでした。
Merge pull request #28862 from georgemillo/show_detailed_exceptions
rails guideのConfiguring Rails Applications
の修正です。
config.consider_all_requests_local
について説明している箇所に、より細かな制御が必要な場合、コントローラでshow_detailed_exceptions?
を実装する必要がある旨説明を追加しています。
Always load validator class to verify it exists
activemodel/lib/active_model/validations/validates.rb
の修正です。
optionの内容に関わらずvalidation classを必ずロードするよう修正しています。不正なvalidationが指定された場合に気付けるようにする(ロード時にエラーになるようにする)為。
Fix docs to replace http with https in activerecord [ci skip]
Active Recordのdocの修正です。
外部リンクへのURLをhttp -> httpsに修正しています。