| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
| |
Currently predicate builder cannot build a predicate for `array|range`
attribute. This commit fixes the issue.
Related #25671.
|
|\
| |
| | |
add missing require rake
|
| |
| |
| |
| |
| | |
In ff8035dfeed8c86594c32ef8e9204806e190cb58, require rake is deferred.
Therefore, it is necessary to require rake even `Engine::CommandsTasks.
|
|\ \
| |/
|/| |
Fix actionview test failure
|
|/
|
|
| |
Caused by #26092.
|
|\
| |
| | |
Minor doc fix related to ActiveModel::SecurePassword [ci skip]
|
| | |
|
| |
| |
| |
| |
| |
| | |
Thinking .. relative to files is not natural, we are used
to think "parent of a directory", and we have __dir__
nowadays.
|
|\ \
| | |
| | | |
Add documentation for `http_cache_forever`. [ci skip]
|
| | | |
|
|\ \ \
| | | |
| | | | |
Allow specifying encoding of parameters by action
|
| | | |
| | | |
| | | |
| | | |
| | | | |
At GitHub we need to handle parameter encodings that are not UTF-8. This
patch allows us to specify encodings per parameter per action.
|
|\ \ \ \
| | | | |
| | | | | |
Fix a NoMethodError schema_statements.rb
|
| | |/ /
| |/| |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
If you call `remove_index` with wrong options, say a type, like I did,
you get:
```
== 20160810072541 RemoveUniqueIndexOnGoals: migrating =========================
-- remove_index(:goal, {:coulmn=>:kid_id, :unique=>true})
rails aborted!
StandardError: An error has occurred, this and all later migrations canceled:
undefined method `ArgumentError' for #<ActiveRecord::ConnectionAdapters::PostgreSQLAdapter:0x007fb7dec91b28>
```
What happened is that I mistyped column (coulmn) and got a
`NoMethodError`, because of a missing comma during the raise. This made
Ruby think we're calling the method `ArgumentError`.
|
|/ / /
| | |
| | |
| | |
| | |
| | |
| | | |
In c546a2b parameter handling in AC test cases was changed to
round tripping through encoders/decoders so that they matched
reality and in 0adb8f8 the old methods were removed but the
`html_format?` method was overlooked.
|
|\ \ \
| |_|/
|/| | |
Fix broken alignments caused by auto-correct commit 411ccbd
|
|/ /
| |
| |
| | |
Hash syntax auto-correcting breaks alignments. 411ccbdab2608c62aabdb320d52cb02d446bb39c
|
|\ \
| | |
| | | |
Document know limitation about using `references` in conjunction with custom select clauses [ci skip]
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
loading causing it to ignore custom select clauses.
[ci skip]
Fixes #24314
|
|\ \ \
| |/ /
|/| | |
Add link to 'Pry' in debugging guide [ci skip]
|
| | | |
|
|\ \ \
| |_|/
|/| | |
update list of rescue_responses default [ci skip]
|
|/ /
| |
| |
| | |
Follow up to fe859a54219740fa8b4e09a592820d2ee12ba222
|
| | |
|
|\ \
| | |
| | | |
Use `FETCH FIRST` for Oracle12 and test `ROWNUM <=` for Oracle 11g or older version to test sql limit behavior
|
|/ /
| |
| |
| |
| | |
also test `ROWNUM <=` for Oracle 11g or older version of Oracle and Oracle visitor
Oracle 12c database and Arel Oracle12 visitor supports better top N query.
|
| |
| |
| |
| |
| |
| |
| | |
This code has too much duplication and the rationale for the concatenation
may not be obvious to the reader. You define the ones at class-level, explain
why does the code concatenates there, and then the convenience ones at
instance-level just delegate.
|
|\ \
| | |
| | |
| | | |
Fix `thread_mattr_accessor` share variable superclass with subclass
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
The current implementation of `thread_mattr_accessor` set variable
sharing superclass with subclass. So the method doesn't work as documented.
Precondition
class Account
thread_mattr_accessor :user
end
class Customer < Account
end
Account.user = "DHH"
Account.user #=> "DHH"
Customer.user = "Rafael"
Customer.user # => "Rafael"
Documented behavior
Account.user # => "DHH"
Actual behavior
Account.user # => "Rafael"
Current implementation set variable statically likes `Thread[:attr_Account_user]`,
and customer also use it.
Make variable name dynamic to use own thread-local variable.
|
| | | |
|
| | | |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
A few have been left for aesthetic reasons, but have made a pass
and removed most of them.
Note that if the method `foo` returns an array, `foo << 1`
is a regular push, nothing to do with assignments, so
no self required.
|
| | |
| | |
| | |
| | | |
Some case expressions remain, need to think about those ones.
|
| | | |
|
| | | |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Inserted spaces in the name of Rails components.
Since I was on it, also used PostgreSQL instead of Postgres
because albeit Postgres is an accepted alias, PostgreSQL is
the official name and the actual name of the adapter.
See
https://wiki.postgresql.org/wiki/ProjectName
with regard to PostgreSQL vs Postgres.
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
In some test runs `ActionController::Base.enable_fragment_cache_logging` would be false,
based on the test order.
Turns out it was off because we assigned the config to the `@controller` variable, and
not on `ActionController::Base`.
The test failure was reproducible with, and now passes after this:
```
bin/test test/controller/log_subscriber_test.rb --seed 19918
```
|
| | | |
|
| | |
| | |
| | |
| | |
| | | |
The entry was a result of a combination of changes in Action View
and Action Controller.
|
| | | |
|
| | | |
|
|\ \ \
| |_|/
|/| | |
Better logging of cached partial renders
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Implement naive partial caching mechanism.
Add test for LogSubscriber
Use ActionView::Base#log_payload to store log_subscriber's payload, so we can pass cache result into it.
Fixed tests
Remove useless settings
Check if #log_payload exists before calling it. Because other classes also includes CacheHelper but don't have is attribute
Use @log_payload_for_partial_reder instead of #log_payload to carry ActionView's payload.
Update test's hash syntax
Add configuration to enable/disable fragment caching logging
Remove unless test and add new test to ensure cache info won't effect next rendering's log
Move :enable_fragment_cache_logging config from ActionView to ActionPack
Apply new config to tests
Update actionview's changelog
Update configuration guide
Improve actionview's changelog
Refactor PartialRenderer#render and log tests
Mute subscriber's log instead of disabling instrumentation.
Fix typo, remove useless comment and use new hash syntax
Improve actionpack's log_subscriber test
Fix rebase mistake
Apply new config to all caching intstrument actions
|
|\ \ \
| |/ /
|/| | |
Fix Accept header overwritten issue when "xhr: true" in integration test
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
In integration test when specify the "Accept" header with "xhr: true"
option, the Accept header is overridden with a default xhr Accept
header. The issue only affects HTTP header "Accept" but not CGI variable
"HTTP_ACCEPT".
For example:
get '/page', headers: { 'Accept' => 'application/json' }, xhr: true
# This is WRONG! And the response.content_type is also affected.
# It should be "application/json"
assert_equal "text/javascript, text/html, ...", request.accept
assert_equal 'text/html', response.content_type
The issue is in `ActionDispatch::Integration::RequestHelpers`. When
setting "xhr: true" the helper sets a default HTTP_ACCEPT if blank.
But the code doesn't consider supporting both HTTP header style and
CGI variable style.
For detail see this GitHub issue:
https://github.com/rails/rails/issues/25859
|
|\ \ \
| | | |
| | | | |
`ActiveRecord::PredicateBuilder#expand` to be private
|
| | | |
| | | |
| | | |
| | | | |
This method is not touched from outside.
|
|\ \ \ \
| | | | |
| | | | |
| | | | |
| | | | | |
y-yagi/show_error_message_when_error_raised_in_rails_runner
show error message when error raised in rails runner
|
| | | | | |
|
| |_|/ /
|/| | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Eagerly requiring Rake could put 100ms on to the Rails boot time. Shimmy that
down to 0 by requiring Rake when no native Rails command exists and we try to
run a Rake task. Or when printing all the Rake commands through `rails help`.
Fixes #25029
|