Private
Public Access
0
0
Files
manual_slop/scripts
ed 195c626ad8 fix(generate_type_registry): atomic write_registry to fix xdist race
The previous write_registry wiped existing .md files first, then wrote
new ones. When multiple xdist workers ran the script concurrently, they
would clobber each other mid-write, causing intermittent test failures
(test_generate_type_registry.py would see missing or stale files).

Fix: generate to a sibling staging directory (PID+timestamp suffix)
first, then use os.replace() to atomically swap into place. No observer
can see the registry in a partial state.

The staging dir is built manually (not via tempfile) because
scripts/audit_no_temp_writes.py forbids tempfile imports in scripts/.

Verified: 6/6 tests in test_generate_type_registry.py PASS in isolation
and in tier-1-unit-core batch (was: 2 failed due to race); audit CLEAN.
2026-06-30 11:54:40 -04:00
..
2026-06-30 05:40:19 -04:00
2026-06-06 12:47:41 -04:00
2026-06-07 11:51:36 -04:00
2026-06-07 11:51:36 -04:00
2026-02-27 22:10:46 -05:00
2026-02-27 22:10:46 -05:00
2026-02-27 22:10:46 -05:00