wobbling-ty-constraint-order
Wobbling ty constraint order
TY_CONSTRAINT_SET_ORDER perturbs both the builder-local TDD-variable order and the local typevar order used to orient typevar-to-typevar constraints. The setting is fixed for the lifetime of each test process.
- unset/
0: normal ordering; reverse: reverse both orderings;- an integer: XOR each local ID with that mask. Small masks immediately perturb dense arena IDs:
1swaps adjacent IDs,3reverses blocks of four, and powers of two exchange neighboring blocks.
This deliberately changes internal TDD shape. Run mdtests only: graph-structure unit snapshots are expected to differ. Never enable snapshot updates for a wobble run, since updating would hide the failures being sought.
Run
From the Ruff root, first establish the normal baseline, then run the reversed and XOR-masked orders sequentially. Set TY_CONSTRAINT_ORDER_LOG_DIR to retain logs in a particular writable directory; otherwise mktemp chooses an appropriate temporary directory (respecting the environment's temporary-directory configuration).
set -u