| Commit message (Collapse) | Author | Age | Files | Lines |
|\
| |
| | |
Add documentations to concern methods [ci skip]
|
| | |
|
| | |
|
|\ \
| | |
| | | |
Removed unused require for active_support/deprecation
|
|/ /
| |
| |
| | |
- Unused since https://github.com/rails/rails/commit/a91ea1d51048342d13f
|
|\ \
| | |
| | |
| | | |
Fix dirty tracking after rollback.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Currently the rollback only restores primary key value, `new_record?`,
`destroyed?`, and `frozen?`. Since the `save` clears current dirty
attribute states, retrying save after rollback will causes no change
saved if partial writes is enabled (by default).
This makes `remember_transaction_record_state` remembers original values
then restores dirty attribute states after rollback.
Fixes #15018.
Fixes #30167.
Fixes #33868.
Fixes #33443.
Closes #33444.
Closes #34504.
|
| | | |
|
|\ \ \
| | | |
| | | | |
Various fixes in ActiveSupport::Notifications::Event
|
| | | | |
|
| | | |
| | | |
| | | |
| | | | |
variables such as @cpu_time, @idle_time and @allocations; this reduces one allocation
|
| | | |
| | | |
| | | |
| | | | |
event subscribed by a `ActiveSupport::Notifications::Fanout::Subscribers::Timed` subscriber
|
| | | |
| | | |
| | | |
| | | | |
`ActiveSupport::Notifications::Fanout::Subscribers::Timed` subscriber
|
| | | | |
|
|\ \ \ \
| | | | |
| | | | |
| | | | |
| | | | | |
soartec-lab/update_guide_asset_pipeline_change_default
Guide updated in line with changes in rails commands [skip ci]
|
| | | | | |
|
| | | | | |
|
| | | | | |
|
|\ \ \ \ \
| | | | | |
| | | | | |
| | | | | | |
Signed-off-by: Kasper Timm Hansen <kaspth@gmail.com>
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
`bin/setup` and `bin/update` are currently almost the same file. The
only thing that keeps them apart is that one is running `bin/rails
db:setup` and the other `bin/rails db:migrate`.
I'm suggesting here that they should be a unique script, which needs to
be idempotent.
- New to a project, need to get started? `bin/setup`
- Need to install new dependencies that were added recently? `bin/setup`.
Before deprecating `bin/update`, I'm suggesting we just have it call
`bin/setup`.
|
| |\ \ \ \ \
| | | | | | |
| | | | | | |
| | | | | | | |
Signed-off-by: Kasper Timm Hansen <kaspth@gmail.com>
|
|\ \ \ \ \ \ \
| |/ / / / / /
|/| / / / / /
| |/ / / / / |
Signed-off-by: Kasper Timm Hansen <kaspth@gmail.com>
|
|/ / / / /
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Cache versioning enables the same cache key to be reused when the object
being cached changes by moving the volatile part of the cache key out of
the cache key and into a version that is embedded in the cache entry.
This is already occurring when the object being cached is an
`ActiveRecord::Base`, but when caching an `ActiveRecord::Relation`
we are currently still putting the volatile information (max updated at
and count) as part of the cache key.
This PR moves the volatile part of the relations `cache_key` into the
`cache_version` to support recycling cache keys for
`ActiveRecord::Relation`s.
|
| | | | | |
|
|\ \ \ \ \
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
tjoyal/Rails/MailersController/do-not-leak-I18n-global-setting-changes
[Rails::MailersController] Do not leak I18n global setting changes
|
| | | | | | |
|
|\ \ \ \ \ \
| |/ / / / /
|/| | | | | |
Squash warning: possibly useless use of a constant in void context
|
|/ / / / /
| | | | |
| | | | |
| | | | | |
in void context
|
|\ \ \ \ \
| | | | | |
| | | | | | |
Update the generate command sample codes [skip ci]
|
|/ / / / / |
|
|\ \ \ \ \
| | | | | |
| | | | | | |
Cache full MySQL version in schema cache
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
* Remove AbstractMysqlAdapter::Version since full_version_string will always
be set.
* Remove nodoc on private methods because private methods are not exposed in
the docs.
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
* The database version is cached in all the adapters, but this didn't include
the full MySQL version. Anything that uses the full MySQL version would need
to query the database to get that data even if they're using the schema
cache.
* Now the full MySQL version will be cached in the schema cache via the
Version object.
|
|\ \ \ \ \ \
| |_|/ / / /
|/| | | | | |
Find query_source_location using lazy Enumerator
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
This way, we only need to filter the backtrace up to the first non-noise
stack frame.
This also updates noise to be able to deal with being passed a lazy
enum. We don't need this anywhere, but it seemed better for this to be
consistent.
|
|\ \ \ \ \ \
| | | | | | |
| | | | | | | |
Bump RuboCop to 0.67.2
|
| | |_|_|/ /
| |/| | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Performance cops will be extracted from RuboCop to RuboCop Performance
when next RuboCop 0.68 will be released.
https://github.com/rubocop-hq/rubocop/issues/5977
RuboCop 0.67 is its transition period.
Since rails/rails repository uses Performance cops, This PR added
rubocop-performance gem to Gemfile.
And this PR fixes some offenses using the following auto-correct.
```console
% bundle exec rubocop -a
Offenses:
activerecord/test/cases/connection_adapters/connection_handlers_multi_db_test.rb:212:26:
C: [Corrected] Layout/SpaceAroundOperators: Operator =
> should be surrounded by a single space.
"primary" => { adapter: "sqlite3", database: "db/primary.sqlite3" }
^^
activerecord/test/cases/connection_adapters/connection_handlers_multi_db_test.rb:239:26:
C: [Corrected] Layout/SpaceAroundOperators: Operator => should be
surrounded by a single space.
"primary" => { adapter: "sqlite3", database: "db/primary.sqlite3" }
^^
actionview/test/template/resolver_shared_tests.rb:1:1: C: [Corrected]
Style/FrozenStringLiteralComment: Missing magic comment #
frozen_string_literal: true.
module ResolverSharedTests
^
actionview/test/template/resolver_shared_tests.rb:10:33: C: [Corrected]
Layout/SpaceAroundEqualsInParameterDefault: Surrounding space missing in
default value assignment.
def with_file(filename, source="File at #{filename}")
^
actionview/test/template/resolver_shared_tests.rb:106:5: C: [Corrected]
Rails/RefuteMethods: Prefer assert_not_same over refute_same.
refute_same a, b
^^^^^^^^^^^
2760 files inspected, 5 offenses detected, 5 offenses corrected
```
|
|\ \ \ \ \ \
| |/ / / / /
|/| | | | | |
Format a comment to not show up as code [ci skip]
|
|/ / / / / |
|
| | | | |
| | | | |
| | | | |
| | | | | |
[ci skip]
|
|\ \ \ \ \
| | | | | |
| | | | | | |
Migrate Code Climate config file to new configuration
|
|/ / / / /
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
I don't know whether have to move to a new configuration, but I think
there is no need to keep using the old configuration.
Ref: https://docs.codeclimate.com/docs/advanced-configuration#section-analysis-configuration-versions
|
|/ / / /
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Since 8180c39, remaining transaction state is cleared in
`force_clear_transaction_record_state` to less work
`sync_with_transaction_state`. But it caused a race condition that
`@transaction_state` would be cleared by other threads if the state is
finalized.
To work as before, snapshot `@transaction_state` to local variable not
to refer `@transaction_state` directly.
Fixes #35983.
|
|\ \ \ \
| | | | |
| | | | | |
mounted routes with non-word characters
|
| | | | | |
|
|\ \ \ \ \
| | | | | |
| | | | | | |
Remove `required: true` from the model generator template
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
`belongs_to` association have `required: true` by default
https://github.com/rails/rails/pull/18937 onwards so we don't need it
in the generator template.
We still need the code for required in the command line generator as
it adds `null: false` in the migration.
|
|\ \ \ \ \ \
| | | | | | |
| | | | | | | |
De-duplicate templates, introduce UnboundTemplate
|
| | | | | | | |
|
| | | | | | | |
|