Skip to content

fix(core): permit Symbol and HashWithIndifferentAccess in log entries - #6529

Open
tvdeyen wants to merge 1 commit into
solidusio:mainfrom
blish:add-symbol-hwia-to-permitted-classes
Open

fix(core): permit Symbol and HashWithIndifferentAccess in log entries#6529
tvdeyen wants to merge 1 commit into
solidusio:mainfrom
blish:add-symbol-hwia-to-permitted-classes

Conversation

@tvdeyen

@tvdeyen tvdeyen commented Jul 31, 2026

Copy link
Copy Markdown
Member

Summary

Serialized log entry details frequently contain symbols and HashWithIndifferentAccess instances (e.g. from payment gateway responses and request params). Because neither class was permitted, serializing such details raised a DisallowedClass error while writing parsed_details= unless every integrator added them to log_entry_permitted_classes themselves. Since both are core Ruby and Rails value types with no safe-loading risk here, permit them by default.

Checklist

Check out our PR guidelines for more details.

The following are mandatory for all PRs:

The following are not always needed:

  • 📖 I have updated the README to account for my changes.
  • 📑 I have documented new code with YARD.
  • 🛣️ I have opened a PR to update the guides.
  • ✅ I have added automated tests to cover my changes.
  • 📸 I have attached screenshots to demo visual changes.

Serialized log entry details frequently contain symbols and
HashWithIndifferentAccess instances (e.g. from payment gateway
responses and request params). Because neither class was permitted,
serializing such details raised a DisallowedClass error while writing
`parsed_details=` unless every integrator added them to
`log_entry_permitted_classes` themselves. Since both are core Ruby and
Rails value types with no safe-loading risk here, permit them by
default.
@tvdeyen
tvdeyen requested a review from a team as a code owner July 31, 2026 08:52
@github-actions github-actions Bot added the changelog:solidus_core Changes to the solidus_core gem label Jul 31, 2026
@codecov

codecov Bot commented Jul 31, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 92.38%. Comparing base (72f9fcd) to head (05f4be3).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #6529      +/-   ##
==========================================
- Coverage   95.07%   92.38%   -2.70%     
==========================================
  Files         460       42     -418     
  Lines        7924      788    -7136     
==========================================
- Hits         7534      728    -6806     
+ Misses        390       60     -330     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

changelog:solidus_core Changes to the solidus_core gem

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant