なるようになるブログ

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

rails commit log流し読み(2014/11/17)

2014/11/17分のコミットです。

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


Don't let #{application,framework,full}_trace be nil

actionpack/lib/action_dispatch/middleware/exception_wrapper.rbactionpack/lib/action_dispatch/middleware/templates/rescues/_source.erbの修正です。

railsの標準エラー画面でtraceを表示する際、viewの方でtraceがnilかどうかチェックしていたのですが、 tracesメソッドの方でnilチェックを行い、nilの場合は空の配列を設定するようにして、viewの方でnilチェックは行わないで良いよう改善しています。


[CI SKIP] Missing space.

rails guideのActive Job Basicsの修正です。

ActionMailer -> Action Mailerに修正しています。


add Nokogiri to docs generation guides

rails guideのGetting Started with Railsの修正です。

What's Next?の項で、Nokoiriのインストールの説明が足りてなかったので、追加しています。


Rename #source_extract to #source_extracts in ExceptionWrapper

actionpack/lib/action_dispatch/middleware/debug_exceptions.rbactionpack/lib/action_dispatch/middleware/exception_wrapper.rbの修正です。

source_extract -> source_extractsメソッド名を修正しています。

1ed264bから、複数の値を返すようになっているので、メソッド名も内容に合わせて修正しています。


Don't show full trace on routing errors

actionpack/lib/action_dispatch/middleware/debug_exceptions.rbの修正です。

こちらのコミットから、エラーが起きた際、全てのバックトレースを表示するようになったのですが、routing_errorが起きた際には全ては表示しないよう修正しています。

Routing Errorの場合は、バックトレースは要らないだろう、との事です。


Don't double check trace origin in ExceptionWrapper#traces

actionpack/lib/action_dispatch/middleware/exception_wrapper.rbの修正です。

不要なtraceのチェック処理を削除しています。


Skip spring install in Cygwin due to fork() bad support.

railties/lib/rails/generators/app_base.rbの修正です。

cygwin の場合springをインストールしないよう対応しています。cygwinだとforkが動作しない為との事。


Fix for assigns(:..) resetting template assertions

actionpack/lib/action_dispatch/testing/integration.rbの修正です。

Integrationテストでassignscookiesメソッドを使用した際、template assertionsをresetしないよう修正しています。


PERF: optimise type lookup to avoid invoking procs

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

HashLookupTypeMapクラスで、一度fetchできたtypeについてはキャッシュを持つようにして、同じtypeを複数回取らないよう修正しています。

PostgreSQLselect_allを使用した際の速度がrail 4.1から遅くなってしまっていたので、性能改善の対応です。


Minor English fixes in docs [ci skip]

guides/source/active_support_core_extensions.mdrailties/lib/rails/engine.rbの修正です。

グラマーの修正です。


Revert "Merge pull request #16622 from matthewd/default-debug"

Railsのデフォルトのログレベルを:debugに変更したこのコミットをrevertしています。

production.rbにconfig.log_levelが設定されるようになったのはRails 4.0からなので、それ以前に新規に作成されたappだとconfig.log_levelが設定されてないので、ログレベルが:debugになってしまい、まずいだろう、という事でrevertしたようです。


Deprecate different default for log_level in production

railties/lib/rails/application/bootstrap.rbrailties/lib/rails/application/configuration.rbの修正です。

production.rblog_levelが設定されてない場合に、ワーニングメッセージを表示するよう修正しています。

Rails 5からはデフォルトを:debugに戻す為、その為の準備との事です。


Meant to describe the concept, not the setting [ci skip]

railties/lib/rails/generators/rails/app/templates/config/environments/production.rb.ttの修正です。

log_level -> log levelに修正しています。


Merge pull request #17628 from bf4/update_unicode

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

対応しているUnicodeのバージョンを7.0.0に更新しています。


Remove pointless private

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

以降に何の定義も無い不要なprivateを削除しています。


Add StackProf to the test group for 2.1

Gemfileの修正です。

Ruby 2.1の場合のみ、Gemfileにstackprofを追加しています。