aglinxinyuan opened a new pull request, #8067: URL: https://github.com/apache/texera/pull/8067
### What changes were proposed in this PR? Seven pyamber files, five existing specs extended and two new ones added. **+15 fully-covered lines; six of the seven files reach 100%.** | File | Missed before | After | |---|---|---| | `handlers/control/open_executor_handler.py` | 2 (67%) | **0 — 100%** | | `models/schema/schema.py` | 3 (94%) | **0 — 100%** | | `models/schema/attribute_type.py` | 2 (96%) | **0 — 100%** | | `models/table.py` | 2 (95%) | **0 — 100%** | | `proxy/proxy_client.py` | 2 (94%) | **0 — 100%** | | `runnables/network_sender.py` | 2 (96%) | **0 — 100%** | | `storage/iceberg/iceberg_utils.py` | 4 local / 2 CI | 2 left | **No file here is worth a PR alone** — each carries two or three lines. The bundle total is the point, and it is stated that way rather than dressed up per file. `iceberg_utils.py` closes lines 239 and 275; its remaining 302–303 are **already green in CI** and worth zero. The local figure of 4 missed is a local-environment artefact, which is why the honest CI-equivalent gain is +15 and not +17. Tests across the seven files go **37 → 89**. ### A measurement trap worth recording This machine cannot run the Iceberg-backed tests — the postgres `texera` role cannot read `iceberg_tables` — so a raw local coverage run **under-reports**. An earlier assessment of one of these files measured 12 missed lines locally where Codecov showed 2, wrong by 6×. Every target here was sized from Codecov and the local numbers were used only for the delta, never for the ceiling. ### Dead production code found, and deliberately not pinned `attribute_type.py:96-97` normalises a trailing `Z` before calling `datetime.fromisoformat`. **Deleting the whole block leaves the suite byte-identical.** That is not a coverage gap — `fromisoformat` has accepted `Z` since Python 3.11, and the CI matrix is 3.11/3.12/3.13, so the block is dead on every interpreter the project runs. A 10-case differential probe confirmed it. No test was written to pin it. The test that had been named after that branch was **renamed and annotated**, so nothing in the suite claims to constrain a branch that cannot be reached. ### Verification **27 mutations, 26 killed, 1 equivalent** — the equivalent one being the dead block above. Each was applied one at a time against a tree verified hash-equal to a snapshot, reverted from that snapshot rather than from git. Two adversarial reviewers returned nine findings against the first draft; all repaired, adding six further tests. Measured with `--cov=src/main/python` under the exact marker filter CI uses (`-m "not integration"`), no name filter, identical on both sides. The before-state restored each tracked spec **by exact single file path** via `git show HEAD:<path>` and moved the two new specs aside; all seven were then restored from a scratch snapshot and md5-verified. Full pyamber suite: `5 failed, 1269 passed, 7 errors`, with the `FAILED`/`ERROR` set **identical by identity** to main's 12 entries — no regression. `ruff check` and `ruff format --check` pass on CI's exact scope (`src/main/python src/test/python`). Both new spec files carry the Apache licence header. No production file is touched; `git diff -- 'amber/src/main/*'` is empty. ### Any related issues, documentation, discussions? Closes #8065 ### How was this PR tested? ``` cd amber && python -m pytest -m "not integration" -q src/test/python/core/models src/test/python/core/proxy src/test/python/core/runnables/test_network_sender.py src/test/python/core/architecture/handlers/control/test_open_executor_handler.py src/test/python/core/storage/iceberg/test_iceberg_utils_catalog.py ``` ``` 89 passed, 1 warning in 1.73s ``` ### Was this PR authored or co-authored using generative AI tooling? Generated-by: Claude Code (Opus 5) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
