Skip to content

BoxLoader decodes all file content as UTF-8 (binaries mangled) #1030

Closed

Description

@AmitoVrito

Follow-up from the #1019 review.

BoxLoader.load() unconditionally does content.decode("utf-8", errors="replace") on every downloaded file, so PDFs/images/other binaries become mojibake rather than being routed through an extractor or emitted as a [Binary file: ...] placeholder (the pattern S3Loader uses).

Proposed: detect binary content-type / non-decodable bytes and either route through the existing extractor path or emit a placeholder + keep the raw bytes in metadata, matching S3Loader. Deferred from the SSRF hardening merge to keep that change focused.

Activity

  1. added
    bug
    enhancement
    on Sep 9, 2026
  2. added a commit that references this issue on Sep 12, 2026
  3. added a commit that references this issue on Sep 15, 2026
    c0d0e8f
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugenhancement

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions