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