なるようになるブログ

読書感想文かrailsについてかrubyについてか

rails commit log流し読み(2025/11/27)

2025/11/27分のコミットです。

CHANGELOGへの追加はありませんでした。


Add langauge for code example in asset pipeline guide [ci skip]

rails guideのThe Asset Pipelineの修正です。

code exampleのblockで、langaugeの指定が不足している箇所があったのを修正しています。


Merge pull request #56129 from matthewd/intent-execute

Active Recordの修正です。

Introduce Parameter Object: QueryIntentで導入したQueryIntentクラスでadapterを保持するようにして、クエリーの実行や結果の取得をQueryIntent経由で行えるよう修正、及び、QueryIntent経由でSQLを実行するよう修正しています。


Optimize ActiveRecord::Base#becomes when no class conversion needed

activerecord/lib/active_record/persistence.rbの修正です。

ActiveRecord::Base#becomesで変換対象のクラスとselfが同一の場合、不要な変換処理を行わないよう修正しています。


Ensure TimeWithZone#as_json always return an UTF-8 string

activesupport/lib/active_support/time_with_zone.rb の修正です。

ActiveSupport::TimeWithZone#as_jsonで返すstringのencodingが、Rails 8.0までは必ずUTF-8だったのが、8.1でUS-ASCIIになってしまう事があるバグがあったのを修正しています。


Handle closed PostgreSQL connections in retryable_query_error?

activerecord/lib/active_record/connection_adapters/postgresql_adapter.rbの修正です。

retryable_query_error?メソッドで、PostgreSQLのconnectionsがclose済みの場合PG::ConnectionBadがそのままraiseされていたのを、boolの値を返し呼び出し元で処理を継続出来るよう修正しています。


Remove whitespace to make note not part of code example [ci skip]

activerecord/lib/active_record/sanitization.rbのdocの修正です。

sanitize_sql_arrayメソッドのdocから不要な空白を削除しています。