- 16 2月, 2019 15 次提交
-
-
由 Ryuta Kamizono 提交于
The CI failure for `test_errors_for_bigint_fks_on_integer_pk_table` is due to the poor regex that extract all ``` `(\w+)` ``` like parts from the message (`:foreign_key` should be `"old_car_id"`, but `"engines"`): https://travis-ci.org/rails/rails/jobs/494123455#L1703 I've improved the regex more strictly and have more exercised mismatched foreign key tests. Fixes #35294
-
由 Ryuta Kamizono 提交于
Fix possible memory leak of ConnectionHandler
-
由 Yutaka HARA 提交于
refs #35296
-
由 Aaron Patterson 提交于
Show deprecated message instead of raise exception in `compiled_method_container` method
-
由 Ryuta Kamizono 提交于
Since #35212, foreign key feature is supported by all adapters.
-
由 Ryuta Kamizono 提交于
-
由 Ryuta Kamizono 提交于
[ci skip]
-
由 Ryuta Kamizono 提交于
Properly handle cached queries with too many bind parameters
-
由 yuuji.yaginuma 提交于
Since #35036, the subclasses of `ActionView::Base` requires the `compiled_method_container`. This is incompatible. For example, `web-console` use view class that subclass of `ActionView::Base`, and does not work it now cause of this. Actually, since it seems that it is only `ActionView::Base` that `compiled_method_container` is necessary, modified the condition that emits a warning.
-
由 Yuji Yaginuma 提交于
Allow to pass options to `csp_meta_tag`
-
由 yuuji.yaginuma 提交于
Currently `csp_meta_tag` generates `name` attribute only. However, in libraries like `Material-UI` and `JSS`, expect that the meta tag that contains the nonce with `property` attribute. https://material-ui.com/css-in-js/advanced/#how-does-one-implement-csp https://github.com/cssinjs/jss/blob/master/docs/csp.md This patch allows `csp_meta_tag` to specify arbitrary options and allows `nonce` to be passed to those libraries.
-
由 Xavier Noria 提交于
-
由 Rafael França 提交于
AbstractController::Translation#t: dup options
-
由 Gannon McGibbon 提交于
Reword RDBMS note in ActiveRecord basics
-
由 Nazar Matus 提交于
-
- 15 2月, 2019 16 次提交
-
-
由 Vipul A M 提交于
Fix Small Typo in Docs [ci skip]
-
由 Conrad Beach 提交于
[ci skip]
-
由 Ryuta Kamizono 提交于
Deprecate using class level querying methods if the receiver scope regarded as leaked
-
由 Ryuta Kamizono 提交于
This deprecates using class level querying methods if the receiver scope regarded as leaked, since #32380 and #35186 may cause that silently leaking information when people upgrade the app. We need deprecation first before making those.
-
由 Xavier Noria 提交于
Rails.autoloader and Rails.once_autoloader was just tentative API good enough for a first patch. Rails.autoloader is singular and does not convey in its name that there is another autoloader. That might be confusing, for example if you set a logger and miss traces. On the other hand, the name `once_autoloader` is very close to being horrible. Rails.autoloaders.main and Rails.autoloaders.once read better for my taste, and have a nice symmetry. Also, both "main" and "once" are four letters long, short and same length. They are tagged as "rails.main" and "rails.once", respectively. References #35235.
-
由 Matthew Dunbar 提交于
-
由 Matthew Draper 提交于
Address uninitialized constant PostgresqlAdapterTest::ChannelPrefixTest (NameError)
-
由 Ryuta Kamizono 提交于
This reverts commit b67d5c6d, reversing changes made to 2e018361. Reason: #35186 may cause that silently leaking information when people upgrade the app. We need deprecation first before making this.
-
由 Rafael Mendonça França 提交于
Fix the `config_for` to always return a NonSymbolAccessDeprecatedHash:
-
由 Yasuo Honda 提交于
``` $ bundle exec ruby -w -Itest test/subscription_adapter/postgresql_test.rb Traceback (most recent call last): 1: from test/subscription_adapter/postgresql_test.rb:8:in `<main>' test/subscription_adapter/postgresql_test.rb:10:in `<class:PostgresqlAdapterTest>': uninitialized constant PostgresqlAdapterTest::ChannelPrefixTest (NameError) ``` https://travis-ci.org/rails/rails/jobs/493530508 Follow up #35276
-
由 Vladimir Dementyev 提交于
-
由 Eileen M. Uchitelle 提交于
Minor changes to deprecation warning message after #35242
-
由 Abhay Nikam 提交于
-
由 George Claghorn 提交于
Fixes missing method `path_for` when using MirrorService with DiskService as the primary service
-
由 Eileen M. Uchitelle 提交于
Add setter and deprecation for configurations hashes
-
由 Abhay Nikam 提交于
-
- 14 2月, 2019 9 次提交
-
-
由 eileencodes 提交于
In chat Sam Saffron asked how to use the setter now that configurations is no longer a hash and you need to do AR::Base.configurations["test"]=. Technically you can do `ActiveRecord::Base.configurations = { the hash }` but I realized the old way throws an error and is unintuitive. To aid in the transition from hashes to objects this PR makes a few changes: 1) Re-adds a deprecated hash setter `[]=` that will add a new hash to the configurations list OR replace an existing hash if that environment is already present. This won't be supported in future Rails versions but a good error is important. 2) Changed to throw deprecation warnings on the methods we decided to support for hash conversion and raise on the methods we don't support. 3) Refactored the setter/getter hash deprecation warnings messages and rewrote them. Getters message: ``` DEPRECATION WARNING: `ActiveRecord::Base.configurations` no longer returns a hash. Methods that act on the hash like `values` are deprecated and will be removed in Rails 6.1. Use the `configs_for` method to collect and iterate over the database configurations. ``` Setter message: ``` DEPRECATION WARNING: Setting `ActiveRecord::Base.configurations` with `[]=` is deprecated. Use `ActiveRecord::Base.configurations=` directly to set the configurations instead. ``` 4) Rewrote the legacy configurations test file to test all the public methods in the DatabaseConfigurations class.
-
由 Edouard CHIN 提交于
- If you have hashes inside array, the hashes were getting initialized as regular HWIA wereas we want them to be NonSymbolAccessDeprecatedHash in order to trigger a deprecation warning when keys are accessed with string. This patch fixes that by overwriting the `[]=` to to the same as what HWIA does (with the difference that we don't call `convert_key` to not trigger a deprecation when setting value). I also took the liberty to extract `hash.nested_under_indifferent_access`, into a separate method to allow subclasses to return whatever they want. Inheriting HWIA is not common, but I think it's useful for cases like this one where we want to preprocess reading and writing values in the hash (for deprecation purposes or other reasons).
-
由 Xavier Noria 提交于
There is too much to say about it for a CHANGELOG entry, and linking to the original PR could mislead if there are later changes as already happened with the gem dependency, so just a one-liner. For final we'll up to date documentation.
-
由 Xavier Noria 提交于
Let Zeitwerk be a dependency of Active Support
-
由 Ryuta Kamizono 提交于
Use Dir#children and Dir#each_child in ActiveSupport::Cache::FileStore
-
由 yuuji.yaginuma 提交于
-
由 Ricardo Díaz 提交于
Both methods were introduced in Ruby 2.5 and fit this use case very nicely: listing a directory's entries excluding the "." and ".." nodes. The private method #exclude_from was removed as it no longer serves its original purpose.
-
由 Rafael Mendonça França 提交于
Adding enque time tracking and logging
-
由 Cory Gwin @gwincr11 提交于
Motivation: - Currently we have 2 seperate monkey patches in place for tracking enqueded time for 2 seperate workers. It seems that activejob could be a source of truth for how long an item has been enqued so that we can easily use it for consistent monitoring across workers/apps to ensure that jobs are running at an acceptable speed. Changes: - Add an enqueded at attribute and serilization tooling. - Add a method to get how long a job has been enqueded for. - Add a logging item to show how long a job was enqued prior to the perform method firing.
-