Skip to content

Conversation

@0xArdi
Copy link
Contributor

@0xArdi 0xArdi commented Nov 7, 2025

🧩 CSV Encoding Fix

The previous implementation manually joined map values with commas:

str := strings.Join(row, ",")

This approach produced invalid CSV output when any value contained commas, quotes, or newlines — for example,
Michael Taolor ⚡️ (τ , τ) would break the format because the comma inside the parentheses was interpreted as a field separator.

This update replaces the manual string join with Go’s standard encoding/csv package, which properly escapes and quotes values according to [RFC 4180](https://www.rfc-editor.org/rfc/rfc4180). It also ensures consistent key order by sorting map keys before encoding.

@maoueh
Copy link
Contributor

maoueh commented Nov 7, 2025

Can you add a quick CHANGELOG entry line, ready to merge afterward.

@maoueh maoueh merged commit dfa5125 into streamingfast:develop Nov 7, 2025
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants