Skip to content

Conversation

@7ttp
Copy link
Contributor

@7ttp 7ttp commented Dec 9, 2025

summary

removes unnecessary console.log that spams user logs when jsonb columns contain primitive string values.

problem

the toJson transformer logs JSON parse error to console whenever JSON.parse fails. this happens when jsonb columns store primitive strings. the function already handles this gracefully by returning the original value, but the console.log spams production logs.

fix

remove the console.log. the error is already handled by returning the original value.

closes #1731

cc @mandarini

@7ttp 7ttp requested review from a team as code owners December 9, 2025 19:12
@mandarini mandarini added the realtime-js Related to the realtime-js library. label Dec 15, 2025
@mandarini mandarini changed the title fix(realtime): remove console.log spam from toJson transformer chore(realtime): remove console.log spam from toJson transformer Dec 15, 2025
@coveralls
Copy link

coveralls commented Dec 15, 2025

Coverage Status

coverage: 95.367% (+14.1%) from 81.261%
when pulling 775221e on 7ttp:json1
into 31280b2 on supabase:master.

@mandarini mandarini merged commit 72566c9 into supabase:master Dec 15, 2025
27 checks passed
@7ttp 7ttp deleted the json1 branch December 15, 2025 19:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

realtime-js Related to the realtime-js library.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

JSON parse error: SyntaxError: JSON Parse error: Unexpected character: d

3 participants