Skip to content

Keep awake test: read keep_awake.rs as UTF-8 (encoding lint red since #17659) - #18125

Merged
danielhanchen merged 1 commit into
mainfrom
ci-keep-awake-test-utf8
Nov 17, 2026
Merged

danielhanchen merged 1 commit into
mainfrom
ci-keep-awake-test-utf8

Conversation

@danielhanchen

Copy link
Copy Markdown
Member

tests/test_source_read_encoding.py::test_checked_in_file_reads_name_an_encoding fails on main in the CPU rest-2 shard since #17659 (seen on the staging run of #18122):

E   AssertionError: 1 file reads in the test trees touch a checked-in file with the platform default encoding, ...
E     + 'tests/studio/test_keep_awake_initialization.py:10: read_text()'

Cause

tests/studio/test_keep_awake_initialization.py (added in #17659) reads studio/src-tauri/src/keep_awake.rs with read_text(). Without an encoding that uses the locale codepage on Windows (cp1252, cp932, ...), so the test breaks there as soon as the Rust file gains a non-ASCII byte. The lint is right; the new test missed it.

Fix

read_text(encoding = "utf-8").

Verification

  • main: the lint fails with the line above.
  • this branch: tests/test_source_read_encoding.py 16 passed.

@danielhanchen

Copy link
Copy Markdown
Member Author

@codex review

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 17, 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-17T10:49:24.624784Z 78ed1bb 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. More of your lovely PRs please.

Reviewed commit: 78ed1bbc28

ℹ️ 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 9b2e749 into main Nov 17, 2026
@danielhanchen
danielhanchen deleted the ci-keep-awake-test-utf8 branch November 17, 2026 10:49
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