Skip to content

Studio tests: read the FLUX.2 reference gate sources as UTF-8 (encoding guard red on main) - #18947

Merged
danielhanchen merged 1 commit into
mainfrom
fix/ref-preprocess-gate-utf8
Nov 22, 2026
Merged

danielhanchen merged 1 commit into
mainfrom
fix/ref-preprocess-gate-utf8

Conversation

@danielhanchen

Copy link
Copy Markdown
Member

Summary

Repo tests (CPU, rest-2) is red on main since #18917:

tests/test_source_read_encoding.py:1029: in test_checked_in_file_reads_name_an_encoding
E   AssertionError: 2 file reads in the test trees touch a checked-in file with the platform default encoding,
    so they break on Windows as soon as that file gains a non-ASCII byte. Pass encoding = "utf-8":
    ['studio/backend/tests/test_diffusion_ref_preprocess_gate.py:34: read_text()',
     'studio/backend/tests/test_diffusion_ref_preprocess_gate.py:40: read_text()']

#18917 added test_diffusion_ref_preprocess_gate.py, whose source checks read diffusion_lanczos_triton.py and diffusion.py with a bare read_text(). The guard is right: on Windows that uses the locale code page.

Fix

Both reads pass encoding = "utf-8". Only the test changes.

Testing

  • tests/test_source_read_encoding.py: 1 failed on main (the two reads above), 16 passed with this change.
  • studio/backend/tests/test_diffusion_ref_preprocess_gate.py: 5 passed.

@danielhanchen

Copy link
Copy Markdown
Member Author

@codex review

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 22, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-22T20:19:47.551140Z 061919b Manual request
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Another round soon, please!

Reviewed commit: 061919ba68

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@danielhanchen
danielhanchen merged commit 87c402b into main Nov 22, 2026
@danielhanchen
danielhanchen deleted the fix/ref-preprocess-gate-utf8 branch November 22, 2026 20:20
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