Repository navigation
Fix Encoding Gate Order, Installer Self-Test UTF-8, Signal Window, and Doc Findings - #4343
Conversation
…elf-Test The encoding gate counted an earlier PYTHONIOENCODING entry as enough even where a later unpacking overwrote it. It now applies each entry and unpacking in order. The installer's self-test child decoded as UTF-8 without being told to emit it, and the test helper let extra_env override the entry. Co-Authored-By: Claude Opus 5.5 <[email protected]>
A dict() keyword cannot be given twice, so it decides wherever it sits. An unpacked display that never names the variable no longer resets the reading, and a | merge is read in order like an unpacking. The test helper's reorder is dropped, since the keyword was already final. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the
|
|
A recorded local strict-review pass covers head |
There was a problem hiding this comment.
🟡 Changes recommended
A remaining nit requests a regression test covering the child environment override, leaving the change without verification that the installer enforces UTF-8 under a non-UTF-8 parent setting.
1 open issue
What changed in this PR
This PR improves UTF-8 handling for Python child processes and makes encoding analysis respect environment updates in evaluation order.
Changes:
- Adds ordered handling for dictionary displays,
|merges, anddict(...)calls. - Adds regression coverage for environment unpacking and merge patterns.
- Passes
PYTHONIOENCODING=utf-8to installer self-test subprocesses.
| File | Description |
|---|---|
| tests/test_tooling_encoding.py | Adds ordered environment analysis and regression tests for dictionary displays, merges, and unpacked mappings. |
| host-setup/agent-safety/claude/install.py | Sets PYTHONIOENCODING=utf-8 in the environment of installer self-test child processes. |
Review effort: Lite
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## develop #4343 +/- ##
========================================
Coverage 79.54% 79.55%
========================================
Files 45 45
Lines 15919 15923 +4
========================================
+ Hits 12663 12667 +4
Misses 3256 3256
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
|
@coderabbitai review |
|
/review |
Action not completed
|
Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
A recorded local strict-review pass covers head |
Keep an append-only clean branch unrewritten, read merge commits before a rebase drops them, and qualify where CodeRabbit reads its configuration. Type the installer entry points and start its try before the signal handlers register. Bound the readiness waits in the interrupt tests. Make the encoding gate stop a name lookup at a parameter and let a replacement after an item write defeat the call. Co-Authored-By: Claude Opus 5.5 <[email protected]>
…the Gate The rebase chain now stops after the rebase where the old head carried a merge commit. The encoding gate lets a later self-reading rebinding or a literal display through and defeats the call on a later update from the environment. A readiness failure kills the child before reading its output. Co-Authored-By: Claude Opus 5.5 <[email protected]>
…by What They Add The conflict path skipped the merge check, so it now names it. The encoding gate no longer treats an item set as binding a name, includes writes on the setting line, and judges a later self-reading rebinding on what it adds. Co-Authored-By: Claude Opus 5.5 <[email protected]>
…the Merge Check Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
A recorded local strict-review pass covers head |

Fixes the verified Copilot and CodeRabbit findings on promotion PR #4342.
|merge, and adict(...)call in order. Adict(...)keyword is final. A name lookup stops at a function parameter or an assignment. A rebinding or a non-literal mutation after an item write has to carry the variable too. Regression tests cover each shape.PYTHONIOENCODING=utf-8, with a test that sets a cp1252 parent value.main()starts itstrybefore the signal handlers register, with a test for a signal right after registration.docs/pr-reviewer-reference.mdis qualified for a trusted same-repository pull request, a fork, and the configuration-source setting.This touches
host-setup/agent-safety/claude/, so it waits for the maintainer's go-ahead before merging.Closes on promotion: none
Pre-existing findings, not filed
tests/test_tooling_encoding.py,_name_carriesrebinding path: a later mutation after a rebinding that setsPYTHONIOENCODING, such asenv.update(os.environ), is not read. Class: pre-existing, a gate gap on a shape no call in the repository uses.tests/test_tooling_encoding.py,_name_carriesrebinding path: a rebinding that reads the name and itself sets the variable is flagged though it carries it. Class: pre-existing, conservative false positive on a shape no call in the repository uses.🤖 Generated with Claude Code