test(conftest): force ENGRAPHIS_EXTRACTOR=none for the offline gate - #165
Closed
Coding-Dev-Tools wants to merge 1 commit into
Closed
test(conftest): force ENGRAPHIS_EXTRACTOR=none for the offline gate#165Coding-Dev-Tools wants to merge 1 commit into
Coding-Dev-Tools wants to merge 1 commit into
Conversation
setdefault kept a real shell export working, so an owner machine exporting ENGRAPHIS_EXTRACTOR=llm_structured leaked a live LLM extractor into every ingest-path test. Under tests/conftest.py's DNS stub the extraction call hangs instead of failing fast, deterministically timing out test_session_close_linearizes_before_delayed_memory_write[ingest]. Force the variable to "none" like ENGRAPHIS_UPDATE_CHECK; tests that exercise extraction already opt back in explicitly via monkeypatch.setenv.
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
Owner
Author
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Forces
ENGRAPHIS_EXTRACTOR=nonein the rootconftest.pyinstead of usingsetdefault, closing a leak where an owner-machine shell export (ENGRAPHIS_EXTRACTOR=llm_structured) put a live LLM extractor into the offline unit gate.Root cause
python -m pytest tests/ -qto pass network-free.os.environ.setdefault("ENGRAPHIS_EXTRACTOR", "none"), which defers to any pre-existing shell variable.tests/conftest.py's DNS stub the extraction call hangs rather than failing fast.test_session_close_linearizes_before_delayed_memory_write[ingest]— the writer thread never reached the embed hook within the test window.Fix
os.environ["ENGRAPHIS_EXTRACTOR"] = "none"), matching the existingENGRAPHIS_UPDATE_CHECKtreatment in the same file.monkeypatch.setenv; no test relies on shell-passthrough (verified by grep acrosstests/).Verification
pytest tests/ -qdistributed: green (exit 0).