Skip to content

Handle UTF-8 BOMs in every JSON input file - #8841

Open
jinchuntan wants to merge 1 commit into
huggingface:mainfrom
jinchuntan:fix/json-bom-later-files
Open

jinchuntan wants to merge 1 commit into
huggingface:mainfrom
jinchuntan:fix/json-bom-later-files

Conversation

@jinchuntan

@jinchuntan jinchuntan commented Oct 18, 2026 •

Copy link
Copy Markdown
Contributor

Follow up to #8243. Strip the UTF-8 BOM at the start of each JSON input file. Multifile loads with inferred or explicit List(Json()) columns otherwise fail when a later file has a BOM.

Adds eight regression cases covering inferred/explicit features and regular/streaming loads, including multiple batches and BOM characters inside values. Four cases fail on main. all eight pass with the fix.

Validation: JSON loader and reader tests: 63 passed, 11 skipped. make quality passes.

Strip the BOM at the start of each input file so JSON feature re-encoding works for later shards. Cover inferred and explicit features with regular and streaming multi-file loads.

Assisted-by: Codex
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.

1 participant