Repository navigation
Add new config option :use_yaml_unsafe_load - #1051
Merged
Merged
Conversation
andrykonchin
force-pushed
the
ak/add-yaml-related-config-options
branch
from
October 2, 2026 21:07
2e42a23 to
6701257
Compare
andrykonchin
force-pushed
the
ak/add-yaml-related-config-options
branch
from
October 2, 2026 22:22
6701257 to
5ec08de
Compare
andrykonchin
force-pushed
the
ak/add-yaml-related-config-options
branch
from
October 2, 2026 22:32
5ec08de to
a0a5d92
Compare
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #1051 +/- ##
==========================================
- Coverage 93.07% 93.03% -0.05%
==========================================
Files 84 84
Lines 4449 4462 +13
==========================================
+ Hits 4141 4151 +10
- Misses 308 311 +3 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds two new configuration options:
use_yaml_unsafe_loadandyaml_permitted_classes. They control how YAML-serialized fields are deserialized (YAML.unsafe_loadvs.YAML.safe_load).These options mirror ActiveRecord's configuration in Rails:
config.active_record.use_yaml_unsafe_loadconfig.active_record.yaml_column_permitted_classesPreviously, safe loading was unconditionally used on Ruby >= 3.1 with a hardcoded list of permitted classes (
[Symbol, Set, Date, Time, DateTime]). Deserialization is now fully configurable while preserving the existing defaults for complete backward compatibility.Previous PR - #889, #757.