activesupport 7.0.3.1 → 7.2.3.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +261 -246
- data/MIT-LICENSE +1 -1
- data/README.rdoc +7 -7
- data/lib/active_support/actionable_error.rb +3 -1
- data/lib/active_support/array_inquirer.rb +3 -1
- data/lib/active_support/backtrace_cleaner.rb +39 -7
- data/lib/active_support/benchmarkable.rb +1 -0
- data/lib/active_support/broadcast_logger.rb +238 -0
- data/lib/active_support/builder.rb +1 -1
- data/lib/active_support/cache/coder.rb +153 -0
- data/lib/active_support/cache/entry.rb +134 -0
- data/lib/active_support/cache/file_store.rb +51 -19
- data/lib/active_support/cache/mem_cache_store.rb +114 -134
- data/lib/active_support/cache/memory_store.rb +85 -30
- data/lib/active_support/cache/null_store.rb +8 -2
- data/lib/active_support/cache/redis_cache_store.rb +175 -154
- data/lib/active_support/cache/serializer_with_fallback.rb +152 -0
- data/lib/active_support/cache/strategy/local_cache.rb +64 -13
- data/lib/active_support/cache.rb +455 -378
- data/lib/active_support/callbacks.rb +121 -136
- data/lib/active_support/code_generator.rb +15 -10
- data/lib/active_support/concern.rb +4 -2
- data/lib/active_support/concurrency/load_interlock_aware_monitor.rb +42 -3
- data/lib/active_support/concurrency/null_lock.rb +13 -0
- data/lib/active_support/configurable.rb +10 -0
- data/lib/active_support/core_ext/array/conversions.rb +1 -2
- data/lib/active_support/core_ext/array.rb +0 -1
- data/lib/active_support/core_ext/benchmark.rb +1 -0
- data/lib/active_support/core_ext/class/attribute.rb +2 -2
- data/lib/active_support/core_ext/class/subclasses.rb +17 -34
- data/lib/active_support/core_ext/date/blank.rb +4 -0
- data/lib/active_support/core_ext/date/calculations.rb +15 -0
- data/lib/active_support/core_ext/date/conversions.rb +1 -2
- data/lib/active_support/core_ext/date.rb +0 -1
- data/lib/active_support/core_ext/date_and_time/calculations.rb +10 -0
- data/lib/active_support/core_ext/date_and_time/compatibility.rb +28 -1
- data/lib/active_support/core_ext/date_time/blank.rb +4 -0
- data/lib/active_support/core_ext/date_time/calculations.rb +4 -0
- data/lib/active_support/core_ext/date_time/conversions.rb +6 -4
- data/lib/active_support/core_ext/date_time.rb +0 -1
- data/lib/active_support/core_ext/digest/uuid.rb +7 -10
- data/lib/active_support/core_ext/enumerable.rb +25 -80
- data/lib/active_support/core_ext/erb/util.rb +201 -0
- data/lib/active_support/core_ext/hash/conversions.rb +1 -1
- data/lib/active_support/core_ext/hash/deep_merge.rb +22 -14
- data/lib/active_support/core_ext/hash/deep_transform_values.rb +3 -3
- data/lib/active_support/core_ext/hash/keys.rb +7 -7
- data/lib/active_support/core_ext/integer/inflections.rb +12 -12
- data/lib/active_support/core_ext/module/attr_internal.rb +17 -6
- data/lib/active_support/core_ext/module/attribute_accessors.rb +6 -0
- data/lib/active_support/core_ext/module/attribute_accessors_per_thread.rb +34 -16
- data/lib/active_support/core_ext/module/concerning.rb +6 -6
- data/lib/active_support/core_ext/module/delegation.rb +20 -119
- data/lib/active_support/core_ext/module/deprecation.rb +12 -12
- data/lib/active_support/core_ext/module/introspection.rb +3 -1
- data/lib/active_support/core_ext/numeric/bytes.rb +9 -0
- data/lib/active_support/core_ext/numeric/conversions.rb +5 -3
- data/lib/active_support/core_ext/numeric.rb +0 -1
- data/lib/active_support/core_ext/object/blank.rb +45 -1
- data/lib/active_support/core_ext/object/deep_dup.rb +16 -0
- data/lib/active_support/core_ext/object/duplicable.rb +25 -16
- data/lib/active_support/core_ext/object/inclusion.rb +13 -5
- data/lib/active_support/core_ext/object/instance_variables.rb +4 -2
- data/lib/active_support/core_ext/object/json.rb +17 -7
- data/lib/active_support/core_ext/object/to_query.rb +0 -2
- data/lib/active_support/core_ext/object/try.rb +2 -2
- data/lib/active_support/core_ext/object/with.rb +46 -0
- data/lib/active_support/core_ext/object/with_options.rb +9 -9
- data/lib/active_support/core_ext/object.rb +1 -0
- data/lib/active_support/core_ext/pathname/blank.rb +20 -0
- data/lib/active_support/core_ext/pathname/existence.rb +2 -0
- data/lib/active_support/core_ext/pathname.rb +1 -0
- data/lib/active_support/core_ext/range/conversions.rb +28 -7
- data/lib/active_support/core_ext/range/overlap.rb +40 -0
- data/lib/active_support/core_ext/range/sole.rb +17 -0
- data/lib/active_support/core_ext/range.rb +2 -2
- data/lib/active_support/core_ext/securerandom.rb +24 -12
- data/lib/active_support/core_ext/string/conversions.rb +1 -1
- data/lib/active_support/core_ext/string/filters.rb +24 -18
- data/lib/active_support/core_ext/string/indent.rb +1 -1
- data/lib/active_support/core_ext/string/inflections.rb +16 -9
- data/lib/active_support/core_ext/string/multibyte.rb +3 -3
- data/lib/active_support/core_ext/string/output_safety.rb +41 -178
- data/lib/active_support/core_ext/thread/backtrace/location.rb +12 -0
- data/lib/active_support/core_ext/time/calculations.rb +40 -30
- data/lib/active_support/core_ext/time/compatibility.rb +24 -0
- data/lib/active_support/core_ext/time/conversions.rb +1 -3
- data/lib/active_support/core_ext/time/zones.rb +7 -8
- data/lib/active_support/core_ext/time.rb +0 -1
- data/lib/active_support/core_ext.rb +0 -1
- data/lib/active_support/current_attributes.rb +60 -46
- data/lib/active_support/deep_mergeable.rb +53 -0
- data/lib/active_support/delegation.rb +202 -0
- data/lib/active_support/dependencies/autoload.rb +9 -16
- data/lib/active_support/deprecation/behaviors.rb +64 -41
- data/lib/active_support/deprecation/constant_accessor.rb +47 -25
- data/lib/active_support/deprecation/deprecators.rb +104 -0
- data/lib/active_support/deprecation/disallowed.rb +6 -8
- data/lib/active_support/deprecation/method_wrappers.rb +6 -23
- data/lib/active_support/deprecation/proxy_wrappers.rb +34 -22
- data/lib/active_support/deprecation/reporting.rb +49 -27
- data/lib/active_support/deprecation.rb +39 -9
- data/lib/active_support/deprecator.rb +7 -0
- data/lib/active_support/descendants_tracker.rb +66 -172
- data/lib/active_support/duration/iso8601_parser.rb +2 -2
- data/lib/active_support/duration/iso8601_serializer.rb +1 -4
- data/lib/active_support/duration.rb +13 -7
- data/lib/active_support/encrypted_configuration.rb +63 -11
- data/lib/active_support/encrypted_file.rb +29 -13
- data/lib/active_support/environment_inquirer.rb +22 -2
- data/lib/active_support/error_reporter/test_helper.rb +15 -0
- data/lib/active_support/error_reporter.rb +163 -36
- data/lib/active_support/evented_file_update_checker.rb +17 -3
- data/lib/active_support/execution_wrapper.rb +5 -6
- data/lib/active_support/file_update_checker.rb +6 -4
- data/lib/active_support/fork_tracker.rb +4 -32
- data/lib/active_support/gem_version.rb +2 -2
- data/lib/active_support/gzip.rb +2 -0
- data/lib/active_support/hash_with_indifferent_access.rb +50 -30
- data/lib/active_support/html_safe_translation.rb +19 -6
- data/lib/active_support/i18n.rb +1 -1
- data/lib/active_support/i18n_railtie.rb +20 -13
- data/lib/active_support/inflector/inflections.rb +2 -0
- data/lib/active_support/inflector/methods.rb +28 -18
- data/lib/active_support/inflector/transliterate.rb +3 -1
- data/lib/active_support/isolated_execution_state.rb +26 -22
- data/lib/active_support/json/decoding.rb +3 -2
- data/lib/active_support/json/encoding.rb +48 -48
- data/lib/active_support/key_generator.rb +9 -1
- data/lib/active_support/lazy_load_hooks.rb +22 -7
- data/lib/active_support/locale/en.yml +2 -0
- data/lib/active_support/log_subscriber.rb +74 -34
- data/lib/active_support/logger.rb +22 -59
- data/lib/active_support/logger_thread_safe_level.rb +10 -32
- data/lib/active_support/message_encryptor.rb +197 -53
- data/lib/active_support/message_encryptors.rb +141 -0
- data/lib/active_support/message_pack/cache_serializer.rb +23 -0
- data/lib/active_support/message_pack/extensions.rb +305 -0
- data/lib/active_support/message_pack/serializer.rb +63 -0
- data/lib/active_support/message_pack.rb +50 -0
- data/lib/active_support/message_verifier.rb +229 -89
- data/lib/active_support/message_verifiers.rb +137 -0
- data/lib/active_support/messages/codec.rb +65 -0
- data/lib/active_support/messages/metadata.rb +111 -45
- data/lib/active_support/messages/rotation_coordinator.rb +93 -0
- data/lib/active_support/messages/rotator.rb +38 -31
- data/lib/active_support/messages/serializer_with_fallback.rb +158 -0
- data/lib/active_support/multibyte/chars.rb +8 -3
- data/lib/active_support/multibyte/unicode.rb +9 -37
- data/lib/active_support/notifications/fanout.rb +248 -87
- data/lib/active_support/notifications/instrumenter.rb +93 -25
- data/lib/active_support/notifications.rb +36 -29
- data/lib/active_support/number_helper/number_converter.rb +16 -7
- data/lib/active_support/number_helper/number_to_currency_converter.rb +6 -6
- data/lib/active_support/number_helper/number_to_delimited_converter.rb +17 -2
- data/lib/active_support/number_helper/number_to_human_size_converter.rb +3 -3
- data/lib/active_support/number_helper/number_to_phone_converter.rb +1 -0
- data/lib/active_support/number_helper.rb +379 -317
- data/lib/active_support/option_merger.rb +4 -4
- data/lib/active_support/ordered_hash.rb +3 -3
- data/lib/active_support/ordered_options.rb +67 -15
- data/lib/active_support/parameter_filter.rb +103 -84
- data/lib/active_support/proxy_object.rb +8 -3
- data/lib/active_support/railtie.rb +25 -20
- data/lib/active_support/reloader.rb +12 -4
- data/lib/active_support/rescuable.rb +10 -8
- data/lib/active_support/secure_compare_rotator.rb +16 -9
- data/lib/active_support/string_inquirer.rb +4 -2
- data/lib/active_support/subscriber.rb +10 -27
- data/lib/active_support/syntax_error_proxy.rb +60 -0
- data/lib/active_support/tagged_logging.rb +64 -40
- data/lib/active_support/test_case.rb +160 -7
- data/lib/active_support/testing/assertions.rb +28 -12
- data/lib/active_support/testing/autorun.rb +0 -2
- data/lib/active_support/testing/constant_stubbing.rb +54 -0
- data/lib/active_support/testing/deprecation.rb +20 -27
- data/lib/active_support/testing/error_reporter_assertions.rb +107 -0
- data/lib/active_support/testing/isolation.rb +46 -33
- data/lib/active_support/testing/method_call_assertions.rb +7 -8
- data/lib/active_support/testing/parallelization/server.rb +18 -2
- data/lib/active_support/testing/parallelization/worker.rb +2 -2
- data/lib/active_support/testing/parallelization.rb +12 -1
- data/lib/active_support/testing/parallelize_executor.rb +8 -3
- data/lib/active_support/testing/setup_and_teardown.rb +2 -0
- data/lib/active_support/testing/stream.rb +1 -1
- data/lib/active_support/testing/tests_without_assertions.rb +19 -0
- data/lib/active_support/testing/time_helpers.rb +38 -16
- data/lib/active_support/time_with_zone.rb +18 -44
- data/lib/active_support/values/time_zone.rb +25 -14
- data/lib/active_support/version.rb +1 -1
- data/lib/active_support/xml_mini/jdom.rb +3 -10
- data/lib/active_support/xml_mini/nokogiri.rb +1 -1
- data/lib/active_support/xml_mini/nokogirisax.rb +1 -1
- data/lib/active_support/xml_mini/rexml.rb +1 -1
- data/lib/active_support/xml_mini.rb +14 -3
- data/lib/active_support.rb +15 -3
- metadata +148 -24
- data/lib/active_support/core_ext/array/deprecated_conversions.rb +0 -25
- data/lib/active_support/core_ext/date/deprecated_conversions.rb +0 -26
- data/lib/active_support/core_ext/date_time/deprecated_conversions.rb +0 -22
- data/lib/active_support/core_ext/numeric/deprecated_conversions.rb +0 -60
- data/lib/active_support/core_ext/range/deprecated_conversions.rb +0 -26
- data/lib/active_support/core_ext/range/include_time_with_zone.rb +0 -7
- data/lib/active_support/core_ext/range/overlaps.rb +0 -10
- data/lib/active_support/core_ext/time/deprecated_conversions.rb +0 -22
- data/lib/active_support/core_ext/uri.rb +0 -5
- data/lib/active_support/deprecation/instance_delegator.rb +0 -38
- data/lib/active_support/per_thread_registry.rb +0 -65
- data/lib/active_support/ruby_features.rb +0 -7
data/CHANGELOG.md
CHANGED
|
@@ -1,438 +1,453 @@
|
|
|
1
|
-
## Rails 7.
|
|
1
|
+
## Rails 7.2.3.1 (March 23, 2026) ##
|
|
2
2
|
|
|
3
|
-
*
|
|
3
|
+
* Reject scientific notation in NumberConverter
|
|
4
4
|
|
|
5
|
+
[CVE-2026-33176]
|
|
5
6
|
|
|
6
|
-
|
|
7
|
+
*Jean Boussier*
|
|
7
8
|
|
|
8
|
-
*
|
|
9
|
+
* Fix `SafeBuffer#%` to preserve unsafe status
|
|
9
10
|
|
|
11
|
+
[CVE-2026-33170]
|
|
10
12
|
|
|
11
|
-
|
|
13
|
+
*Jean Boussier*
|
|
12
14
|
|
|
13
|
-
*
|
|
15
|
+
* Improve performance of NumberToDelimitedConverter
|
|
14
16
|
|
|
15
|
-
|
|
16
|
-
in names of tags and names of attributes, following the specification of XML.
|
|
17
|
+
[CVE-2026-33169]
|
|
17
18
|
|
|
18
|
-
|
|
19
|
+
*Jean Boussier*
|
|
19
20
|
|
|
20
|
-
## Rails 7.0.2.3 (March 08, 2022) ##
|
|
21
21
|
|
|
22
|
-
|
|
22
|
+
## Rails 7.2.3 (October 28, 2025) ##
|
|
23
23
|
|
|
24
|
+
* Fix `Enumerable#sole` to return the full tuple instead of just the first element of the tuple.
|
|
24
25
|
|
|
25
|
-
|
|
26
|
+
*Olivier Bellone*
|
|
26
27
|
|
|
27
|
-
* Fix
|
|
28
|
+
* Fix parallel tests hanging when worker processes die abruptly.
|
|
28
29
|
|
|
30
|
+
Previously, if a worker process was killed (e.g., OOM killed, `kill -9`) during parallel
|
|
31
|
+
test execution, the test suite would hang forever waiting for the dead worker.
|
|
29
32
|
|
|
30
|
-
|
|
33
|
+
*Joshua Young*
|
|
31
34
|
|
|
32
|
-
*
|
|
35
|
+
* `ActiveSupport::FileUpdateChecker` does not depend on `Time.now` to prevent unnecessary reloads with time travel test helpers
|
|
33
36
|
|
|
37
|
+
*Jan Grodowski*
|
|
34
38
|
|
|
35
|
-
|
|
39
|
+
* Fix `ActiveSupport::BroadcastLogger` from executing a block argument for each logger (tagged, info, etc.).
|
|
36
40
|
|
|
37
|
-
*
|
|
41
|
+
*Jared Armstrong*
|
|
38
42
|
|
|
39
|
-
|
|
43
|
+
* Fix `ActiveSupport::HashWithIndifferentAccess#transform_keys!` removing defaults.
|
|
40
44
|
|
|
41
|
-
*
|
|
45
|
+
*Hartley McGuire*
|
|
42
46
|
|
|
43
|
-
|
|
47
|
+
* Fix `ActiveSupport::HashWithIndifferentAccess#tranform_keys!` to handle collisions.
|
|
44
48
|
|
|
49
|
+
If the transformation would result in a key equal to another not yet transformed one,
|
|
50
|
+
it would result in keys being lost.
|
|
45
51
|
|
|
46
|
-
|
|
52
|
+
Before:
|
|
47
53
|
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
54
|
+
```ruby
|
|
55
|
+
>> {a: 1, b: 2}.with_indifferent_access.transform_keys!(&:succ)
|
|
56
|
+
=> {"c" => 1}
|
|
57
|
+
```
|
|
52
58
|
|
|
53
|
-
|
|
59
|
+
After:
|
|
54
60
|
|
|
61
|
+
```ruby
|
|
62
|
+
>> {a: 1, b: 2}.with_indifferent_access.transform_keys!(&:succ)
|
|
63
|
+
=> {"c" => 1, "d" => 2}
|
|
64
|
+
```
|
|
55
65
|
|
|
56
|
-
|
|
66
|
+
*Jason T Johnson*, *Jean Boussier*
|
|
57
67
|
|
|
58
|
-
* Fix `ActiveSupport::
|
|
68
|
+
* Fix `ActiveSupport::Cache::MemCacheStore#read_multi` to handle network errors.
|
|
59
69
|
|
|
60
|
-
|
|
61
|
-
ignored the sign of the `value` and accumulated incorrect part values. This
|
|
62
|
-
impacted `ActiveSupport::Duration#sum` (which is dependent on `parts`) but
|
|
63
|
-
not `ActiveSupport::Duration#eql?` (which is dependent on `value`).
|
|
70
|
+
This method specifically wasn't handling network errors like other codepaths.
|
|
64
71
|
|
|
65
|
-
*
|
|
72
|
+
*Alessandro Dal Grande*
|
|
66
73
|
|
|
74
|
+
* Fix Active Support Cache `fetch_multi` when local store is active.
|
|
67
75
|
|
|
68
|
-
|
|
76
|
+
`fetch_multi` now properly yield to the provided block for missing entries
|
|
77
|
+
that have been recorded as such in the local store.
|
|
69
78
|
|
|
70
|
-
*
|
|
79
|
+
*Jean Boussier*
|
|
71
80
|
|
|
81
|
+
* Fix execution wrapping to report all exceptions, including `Exception`.
|
|
72
82
|
|
|
73
|
-
|
|
83
|
+
If a more serious error like `SystemStackError` or `NoMemoryError` happens,
|
|
84
|
+
the error reporter should be able to report these kinds of exceptions.
|
|
74
85
|
|
|
75
|
-
*
|
|
86
|
+
*Gannon McGibbon*
|
|
76
87
|
|
|
77
|
-
|
|
88
|
+
* Fix `RedisCacheStore` and `MemCacheStore` to also handle connection pool related errors.
|
|
78
89
|
|
|
79
|
-
|
|
80
|
-
`BigDecimal`, `Float` and, `Integer`.
|
|
90
|
+
These errors are rescued and reported to `Rails.error`.
|
|
81
91
|
|
|
82
|
-
*
|
|
92
|
+
*Jean Boussier*
|
|
83
93
|
|
|
84
|
-
*
|
|
94
|
+
* Fix `ActiveSupport::Cache#read_multi` to respect version expiry when using local cache.
|
|
85
95
|
|
|
86
|
-
*
|
|
96
|
+
*zzak*
|
|
87
97
|
|
|
88
|
-
*
|
|
98
|
+
* Fix `ActiveSupport::MessageVerifier` and `ActiveSupport::MessageEncryptor` configuration of `on_rotation` callback.
|
|
89
99
|
|
|
90
100
|
```ruby
|
|
91
|
-
|
|
101
|
+
verifier.rotate(old_secret).on_rotation { ... }
|
|
92
102
|
```
|
|
93
103
|
|
|
94
|
-
|
|
104
|
+
Now both work as documented.
|
|
95
105
|
|
|
96
|
-
*
|
|
106
|
+
*Jean Boussier*
|
|
97
107
|
|
|
98
|
-
|
|
108
|
+
* Fix `ActiveSupport::MessageVerifier` to always be able to verify both URL-safe and URL-unsafe payloads.
|
|
99
109
|
|
|
100
|
-
|
|
101
|
-
|
|
110
|
+
This is to allow transitioning seemlessly from either configuration without immediately invalidating
|
|
111
|
+
all previously generated signed messages.
|
|
102
112
|
|
|
103
|
-
*
|
|
113
|
+
*Jean Boussier*, *Florent Beaurain*, *Ali Sepehri*
|
|
104
114
|
|
|
105
|
-
*
|
|
115
|
+
* Fix `cache.fetch` to honor the provided expiry when `:race_condition_ttl` is used.
|
|
106
116
|
|
|
107
|
-
|
|
117
|
+
```ruby
|
|
118
|
+
cache.fetch("key", expires_in: 1.hour, race_condition_ttl: 5.second) do
|
|
119
|
+
"something"
|
|
120
|
+
end
|
|
121
|
+
```
|
|
108
122
|
|
|
109
|
-
|
|
123
|
+
In the above example, the final cache entry would have a 10 seconds TTL instead
|
|
124
|
+
of the requested 1 hour.
|
|
110
125
|
|
|
111
|
-
*
|
|
126
|
+
*Dhia*
|
|
112
127
|
|
|
113
|
-
*
|
|
114
|
-
`ActiveSupport::OptionMerger` instance.
|
|
128
|
+
* Better handle procs with splat arguments in `set_callback`.
|
|
115
129
|
|
|
116
|
-
*
|
|
130
|
+
*Radamés Roriz*
|
|
131
|
+
|
|
132
|
+
* Fix `String#mb_chars` to not mutate the receiver.
|
|
117
133
|
|
|
118
|
-
|
|
134
|
+
Previously it would call `force_encoding` on the receiver,
|
|
135
|
+
now it dups the receiver first.
|
|
119
136
|
|
|
120
|
-
|
|
121
|
-
leaking from one test to another.
|
|
137
|
+
*Jean Boussier*
|
|
122
138
|
|
|
123
|
-
|
|
139
|
+
* Improve `ErrorSubscriber` to also mark error causes as reported.
|
|
124
140
|
|
|
125
|
-
|
|
141
|
+
This avoid some cases of errors being reported twice, notably in views because of how
|
|
142
|
+
errors are wrapped in `ActionView::Template::Error`.
|
|
126
143
|
|
|
127
144
|
*Jean Boussier*
|
|
128
145
|
|
|
129
|
-
* `
|
|
130
|
-
|
|
131
|
-
Ruby now provides a fast `Class#descendants` making `ActiveSupport::DescendantsTracker` mostly useless.
|
|
146
|
+
* Fix `Module#module_parent_name` to return the correct name after the module has been named.
|
|
132
147
|
|
|
133
|
-
|
|
148
|
+
When called on an anonymous module, the return value wouldn't change after the module was given a name
|
|
149
|
+
later by being assigned to a constant.
|
|
134
150
|
|
|
135
|
-
|
|
136
|
-
|
|
151
|
+
```ruby
|
|
152
|
+
mod = Module.new
|
|
153
|
+
mod.module_parent_name # => "Object"
|
|
154
|
+
MyModule::Something = mod
|
|
155
|
+
mod.module_parent_name # => "MyModule"
|
|
156
|
+
```
|
|
137
157
|
|
|
138
158
|
*Jean Boussier*
|
|
139
159
|
|
|
140
|
-
* Fix
|
|
141
|
-
|
|
142
|
-
The new behavior will be enabled by setting the
|
|
143
|
-
`config.active_support.use_rfc4122_namespaced_uuids` option to `true`
|
|
144
|
-
and is the default for new apps.
|
|
160
|
+
* Fix a bug in `ERB::Util.tokenize` that causes incorrect tokenization when ERB tags are preceeded by multibyte characters.
|
|
145
161
|
|
|
146
|
-
|
|
147
|
-
deprecation warning every time a value that is different than one of
|
|
148
|
-
the constants defined on the `Digest::UUID` extension is used as the
|
|
149
|
-
namespace ID.
|
|
162
|
+
*Martin Emde*
|
|
150
163
|
|
|
151
|
-
*Alex Robbin*, *Erich Soares Machado*, *Eugene Kenny*
|
|
152
164
|
|
|
153
|
-
|
|
154
|
-
and `inflector.clear` / `inflector.clear(:all)` also clears acronyms.
|
|
165
|
+
## Rails 7.2.2.2 (August 13, 2025) ##
|
|
155
166
|
|
|
156
|
-
|
|
167
|
+
* No changes.
|
|
157
168
|
|
|
158
169
|
|
|
159
|
-
## Rails 7.
|
|
170
|
+
## Rails 7.2.2.1 (December 10, 2024) ##
|
|
160
171
|
|
|
161
172
|
* No changes.
|
|
162
173
|
|
|
163
174
|
|
|
164
|
-
## Rails 7.
|
|
175
|
+
## Rails 7.2.2 (October 30, 2024) ##
|
|
165
176
|
|
|
166
|
-
*
|
|
177
|
+
* Include options when instrumenting `ActiveSupport::Cache::Store#delete` and `ActiveSupport::Cache::Store#delete_multi`.
|
|
167
178
|
|
|
168
|
-
*
|
|
179
|
+
*Adam Renberg Tamm*
|
|
169
180
|
|
|
170
|
-
*
|
|
181
|
+
* Print test names when running `rails test -v` for parallel tests.
|
|
171
182
|
|
|
172
|
-
*
|
|
183
|
+
*John Hawthorn*, *Abeid Ahmed*
|
|
173
184
|
|
|
174
|
-
* The private API of `ActiveSupport::Dependencies` has been deleted. That includes methods like `hook!`, `unhook!`, `depend_on`, `require_or_load`, `mechanism`, and many others.
|
|
175
185
|
|
|
176
|
-
|
|
186
|
+
## Rails 7.2.1.2 (October 23, 2024) ##
|
|
177
187
|
|
|
178
|
-
*
|
|
188
|
+
* No changes.
|
|
179
189
|
|
|
180
|
-
*Mike Dalessio*
|
|
181
190
|
|
|
182
|
-
|
|
191
|
+
## Rails 7.2.1.1 (October 15, 2024) ##
|
|
183
192
|
|
|
184
|
-
|
|
185
|
-
the error handler would be rescued and logged only. Removed the `rescue` clause from `handle_exception`
|
|
186
|
-
to allow these to be thrown.
|
|
193
|
+
* No changes.
|
|
187
194
|
|
|
188
|
-
*Nicholas A. Stuart*
|
|
189
195
|
|
|
190
|
-
|
|
196
|
+
## Rails 7.2.1 (August 22, 2024) ##
|
|
191
197
|
|
|
192
|
-
|
|
193
|
-
still be done on each call to `ActiveSupport::Deprecation.warn`. In very hot paths, this could
|
|
194
|
-
cause performance issues.
|
|
198
|
+
* No changes.
|
|
195
199
|
|
|
196
|
-
Now, you can make `ActiveSupport::Deprecation.warn` a no-op:
|
|
197
200
|
|
|
198
|
-
|
|
199
|
-
config.active_support.report_deprecations = false
|
|
200
|
-
```
|
|
201
|
+
## Rails 7.2.0 (August 09, 2024) ##
|
|
201
202
|
|
|
202
|
-
|
|
203
|
+
* Fix `delegate_missing_to allow_nil: true` when called with implict self
|
|
203
204
|
|
|
204
205
|
```ruby
|
|
205
|
-
|
|
206
|
-
|
|
206
|
+
class Person
|
|
207
|
+
delegate_missing_to :address, allow_nil: true
|
|
208
|
+
|
|
209
|
+
def address
|
|
210
|
+
nil
|
|
211
|
+
end
|
|
212
|
+
|
|
213
|
+
def berliner?
|
|
214
|
+
city == "Berlin"
|
|
215
|
+
end
|
|
216
|
+
end
|
|
217
|
+
|
|
218
|
+
Person.new.city # => nil
|
|
219
|
+
Person.new.berliner? # undefined local variable or method `city' for an instance of Person (NameError)
|
|
207
220
|
```
|
|
208
221
|
|
|
209
|
-
|
|
222
|
+
*Jean Boussier*
|
|
210
223
|
|
|
211
|
-
|
|
224
|
+
* Add `logger` as a dependency since it is a bundled gem candidate for Ruby 3.5
|
|
212
225
|
|
|
213
|
-
*
|
|
214
|
-
of them.
|
|
226
|
+
*Earlopain*
|
|
215
227
|
|
|
216
|
-
|
|
217
|
-
setup and fixture loading. Now, Rails will only parallelize test executions when
|
|
218
|
-
there are enough tests to make it worth it.
|
|
228
|
+
* Define `Digest::UUID.nil_uuid`, which returns the so-called nil UUID.
|
|
219
229
|
|
|
220
|
-
|
|
221
|
-
your test.rb:
|
|
230
|
+
*Xavier Noria*
|
|
222
231
|
|
|
223
|
-
|
|
224
|
-
config.active_support.test_parallelization_threshold = 100
|
|
225
|
-
```
|
|
232
|
+
* Support `duration` type in `ActiveSupport::XmlMini`.
|
|
226
233
|
|
|
227
|
-
|
|
234
|
+
*heka1024*
|
|
228
235
|
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
end
|
|
233
|
-
```
|
|
236
|
+
* Remove deprecated `ActiveSupport::Notifications::Event#children` and `ActiveSupport::Notifications::Event#parent_of?`.
|
|
237
|
+
|
|
238
|
+
*Rafael Mendonça França*
|
|
234
239
|
|
|
235
|
-
|
|
240
|
+
* Remove deprecated support to call the following methods without passing a deprecator:
|
|
236
241
|
|
|
237
|
-
|
|
242
|
+
- `deprecate`
|
|
243
|
+
- `deprecate_constant`
|
|
244
|
+
- `ActiveSupport::Deprecation::DeprecatedObjectProxy.new`
|
|
245
|
+
- `ActiveSupport::Deprecation::DeprecatedInstanceVariableProxy.new`
|
|
246
|
+
- `ActiveSupport::Deprecation::DeprecatedConstantProxy.new`
|
|
247
|
+
- `assert_deprecated`
|
|
248
|
+
- `assert_not_deprecated`
|
|
249
|
+
- `collect_deprecations`
|
|
238
250
|
|
|
239
|
-
*
|
|
251
|
+
*Rafael Mendonça França*
|
|
240
252
|
|
|
241
|
-
* `
|
|
242
|
-
A valid ordinal value will be converted to an instance of `TimeWithZone` using the `:year`
|
|
243
|
-
and `:yday` fragments returned from `Date._iso8601`.
|
|
253
|
+
* Remove deprecated `ActiveSupport::Deprecation` delegation to instance.
|
|
244
254
|
|
|
245
|
-
|
|
246
|
-
twz = ActiveSupport::TimeZone["Eastern Time (US & Canada)"].iso8601("21087")
|
|
247
|
-
twz.to_a[0, 6] == [0, 0, 0, 28, 03, 2021]
|
|
248
|
-
```
|
|
255
|
+
*Rafael Mendonça França*
|
|
249
256
|
|
|
250
|
-
|
|
257
|
+
* Remove deprecated `SafeBuffer#clone_empty`.
|
|
251
258
|
|
|
252
|
-
*
|
|
253
|
-
return a `Time` with the timezone argument provided, if the caller was
|
|
254
|
-
initialized with a timezone argument.
|
|
259
|
+
*Rafael Mendonça França*
|
|
255
260
|
|
|
256
|
-
|
|
261
|
+
* Remove deprecated `#to_default_s` from `Array`, `Date`, `DateTime` and `Time`.
|
|
257
262
|
|
|
258
|
-
*
|
|
263
|
+
*Rafael Mendonça França*
|
|
259
264
|
|
|
260
|
-
*
|
|
265
|
+
* Remove deprecated support to passing `Dalli::Client` instances to `MemCacheStore`.
|
|
261
266
|
|
|
262
|
-
*
|
|
267
|
+
*Rafael Mendonça França*
|
|
263
268
|
|
|
264
|
-
*
|
|
265
|
-
`RAILS_MASTER_KEY` environment variable is blank (e.g. `""`).
|
|
269
|
+
* Remove deprecated `config.active_support.use_rfc4122_namespaced_uuids`.
|
|
266
270
|
|
|
267
|
-
*
|
|
271
|
+
*Rafael Mendonça França*
|
|
268
272
|
|
|
269
|
-
*
|
|
273
|
+
* Remove deprecated `config.active_support.remove_deprecated_time_with_zone_name`.
|
|
270
274
|
|
|
271
|
-
|
|
275
|
+
*Rafael Mendonça França*
|
|
272
276
|
|
|
273
|
-
|
|
274
|
-
assert_no_changes -> { Status.all_good? }, from: true do
|
|
275
|
-
post :create, params: { status: { ok: true } }
|
|
276
|
-
end
|
|
277
|
-
```
|
|
277
|
+
* Remove deprecated `config.active_support.disable_to_s_conversion`.
|
|
278
278
|
|
|
279
|
-
*
|
|
279
|
+
*Rafael Mendonça França*
|
|
280
280
|
|
|
281
|
-
*
|
|
281
|
+
* Remove deprecated support to bolding log text with positional boolean in `ActiveSupport::LogSubscriber#color`.
|
|
282
282
|
|
|
283
|
-
|
|
284
|
-
to be implicitly converted to a String in string operations. In some
|
|
285
|
-
circumstances `ActiveSupport::SafeBuffer` was incorrectly calling the
|
|
286
|
-
explicit conversion method (`#to_s`) on them. This behavior is now
|
|
287
|
-
deprecated.
|
|
283
|
+
*Rafael Mendonça França*
|
|
288
284
|
|
|
289
|
-
|
|
285
|
+
* Remove deprecated constants `ActiveSupport::LogSubscriber::CLEAR` and `ActiveSupport::LogSubscriber::BOLD`.
|
|
290
286
|
|
|
291
|
-
*
|
|
287
|
+
*Rafael Mendonça França*
|
|
292
288
|
|
|
293
|
-
|
|
289
|
+
* Remove deprecated support for `config.active_support.cache_format_version = 6.1`.
|
|
294
290
|
|
|
295
|
-
|
|
291
|
+
*Rafael Mendonça França*
|
|
296
292
|
|
|
297
|
-
|
|
298
|
-
aws:
|
|
299
|
-
access_key_id: 123
|
|
300
|
-
secret_access_key: 345
|
|
301
|
-
```
|
|
293
|
+
* Remove deprecated `:pool_size` and `:pool_timeout` options for the cache storage.
|
|
302
294
|
|
|
303
|
-
|
|
304
|
-
`Rails.application.credentials.aws[:access_key_id]`.
|
|
295
|
+
*Rafael Mendonça França*
|
|
305
296
|
|
|
306
|
-
|
|
297
|
+
* Warn on tests without assertions.
|
|
307
298
|
|
|
308
|
-
|
|
299
|
+
`ActiveSupport::TestCase` now warns when tests do not run any assertions.
|
|
300
|
+
This is helpful in detecting broken tests that do not perform intended assertions.
|
|
309
301
|
|
|
310
|
-
|
|
311
|
-
`config.load_defaults 7.0`. Regardless of the configuration Active Support
|
|
312
|
-
7.0 can read cache entries serialized by Active Support 6.1 which allows to
|
|
313
|
-
upgrade without invalidating the cache. However Rails 6.1 can't read the
|
|
314
|
-
new format, so all readers must be upgraded before the new format is enabled.
|
|
302
|
+
*fatkodima*
|
|
315
303
|
|
|
316
|
-
|
|
304
|
+
* Support `hexBinary` type in `ActiveSupport::XmlMini`.
|
|
305
|
+
|
|
306
|
+
*heka1024*
|
|
317
307
|
|
|
318
|
-
*
|
|
319
|
-
sole item of the enumerable, raising if no items are found, or if more than
|
|
320
|
-
one is.
|
|
308
|
+
* Deprecate `ActiveSupport::ProxyObject` in favor of Ruby's built-in `BasicObject`.
|
|
321
309
|
|
|
322
|
-
*
|
|
310
|
+
*Earlopain*
|
|
323
311
|
|
|
324
|
-
*
|
|
312
|
+
* `stub_const` now accepts a `exists: false` parameter to allow stubbing missing constants.
|
|
325
313
|
|
|
326
|
-
|
|
314
|
+
*Jean Boussier*
|
|
315
|
+
|
|
316
|
+
* Make `ActiveSupport::BacktraceCleaner` copy filters and silencers on dup and clone.
|
|
327
317
|
|
|
328
|
-
|
|
318
|
+
Previously the copy would still share the internal silencers and filters array,
|
|
319
|
+
causing state to leak.
|
|
329
320
|
|
|
330
|
-
*
|
|
321
|
+
*Jean Boussier*
|
|
331
322
|
|
|
332
|
-
|
|
333
|
-
instance had fractional seconds the new UTC time instance was out by
|
|
334
|
-
a factor of 1,000,000 as the `Time.utc` constructor takes a usec
|
|
335
|
-
value and not a fractional second value.
|
|
323
|
+
* Updating Astana with Western Kazakhstan TZInfo identifier.
|
|
336
324
|
|
|
337
|
-
*
|
|
325
|
+
*Damian Nelson*
|
|
338
326
|
|
|
339
|
-
* Add
|
|
327
|
+
* Add filename support for `ActiveSupport::Logger.logger_outputs_to?`.
|
|
340
328
|
|
|
341
329
|
```ruby
|
|
342
|
-
|
|
330
|
+
logger = Logger.new('/var/log/rails.log')
|
|
331
|
+
ActiveSupport::Logger.logger_outputs_to?(logger, '/var/log/rails.log')
|
|
343
332
|
```
|
|
344
333
|
|
|
345
|
-
*
|
|
334
|
+
*Christian Schmidt*
|
|
346
335
|
|
|
347
|
-
*
|
|
336
|
+
* Include `IPAddr#prefix` when serializing an `IPAddr` using the
|
|
337
|
+
`ActiveSupport::MessagePack` serializer.
|
|
348
338
|
|
|
349
|
-
|
|
339
|
+
This change is backward and forward compatible — old payloads can
|
|
340
|
+
still be read, and new payloads will be readable by older versions of Rails.
|
|
350
341
|
|
|
351
|
-
*
|
|
352
|
-
is considerably faster.
|
|
342
|
+
*Taiki Komaba*
|
|
353
343
|
|
|
354
|
-
|
|
344
|
+
* Add `default:` support for `ActiveSupport::CurrentAttributes.attribute`.
|
|
355
345
|
|
|
356
346
|
```ruby
|
|
357
|
-
|
|
358
|
-
|
|
347
|
+
class Current < ActiveSupport::CurrentAttributes
|
|
348
|
+
attribute :counter, default: 0
|
|
349
|
+
end
|
|
350
|
+
```
|
|
351
|
+
|
|
352
|
+
*Sean Doyle*
|
|
353
|
+
|
|
354
|
+
* Yield instance to `Object#with` block.
|
|
359
355
|
|
|
360
|
-
|
|
361
|
-
|
|
356
|
+
```ruby
|
|
357
|
+
client.with(timeout: 5_000) do |c|
|
|
358
|
+
c.get("/commits")
|
|
359
|
+
end
|
|
362
360
|
```
|
|
363
361
|
|
|
364
|
-
*
|
|
362
|
+
*Sean Doyle*
|
|
363
|
+
|
|
364
|
+
* Use logical core count instead of physical core count to determine the
|
|
365
|
+
default number of workers when parallelizing tests.
|
|
365
366
|
|
|
366
|
-
*
|
|
367
|
+
*Jonathan Hefner*
|
|
367
368
|
|
|
368
|
-
|
|
369
|
+
* Fix `Time.now/DateTime.now/Date.today` to return results in a system timezone after `#travel_to`.
|
|
369
370
|
|
|
370
|
-
|
|
371
|
+
There is a bug in the current implementation of #travel_to:
|
|
372
|
+
it remembers a timezone of its argument, and all stubbed methods start
|
|
373
|
+
returning results in that remembered timezone. However, the expected
|
|
374
|
+
behavior is to return results in a system timezone.
|
|
371
375
|
|
|
372
|
-
*
|
|
376
|
+
*Aleksei Chernenkov*
|
|
373
377
|
|
|
374
|
-
|
|
378
|
+
* Add `ErrorReported#unexpected` to report precondition violations.
|
|
375
379
|
|
|
376
|
-
|
|
377
|
-
elements of an enumerable.
|
|
380
|
+
For example:
|
|
378
381
|
|
|
379
382
|
```ruby
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
383
|
+
def edit
|
|
384
|
+
if published?
|
|
385
|
+
Rails.error.unexpected("[BUG] Attempting to edit a published article, that shouldn't be possible")
|
|
386
|
+
return false
|
|
387
|
+
end
|
|
388
|
+
# ...
|
|
389
|
+
end
|
|
384
390
|
```
|
|
385
391
|
|
|
386
|
-
|
|
387
|
-
See PR [#41404](https://github.com/rails/rails/pull/41404) for an example.
|
|
392
|
+
The above will raise an error in development and test, but only report the error in production.
|
|
388
393
|
|
|
389
|
-
*
|
|
394
|
+
*Jean Boussier*
|
|
390
395
|
|
|
391
|
-
* `
|
|
396
|
+
* Make the order of read_multi and write_multi notifications for `Cache::Store#fetch_multi` operations match the order they are executed in.
|
|
392
397
|
|
|
393
|
-
|
|
394
|
-
config.cache_store = :mem_cache_store, nil
|
|
398
|
+
*Adam Renberg Tamm*
|
|
395
399
|
|
|
396
|
-
|
|
400
|
+
* Make return values of `Cache::Store#write` consistent.
|
|
397
401
|
|
|
398
|
-
|
|
402
|
+
The return value was not specified before. Now it returns `true` on a successful write,
|
|
403
|
+
`nil` if there was an error talking to the cache backend, and `false` if the write failed
|
|
404
|
+
for another reason (e.g. the key already exists and `unless_exist: true` was passed).
|
|
399
405
|
|
|
400
|
-
|
|
406
|
+
*Sander Verdonschot*
|
|
401
407
|
|
|
402
|
-
|
|
408
|
+
* Fix logged cache keys not always matching actual key used by cache action.
|
|
403
409
|
|
|
404
|
-
|
|
405
|
-
|
|
410
|
+
*Hartley McGuire*
|
|
411
|
+
|
|
412
|
+
* Improve error messages of `assert_changes` and `assert_no_changes`.
|
|
413
|
+
|
|
414
|
+
`assert_changes` error messages now display objects with `.inspect` to make it easier
|
|
415
|
+
to differentiate nil from empty strings, strings from symbols, etc.
|
|
416
|
+
`assert_no_changes` error messages now surface the actual value.
|
|
417
|
+
|
|
418
|
+
*pcreux*
|
|
406
419
|
|
|
407
|
-
|
|
420
|
+
* Fix `#to_fs(:human_size)` to correctly work with negative numbers.
|
|
408
421
|
|
|
409
|
-
*
|
|
422
|
+
*Earlopain*
|
|
410
423
|
|
|
411
|
-
*
|
|
424
|
+
* Fix `BroadcastLogger#dup` so that it duplicates the logger's `broadcasts`.
|
|
412
425
|
|
|
413
|
-
*
|
|
426
|
+
*Andrew Novoselac*
|
|
414
427
|
|
|
415
|
-
* `
|
|
416
|
-
`String#camelize` behavior.
|
|
428
|
+
* Fix issue where `bootstrap.rb` overwrites the `level` of a `BroadcastLogger`'s `broadcasts`.
|
|
417
429
|
|
|
418
|
-
*
|
|
430
|
+
*Andrew Novoselac*
|
|
419
431
|
|
|
420
|
-
*
|
|
421
|
-
invalid.
|
|
432
|
+
* Fix compatibility with the `semantic_logger` gem.
|
|
422
433
|
|
|
423
|
-
|
|
434
|
+
The `semantic_logger` gem doesn't behave exactly like stdlib logger in that
|
|
435
|
+
`SemanticLogger#level` returns a Symbol while stdlib `Logger#level` returns an Integer.
|
|
424
436
|
|
|
425
|
-
|
|
437
|
+
This caused the various `LogSubscriber` classes in Rails to break when assigned a
|
|
438
|
+
`SemanticLogger` instance.
|
|
426
439
|
|
|
427
|
-
*
|
|
440
|
+
*Jean Boussier*, *ojab*
|
|
428
441
|
|
|
429
|
-
*
|
|
442
|
+
* Fix MemoryStore to prevent race conditions when incrementing or decrementing.
|
|
430
443
|
|
|
431
|
-
*
|
|
444
|
+
*Pierre Jambet*
|
|
432
445
|
|
|
433
|
-
*
|
|
446
|
+
* Implement `HashWithIndifferentAccess#to_proc`.
|
|
434
447
|
|
|
435
|
-
|
|
448
|
+
Previously, calling `#to_proc` on `HashWithIndifferentAccess` object used inherited `#to_proc`
|
|
449
|
+
method from the `Hash` class, which was not able to access values using indifferent keys.
|
|
436
450
|
|
|
451
|
+
*fatkodima*
|
|
437
452
|
|
|
438
|
-
Please check [
|
|
453
|
+
Please check [7-1-stable](https://github.com/rails/rails/blob/7-1-stable/activesupport/CHANGELOG.md) for previous changes.
|