Skip to content

Conversation

@viralpraxis viralpraxis changed the title Prefer JSON's symbolize_names option instead of ActiveSupport's dep_symbolize_keys Prefer JSON's symbolize_names option instead of ActiveSupport's deep_symbolize_keys Oct 11, 2025
@pirj
Copy link
Member

pirj commented Oct 11, 2025

If it’s such a problem, I wonder if AS can somehow mark a freshly parsed object, and issue a warning if deep symbolise is called on it?

@pirj
Copy link
Member

pirj commented Oct 11, 2025

Cc @byroot

@byroot
Copy link

byroot commented Oct 11, 2025

If it’s such a problem

It's wasteful, but not necessarily a problem.

I wonder if AS can somehow mark a freshly parsed object

Nah, would mean monkey patching JSON, to then add an instance variable on a Hash object, that's too wasteful and dirty.

@viralpraxis
Copy link
Author

So does it make sense to implement this rule as a cop?

@pirj
Copy link
Member

pirj commented Oct 18, 2025

As a cop - certainly yes. As a guideline - I’m uncertain if it’s worth it.

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

Labels

None yet

3 participants