You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
T034: repair the nine files that go red once 2.1 lands (research R3; 16.6's phase-1 repair) - #50
Plan 034, task T034, slice P1-F (the sweep and the nine-file repair). The plan is specs/034-opendox-standalone-operation/tasks.md at opensoft/openxFactory main468863d1, where round 2 (#1176) has landed. The T034 entry there is byte-identical to 0d48231b's, which this record was first written against. This PR realizes box 9.1 (part) and 16.6 (the phase-1 repair) of the ratified add-neutral-product-standalone-operability.
Ruled: R1Q2 (a) and R1Q22 (a), openxFactory#656 comment 5817152735. Eight of the nine files are carved moved_with_declared_edit rows, and tests/test_consumer_reach.py has no row. None needs a declared-edit act.
For T007's batch E and T047: what this PR moves to openxFactory
Four test cases leave openDox-code and become NAMED openxFactory composition tests (R1Q2 (a)). T007's batch E adds each destination path to F11.1's named set (COMPOSITION_TESTS) before T047 lands. T047's openxFactory PR lands the cases there, and T049 checks that they arrived. tests/test_session_harness.py is not moved here. It is in collect_ignore, and it is T035's.
The holder's decision on the three memory-gateway cases: accepted under R1Q2 (a) (relayed to this lane's writer, 2026-09-27). T034's text names only the outline case. The memory-gateway cases take the same route because the spec they read exists only in openxFactory.
It holds views/outline-model.js's REQUIRED_SECTIONS and QUESTION_SUBFIELDS equal to openxFactory's doc_health.families (_TEMPLATE_SECTIONS, _QUESTION_SUBFIELDS). It imports doc_health, which openDox can never install. openDox has no checker of its own until Group 6 (release 2), so there is no openDox contract to rewrite it against.
It reads openspec/specs/memory-gateway/spec.md, the promoted capability that doxbench_memory_gateway.CAPABILITY_REQUIREMENTS is transcribed from. That spec is openxFactory's, and no openDox repository carries a copy (checked in openDox-spec, openDox, openXdox-spec, openXdox and openXdox-code). It failed on FileNotFoundError.
Both destinations compose openDox at openxFactory's pin, which scripts/carved_reach.py already puts on the path for tests/ideation-dashboard/. The outline case then reads openDox/code/src/opendox/web/views/outline-model.js from the pin, and the memory-gateway cases import opendox.doxbench_memory_gateway. The paths are proposals. If T047's writer chooses others, batch E records what T047 lands. The cases' own text, verbatim from main19370adc, is below, so no archaeology is needed.
The outline-template agreement case (from tests/test_outline_model.py)
deftest_the_model_and_the_doc_health_family_agree_on_the_contract():
"""The surface and the checker must mean the same thing by conformance."""importsyssys.path.insert(0, str(REPO_ROOT/"scripts"))
fromdoc_healthimportfamiliesjs=MODEL_JS.read_text(encoding="utf-8")
for_needle, labelinfamilies._TEMPLATE_SECTIONS:
assertf'label: "{label}"'injs, f"model omits required section {label}"forfieldinfamilies._QUESTION_SUBFIELDS:
assertf'"{field}"'injs, f"model omits sub-field {field}"
MODEL_JS was REPO_ROOT / "src/opendox/web/views/outline-model.js". At openxFactory it is the pinned leg's copy of that file.
The three memory-gateway roster cases (from tests/test_doxbench_memory_gateway.py)
SPEC_PATH=REPO_ROOT/"openspec"/"specs"/"memory-gateway"/"spec.md"# ===========================================================================# THE ROSTER — transcribed, and asserted against the capability itself# ===========================================================================deftest_the_roster_is_exactly_the_promoted_capabilitys_requirements():
"""The declaration is only complete if the roster it is complete OVER is the capability's own. Read from the promoted spec, so a requirement added upstream fails here rather than becoming a silent gap in the declaration."""published= {
line[len("### Requirement: "):].strip()
forlineinSPEC_PATH.read_text(encoding="utf-8").splitlines()
ifline.startswith("### Requirement: ")
}
assertpublished==set(mg.CAPABILITY_REQUIREMENTS)
def_published_tiers() ->dict[str, str]:
"""The spec's OWN tier block, parsed: requirement name -> the tier line it is named on."""spec=SPEC_PATH.read_text(encoding="utf-8")
block=spec.split("```text", 1)[1].split("```", 1)[0]
published: dict[str, str] = {}
formatchinre.finditer(r"(M\d):((?:.|\n)*?)(?=\nM\d:|\Z)", block):
tier, body=match.group(1), " ".join(match.group(2).split())
fornameinbody.split(";"):
published[name.strip().rstrip(".")] =tierreturnpublisheddeftest_the_tier_column_is_TRANSCRIBED_not_invented():
"""RE-PINNED (adversarial review, F7). The roster test checked NAMES only, so two wrong tier values sat in the column unchallenged: one requirement carried `M0` although the spec's tier block never tiers it at all, and `Expert Memory And Knowledge DBs Are Gateway-Governed` was FLATTENED to `M4` although the spec says in as many words that it follows the tier of the operation it mirrors. Both are now transcribed, and this test reads the spec's own block so neither error can recur silently."""published=_published_tiers()
forrequirement, declaredinmg.CAPABILITY_REQUIREMENTS.items():
named= [lineforlineinpublishedifline.lower().startswith(requirement.lower())]
ifnotnamed:
# Not tiered by the spec at all -- which the column must SAY.assertdeclared==mg.TIER_UNTIERED, requirementcontinueline=named[0]
ifline!=requirement:
# The spec qualifies this row rather than tiering it outright.assertdeclared==mg.TIER_MIRRORS_OPERATION, requirementassert"follows the tier of the operation it mirrors"inlinecontinueassertdeclared==published[line], requirementdeftest_the_untiered_requirement_really_is_absent_from_the_tier_block():
published=_published_tiers()
untiered= [nameforname, tierinmg.CAPABILITY_REQUIREMENTS.items()
iftier==mg.TIER_UNTIERED]
# TWO since 2026-08-22: add-doxbench-editing-phase-b's archive promoted# `Subject-Free Local Consumers…` into the capability, and the spec's tier# block does not tier it either. The list stays EXACT rather than becoming# a membership check — an untiered requirement is a fact about the spec, so# a third one appearing should fail here and be looked at.assertuntiered== [
"Derived memory bindings validate against the neutral schema",
"Subject-Free Local Consumers Declare Their Inapplicable Rails"]
fornameinuntiered:
assertnotany(line.lower().startswith(name.lower())
forlineinpublished)
mg is opendox.doxbench_memory_gateway, and the helper needs import re. At openxFactory, REPO_ROOT is openxFactory's own root, where the spec is (22 requirements at 0d48231b, and CAPABILITY_REQUIREMENTS holds 22).
The nine files (research R3), at main68be484a and at this head
With the root conftest in play, Python 3.12.3, -c constraints-cpython312-linux.txt -e ".[test]". The nine files give the same results on main at 68be484a as at 19370adc:
file
main
this head
cause
repair
test_doxbench_abstract_pane.py
18 passed, 28 errors
46 passed
§ 3.4 slice S5 moved the workbench gate column out of the bundle, so a shell mounted with no column withholds the canvas, and the generate control with it
The harness is the host, so it contributes the column app.js resolves. It imports _CONTRIBUTED_GATE from test_doxbench_view.py, whose S7 note gives the reason, the way it already imports the DOM shim. The column answers createGateLive off the same caps, so the ungated and hosted mounts still have no gate.
test_outline_tab.py
3 passed, 25 errors
28 passed
the same
the same, and the pre-template sentence reads the SELECTION role's word from NEUTRAL_DISPLAY. It spelled openxFactory's "staged" before S7 parameterized it.
none left after T011, whose bullet says "T034 re-derives the rest of the file"
re-derived: see below
test_boundary.py
27 passed, 1 failed
28 passed
the surface scan kept names whose __module__ was the literal "output_boundary", so after the carve every class fell out of the census
the guard's home is read off output_boundary.__name__
test_doxbench_mcp.py
23 passed, 1 failed
24 passed
the child was started as -m ideation_dashboard.doxbench_mcp with PYTHONPATH=scripts/
-m opendox.doxbench_mcp with PYTHONPATH=src/
test_outline_model.py
47 passed, 1 failed
47 passed
imported doc_health
the case moves to openxFactory (above)
total
201 passed, 18 failed, 66 errors
282 passed
test_provider_boundary.py, for 16.6's three reasons. None of the twelve failures was a crossing. The file's docstring now records each reason.
It read snapshot_registry.py, its second HTTP-client holder, which the carve sent to openXdox-code. It is no holder in this package now, and the claim about it is not this leg's to make.
It pinned seven per-module scan suites by filename. The carve manifest sent five to openXdox-code (test_doxbench_turns.py, test_doxbench_packet.py, test_doxbench_threads.py, test_doxbench_bridge.py and test_doxbench_mutation_boundary.py) and left two in openxFactory (test_doxbench_model.py and test_doxbench_status_exemption.py, stays_openxfactory_adapter). PRESERVED_SCANS now pins the three this checkout carries. PRESERVED_ELSEWHERE records the seven with their homes, and a case asserts that none of them is here, so the record cannot go stale.
Its sweep reached the runtime (§ 3.5).runtime/app.py spells Authorization and Bearer for the identity broker's token, which it checks on the way in. runtime/oidc.py, which verifies that token, spells Authorization in prose. Both are named as tier-two holders in place of snapshot_registry.py, and the provider tier is asserted absent from each, as it was from that module. The named list is an exemption, so it is not its own authority. Since review round 5, test_the_identity_surface_is_the_runtimes_two_modules holds it to exactly these two modules, and a third holder has to be argued on its own PR. runtime/config.py names access_token in SECRET_PARAMETER_KEYS, the credential names the runtime refuses and redacts. It gets one permit: that needle, in that module, only while that tuple still names it (read with ast), and no other provider-tier spelling there. Since review round 1, the permit covers only the tuple and the module's prose. The sweep asks _spelled_in_code, which reads every identifier, attribute name and string literal off the syntax tree outside the declaration and the documentation. A spelling there fails with its line. A case also holds the table to that one entry, not only to its size, so a second permit, or one moved to another module or needle, has to be argued on its own PR.
The boundary is still one module wide for anything that holds a provider credential. 16.6's own measurement agrees: only doxbench_provider.py reaches a model provider.
test_consumer_reach.py, re-derived over the whole package. T011 emptied STILL_REACHING by moving its only two entries.
test_the_record_is_the_whole_packages_own now derives the record on every run. It imports every module the package's files define, in one interpreter, with all four siblings blocked. It follows the exception chain, because a stand-in resolved at import time raises ConsumerReachUnavailable with the ModuleNotFoundError as its cause. The modules that fail on a sibling must be exactly the record. Before this, a module outside NEUTRAL_MODULES, which names nine, could start needing openxdox at import time and pass the whole file. At this head none fails.
Every other failure is classified, not dropped. The one read past is a module of opendox.runtime missing a package of the runtime extra, where the extra is not installed. In a .[test]-only venv, that is app, db and oidc, on fastapi, psycopg and httpx. Anything else fails the test by name: a syntax error, a broken module of openDox's own, an undeclared dependency, or a runtime package needed outside opendox.runtime. RUNTIME_EXTRA tables the extra's distributions with their import names, and test_the_runtime_extra_is_the_one_pyproject_declares holds its keys to pyproject.toml's runtime list. test_the_runtime_extras_modules_are_the_runtimes_own holds the import names to two independent authorities, the runtime's own imports and the installed metadata. Each tabled name is one that a module of opendox.runtime imports. Every third-party package the runtime imports is tabled, or comes from one of the package's required dependencies. Where a tabled distribution is installed, each of its names is installed by it or by a distribution it requires.
CONVERTED_SITES had fallen behind the tree by five names in two files: branch_session.py's gate_console, the module whose nine default-argument reads the guard is named for, and cli.py's corpus_root_refusal, generate_snapshot, is_rfc3339_datetime and SCANNED_ROOTS. They join the table. test_every_name_bound_to_the_seam_is_guarded holds the table equal to the names each module binds to the seam. None of the five is read at import time. The census reads every spelling of the seam:
Y = <seam>.X, its annotated form, and Y = <seam>.module(...);
<seam> spelled as an alias of the module, as opendox.consumer_reach after import opendox or import opendox.consumer_reach, or through from .. import consumer_reach in a subpackage;
each of these wherever the module runs it at import time, a module-level if or try included.
A wildcard import from the seam fails with its own message.
Thirty-seven mutations, each a copy of this tree with one planted change, and each fails the assertion it targets. One more runs in the .[runtime,test] venv. The first thirteen:
an unlisted module gains a module-level from openxdox import …;
an unlisted module resolves a stand-in at import time, which is caught through the exception chain;
a new name is bound to the seam;
branch_session.py reads gate_console at import time;
a provider endpoint appears in a non-provider module;
a Bearer header appears in an unnamed module;
the identity surface gains MintedToken;
SECRET_PARAMETER_KEYS stops naming access_token;
the redaction module gains client_secret;
a carved-away scan suite comes back;
the guard gains a public class the shim does not re-export;
the pre-template sentence goes back to "staged topic";
the abstract-pane harness loses its contributed column.
The twelve added in review round 1:
an import-time import doc_health where a doc_health is installed;
a module importing a missing module of openDox's own;
a module that raises while importing;
an undeclared dependency;
import fastapi outside opendox.runtime;
a runtime module importing a package the extra does not declare;
a distribution added to pyproject's runtime extra and not tabled;
Y: T = consumer_reach.X;
Y = consumer_reach.module(...);
runtime/config.py spelling access_token in a dict key, in an attribute read, and in an f-string.
Eight more came from review rounds 2 and 3:
import opendox.consumer_reach then opendox.consumer_reach.module(...);
import opendox then opendox.consumer_reach.snapshot;
an alias of the seam module;
a subpackage's from .. import consumer_reach;
the seam imported inside a module-level try;
a stand-in bound inside a module-level if;
a wildcard import from the seam;
a second redaction permit.
Two came from review round 4, and one more runs in the .[runtime,test] venv:
an invented module in a RUNTIME_EXTRA row;
a runtime module importing a package nothing declares, read statically;
in .[runtime,test], a module tabled under a distribution that does not install it.
Two came from review round 5:
a third identity holder listed, with Authorization in its code;
the one redaction permit moved to another needle, with runtime/config.py spelling that name instead.
Two controls pass, as they must: a new comment and a new docstring in runtime/config.py that name access_token.
The falsifier: python -m pytest -q over the nine files
It also passes under --noconftest, file by file, and in a .[runtime,test] venv.
The repository's own check
.github/workflows/validate.yml's three report-producing steps, run as the file writes them and summed as Pin the triple sums them, in the .[test] venv above:
main at 68be484a gives 1155/1152/3. The five new cases are test_consumer_reach.py's, which the required job runs by name. test_provider_boundary.py's new cases are not on the job's list. No skip was added.
The whole suite, with the root conftest. A test-by-test JUnit diff against main in the same venv:
venv
main
this head
.[test]
19 failed, 1489 passed, 13 skipped, 66 errors
1 failed, 1570 passed, 13 skipped
.[runtime,test] (F2.1's install)
18 failed, 1490 passed, 13 skipped, 66 errors
1571 passed, 13 skipped
69 cases go from red to passed, all in the nine files.
15 are gone: the 4 moved cases, and 11 of test_provider_boundary.py's old ids. Nine were PRESERVED_SCANS rows for files this checkout does not carry, one was the renamed tier-two case, and one was the snapshot_registry.py case.
12 are new, all passing: 5 in test_consumer_reach.py and 7 in test_provider_boundary.py.
Each finding was planted at 6898748a first, and every plant passed there. Each is fixed in 86b8f522, where every plant fails, and each thread is answered with its evidence and resolved.
The derivation blocked only openxdox. With a doc_health on the path, a module gaining import doc_health dropped out of the census. The derivation, and the record entry check that reads the same failure, now block all four.
The derivation dropped every failure that named no sibling. They are classified now (above).
The access_token permit covered the whole of runtime/config.py. It covers the declaration and the prose now (above).
The review's overview also named annotated assignments in the seam census, with no thread. That is done too (above).
Review rounds 2 and 3 (Copilot, at 86b8f522 and 9d52122b), no threads
Round 2: one previously missed finding.import opendox.consumer_reach binds opendox, so a stand-in bound through opendox.consumer_reach went unseen. Three sibling forms were unseen the same way. All four are read since 9d52122, and each passed as a plant at 86b8f52.
Round 3: a summary line only, "seam-alias and wildcard-import gaps, and the single provider-boundary permit invariant." Since 9a9b21a:
the census reads a module-level if or try, where both plants passed at 9d52122;
a wildcard import fails with its own message;
the permit table is held at one entry.
At 9a9b21ae Copilot reports "Needs a closer look", with no finding and no thread.
Review round 4 (Copilot, at 7867614c, the first merge of main)
RUNTIME_EXTRA's import names were checked only through its keys. Adding "planted" to fastapi's row left the whole of test_consumer_reach.py green at 7867614, and a missing planted import in opendox.runtime would then have been read past as an absent extra. Fixed in 383b3232 by the new case above, which holds the names to the runtime's imports and to the installed metadata. The thread is answered with that evidence and resolved.
At 383b3232 Copilot reports "Needs a closer look", with no finding and no thread.
Review round 5 (Copilot, at 7e3dc9ff, the merge of T032)
IDENTITY_MODULES was its own authority.holders_seen == permitted proves only that each listed module holds a needle. Planted at 7e3dc9ff, runtime/db.py added to the tuple, with an Authorization string in its code, passed the whole file (24 passed). The thread also names line 318, the permit table's pin, which held REDACTION_PERMITS by its size only. Planted there, the permit moved to refresh_token, with runtime/config.py spelling that name in place of access_token, passed too (23 passed). Fixed in bc6b168d: each table is held to the surface it names (above), and both plants fail. The thread is answered with that evidence and resolved. All five threads on this PR are resolved.
Repair the standalone openDox test inventory and package-boundary checks after the carve so the affected suites accurately validate the new repository ownership and runtime behavior.
Bug Fixes:
Repair the nine post-carve test files so the targeted suite passes across the standalone package layout.
Correct browser harness setup, module paths, neutral display wording, boundary scans, provider-boundary exemptions, and consumer-reach census behavior.
Enhancements:
Re-derive consumer reach and seam bindings across the complete package, including runtime dependency classification and mutation-resistant coverage.
Align provider-boundary checks with the carved repository structure and explicitly track identity-surface and credential-redaction exceptions.
Move cross-repository specification-integration checks out of openDox tests for validation in openxFactory.
Tests:
Update and strengthen boundary, consumer-reach, provider-boundary, and browser composition tests for the standalone package.
Chores:
Record carved test suites and integration cases that now belong to openxFactory or openXdox-code.
Research R3's nine files, each red for a stale harness, a stale record or a
reach the carve left behind in a test, and none for a product defect:
- test_doxbench_abstract_pane, test_outline_tab, test_doxbench_composition:
the harnesses mount the shell as its host, so they contribute the
workbench gate column app.js resolves (slice S5 moved it out), imported
from test_doxbench_view's _CONTRIBUTED_GATE with the DOM shim. The outline
tab's pre-template sentence reads the SELECTION role's neutral word (S7).
- test_provider_boundary, for 16.6's three reasons: snapshot_registry.py
went to openXdox-code; the seven carved-away per-module scans are
recorded with their homes and asserted absent; the runtime's identity
surface is named for tier two, and config.py's redaction key is a permit
held to its declared reason.
- test_boundary: the census reads the guard's home off the module.
- test_doxbench_mcp: the child runs as opendox.doxbench_mcp from src/.
- test_consumer_reach: STILL_REACHING is derived over the whole package on
every run, and CONVERTED_SITES is held equal to the names the tree binds
to the seam (branch_session.py's gate_console and cli.py's four other
aliases join it).
- Moved out, as named openxFactory composition tests (R1Q2 (a)):
test_outline_model's doc_health agreement case and
test_doxbench_memory_gateway's three spec-reading cases. T007's batch E
names their paths; T047 lands them.
Arc: neutral-product-standalone-operability
Lane: openxfactory-4 (openXfactory-4-openDox_extraction)
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This PR repairs the nine post-2.1 red test files by aligning harnesses and subprocess imports with the carved openDox layout, moving openxFactory-owned integration checks out of openDox, and replacing stale hand-maintained boundary/import inventories with package-wide derived assertions and explicit carve records.
File-Level Changes
Change
Details
Files
Re-derived standalone import and seam-guard inventories across the entire package.
Enumerate every package-defined module in a consumer-blocked subprocess and compare sibling failures with STILL_REACHING.
Derive top-level names bound to the consumer-reach seam and require an exact match with CONVERTED_SITES.
Expand the consumer-reach census with corrected module-level aliases and mutation-focused safeguards.
tests/test_consumer_reach.py
Repaired package-wide provider-boundary checks for the post-carve repository layout.
Replace stale snapshot and missing per-module scan assumptions with runtime identity holders and explicit elsewhere records.
Permit and validate runtime/config.py's refusal-only access_token spelling while keeping provider-tier scans strict.
Use package-relative paths and AST inspection for subpackage modules and redaction permits.
tests/test_provider_boundary.py
Updated browser and composition test harnesses to provide the post-carve workbench gate contract.
Import the shared contributed gate column alongside the DOM shim.
Mount the contributed column so canvas and generate-control behavior is exercised under the host contract.
Read the neutral selection display term instead of the obsolete staged wording.
Fixed the MCP child-process test for the carved package and import root.
Launch opendox.doxbench_mcp with src/ on PYTHONPATH instead of the pre-carve ideation_dashboard module.
tests/test_doxbench_mcp.py
Made boundary re-export discovery independent of the package's hard-coded module name.
Derive the guard's home from output_boundary.name when identifying public definitions and reporting missing re-exports.
tests/test_boundary.py
Tips and commands
Interacting with Sourcery
Trigger a new review: Comment @sourcery-ai review on the pull request.
Continue discussions: Reply directly to Sourcery's review comments.
Generate a GitHub issue from a review comment: Ask Sourcery to create an
issue from a review comment by replying to it. You can also reply to a
review comment with @sourcery-ai issue to create an issue from it.
Generate a pull request title: Write @sourcery-ai anywhere in the pull
request title to generate a title at any time. You can also comment @sourcery-ai title on the pull request to (re-)generate the title at any time.
Generate a pull request summary: Write @sourcery-ai summary anywhere in
the pull request body to generate a PR summary at any time exactly where you
want it. You can also comment @sourcery-ai summary on the pull request to
(re-)generate the summary at any time.
Generate reviewer's guide: Comment @sourcery-ai guide on the pull
request to (re-)generate the reviewer's guide at any time.
Resolve all Sourcery comments: Comment @sourcery-ai resolve on the
pull request to resolve all Sourcery comments. Useful if you've already
addressed all the comments and don't want to see them anymore.
Dismiss all Sourcery reviews: Comment @sourcery-ai dismiss on the pull
request to dismiss all existing Sourcery reviews. Especially useful if you
want to start fresh with a new review - don't forget to comment @sourcery-ai review to trigger a new review!
… and hold the access_token permit to its declaration (plan 034 T034)
Four review findings on the repair, each planted at 6898748 first, where
all eleven plants passed, and each failing now.
The record's derivation blocked only openxdox. With a doc_health on the
path, a module gaining `import doc_health` imported, and dropped out of the
census. The derivation, and the record entry check that reads the same
failure, now block all four SIBLINGS.
The derivation dropped every failure that named no sibling: a missing
module of openDox's own, a module that raises while importing, an
undeclared dependency. Each is now a failure of the test, by name. It reads
past one failure only: a module of opendox.runtime that cannot find a
package of the runtime extra, where that package is not installed. That is
what validate.yml's .[test] install meets, for app, db and oidc.
RUNTIME_EXTRA tables the extra's distributions with the modules each puts
on the path. A new case holds its keys to pyproject.toml's own list (PEP
503 names), so the one exemption cannot drift from what the package
declares.
The access_token permit covered the whole of runtime/config.py. It now
covers the SECRET_PARAMETER_KEYS declaration and the module's prose. A
spelling in code anywhere else fails the sweep with its line: a dict key,
an attribute read, or an f-string. A comment or a docstring does not (two
controls).
The seam census now also reads `Y: T = consumer_reach.X` and
`Y = consumer_reach.module(...)`. The tree binds neither today, so the
table is unchanged.
Falsifiers: the nine files, 279 passed; validate.yml's triple
1147/1144/3, PASS; the whole suite under .[test], 1 failed (T036's
test_imports_standalone, as before) / 1526 passed / 13 skipped, with one
new passing case and no other change; 25 of 25 mutations bite.
Arc: neutral-product-standalone-operability
Lane: openxfactory-4 (openXfactory-4-openDox_extraction)
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Track bare package imports in the seam binding census
tests/test_consumer_reach.py:952
The binding census only recognizes import opendox.consumer_reach as alias; a normal import opendox.consumer_reach binds the name opendox, so a later top-level assignment such as X = opendox.consumer_reach.module(...) is not included in derived. A future module can therefore introduce an import-time seam binding in a valid Python form while test_every_name_bound_to_the_seam_is_guarded still passes. Track the bare-import package alias and its nested consumer_reach attribute (and add a mutation for this form).
Review round 2 named a form the census missed, as a previously missed
finding with no thread. `import opendox.consumer_reach` binds `opendox`,
so `X = opendox.consumer_reach.module(...)` bound a stand-in that
`test_every_name_bound_to_the_seam_is_guarded` never saw. Three more forms
were missed the same way: `import opendox`, then
`opendox.consumer_reach.snapshot`; an alias of the seam module
(`cr = consumer_reach`); and a subpackage's `from .. import
consumer_reach`, because the relative level was fixed at one. Each of the
four, planted at 86b8f52, passed. Each fails now.
The census now tracks the names bound to the `opendox` package, reads
`opendox.consumer_reach` as the seam, follows an assignment of the seam
module in statement order, and reads the relative level from the file's
depth under the package. The tree binds none of these forms today, so the
table is unchanged.
Falsifiers: the nine files, 279 passed; the triple 1147/1144/3, PASS;
29 of 29 mutations bite, and both prose controls still pass.
Arc: neutral-product-standalone-operability
Lane: openxfactory-4 (openXfactory-4-openDox_extraction)
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
… and hold the permit to one (plan 034 T034)
Review round 3 left three hints, with no thread and no finding.
The census read only a module's top-level statements. So an import of
the seam inside a module-level `try`, and a stand-in bound inside a
module-level `if`, went unread, and both run at import time. Planted at
9d52122, both passed. It now walks every statement the module runs at
import time, through if/try/with/for/while/match and their handlers,
but not a function's or a class's body.
A wildcard import from the seam binds stand-ins the guard cannot read
name by name. It already failed the census as a mismatch, with a message
that invited adding "*" to the table. It now fails with its own message.
`REDACTION_PERMITS` is ONE spelling in ONE module, as its comment says.
A new case holds the count at one, so a second permit has to be argued
on its own PR.
Falsifiers: the nine files, 280 passed; the triple 1147/1144/3, PASS
(test_provider_boundary.py is not on validate.yml's list); 33 of 33
mutations bite, and both prose controls still pass.
Arc: neutral-product-standalone-operability
Lane: openxfactory-4 (openXfactory-4-openDox_extraction)
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
T022 has landed, so this takes main at 255514d and re-verifies the nine
files, the triple and the whole suite over it. T034 stays after T032
(#49), and takes main again once T032 lands.
Arc: neutral-product-standalone-operability
Lane: openxfactory-4 (openXfactory-4-openDox_extraction)
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
… to the installed metadata (plan 034 T034)
Review round 4's thread. The pyproject check held RUNTIME_EXTRA's
distributions, but not the module names the exemption reads. So adding
"planted" to a row exempted a missing `planted` import from
opendox.runtime. Planted at 7867614, the whole file stayed green. It
fails now.
A new case, `test_the_runtime_extras_modules_are_the_runtimes_own`,
holds the names three ways:
1. each tabled name is imported by a module of opendox.runtime, read with
tests/import_scan.py's shared scanner, so an invented entry fails;
2. every third-party package opendox.runtime imports is tabled, or comes
from one of the package's required dependencies (read from its
installed metadata), so an undeclared dependency fails too, wherever
it sits in the import order;
3. where a tabled distribution is installed, each of its names is
installed by it or by a distribution it requires, per the metadata.
In `.[runtime,test]` that places pydantic under fastapi and
psycopg_pool under psycopg. Moving pydantic to httpx's row fails
there.
Falsifiers: the nine files, 281 passed in both venvs; the triple
1159/1156/3, PASS; 35 of 35 mutations bite, plus the runtime-venv one;
both prose controls pass.
Arc: neutral-product-standalone-operability
Lane: openxfactory-4 (openXfactory-4-openDox_extraction)
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
T038 landed after T022, so this takes main at 796838e and re-verifies
the nine files, the triple and the whole suite over it, in both venvs.
T034 stays after T032 (#49), and takes main again once T032 lands.
Arc: neutral-product-standalone-operability
Lane: openxfactory-4 (openXfactory-4-openDox_extraction)
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
T032 has landed, so T034's After is met. This takes main at 68be484,
which adds only the sweep and its reader, and re-verifies the nine
files, the triple and the whole suite over it, in both venvs. The sweep
itself passes on this tree, and its import inventory is the one the
re-derived censuses hold.
Arc: neutral-product-standalone-operability
Lane: openxfactory-4 (openXfactory-4-openDox_extraction)
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
…y name (plan 034 T034)
Review round 5's thread, at the merged head. `IDENTITY_MODULES` was its
own authority: `holders_seen == permitted` proves only that each listed
module holds a needle. Planted at 7e3dc9f, `runtime/db.py` added to the
tuple, with an `Authorization` string in its code, passed the whole of
`tests/test_provider_boundary.py` (24 passed).
`test_the_identity_surface_is_the_runtimes_two_modules` holds the tuple
to the runtime's identity surface, `runtime/app.py`, which takes the
caller's bearer token, and `runtime/oidc.py`, which verifies it. A third
holder has to be argued on its own pull request.
The same thread names the permit table's pin. It held
`REDACTION_PERMITS` to one entry by its size only. Planted at 7e3dc9f,
the permit moved to `refresh_token`, with `runtime/config.py` spelling
that name in place of `access_token`, passed too (23 passed). The case
now holds the table to its one entry.
Falsifiers: the nine files give 282 passed in both venvs; the triple is
1160/1157/3; both plants fail now; 37 of 37 mutations bite, plus the
runtime-venv one, and both prose controls pass.
Arc: neutral-product-standalone-operability
Lane: openxfactory-4 (openXfactory-4-openDox_extraction)
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
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
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.
Plan 034, task T034, slice P1-F (the sweep and the nine-file repair). The plan is
specs/034-opendox-standalone-operation/tasks.mdat opensoft/openxFactorymain468863d1, where round 2 (#1176) has landed. The T034 entry there is byte-identical to0d48231b's, which this record was first written against. This PR realizes box 9.1 (part) and 16.6 (the phase-1 repair) of the ratifiedadd-neutral-product-standalone-operability.5817152735. Eight of the nine files are carvedmoved_with_declared_editrows, andtests/test_consumer_reach.pyhas no row. None needs a declared-edit act.5852380744.68be484a, after T022 (T022: 4.1a, openDox's own default adapter over LocalGitCorpus #45 →255514df) and T038 (10.1: [project.scripts] opendox = "opendox.cli:main" (plan 034 T038) #48 →796838e8).mainat68be484ais merged in (7e3dc9ff, no force-push). Everything below was re-run at this head,bc6b168d. The inventory the sweep fixes is the one the re-derived record holds. At68be484athe sweep finds no reach at import time, andSTILL_REACHING, which the record now derives on every run, is empty. The sweep's 19 deferred reaches sit inbranch_session,cli,serve,serve_projectandserve_workbench, the five modules openXdox-code's ratchet counts. The sweep's own file passes on this tree (35 passed).For T007's batch E and T047: what this PR moves to openxFactory
Four test cases leave openDox-code and become NAMED openxFactory composition tests (R1Q2 (a)). T007's batch E adds each destination path to F11.1's named set (
COMPOSITION_TESTS) before T047 lands. T047's openxFactory PR lands the cases there, and T049 checks that they arrived.tests/test_session_harness.pyis not moved here. It is incollect_ignore, and it is T035's.The holder's decision on the three memory-gateway cases: accepted under R1Q2 (a) (relayed to this lane's writer, 2026-09-27). T034's text names only the outline case. The memory-gateway cases take the same route because the spec they read exists only in openxFactory.
test_the_model_and_the_doc_health_family_agree_on_the_contracttests/test_outline_model.pytests/ideation-dashboard/test_outline_template_agreement.pyviews/outline-model.js'sREQUIRED_SECTIONSandQUESTION_SUBFIELDSequal to openxFactory'sdoc_health.families(_TEMPLATE_SECTIONS,_QUESTION_SUBFIELDS). It importsdoc_health, which openDox can never install. openDox has no checker of its own until Group 6 (release 2), so there is no openDox contract to rewrite it against.test_the_roster_is_exactly_the_promoted_capabilitys_requirementstests/test_doxbench_memory_gateway.pytests/ideation-dashboard/test_memory_gateway_roster.pyopenspec/specs/memory-gateway/spec.md, the promoted capability thatdoxbench_memory_gateway.CAPABILITY_REQUIREMENTSis transcribed from. That spec is openxFactory's, and no openDox repository carries a copy (checked in openDox-spec, openDox, openXdox-spec, openXdox and openXdox-code). It failed onFileNotFoundError.test_the_tier_column_is_TRANSCRIBED_not_inventedtest_the_untiered_requirement_really_is_absent_from_the_tier_blockBoth destinations compose openDox at openxFactory's pin, which
scripts/carved_reach.pyalready puts on the path fortests/ideation-dashboard/. The outline case then readsopenDox/code/src/opendox/web/views/outline-model.jsfrom the pin, and the memory-gateway cases importopendox.doxbench_memory_gateway. The paths are proposals. If T047's writer chooses others, batch E records what T047 lands. The cases' own text, verbatim frommain19370adc, is below, so no archaeology is needed.The outline-template agreement case (from
tests/test_outline_model.py)MODEL_JSwasREPO_ROOT / "src/opendox/web/views/outline-model.js". At openxFactory it is the pinned leg's copy of that file.The three memory-gateway roster cases (from
tests/test_doxbench_memory_gateway.py)mgisopendox.doxbench_memory_gateway, and the helper needsimport re. At openxFactory,REPO_ROOTis openxFactory's own root, where the spec is (22 requirements at0d48231b, andCAPABILITY_REQUIREMENTSholds 22).The nine files (research R3), at
main68be484aand at this headWith the root conftest in play, Python 3.12.3,
-c constraints-cpython312-linux.txt -e ".[test]". The nine files give the same results onmainat68be484aas at19370adc:maintest_doxbench_abstract_pane.pyapp.jsresolves. It imports_CONTRIBUTED_GATEfromtest_doxbench_view.py, whose S7 note gives the reason, the way it already imports the DOM shim. The column answerscreateGateLiveoff the samecaps, so the ungated and hosted mounts still have no gate.test_outline_tab.pyNEUTRAL_DISPLAY. It spelled openxFactory's "staged" before S7 parameterized it.test_doxbench_composition.pytest_provider_boundary.pytest_doxbench_memory_gateway.pyopenspec/specs/memory-gateway/spec.mdtest_consumer_reach.pytest_boundary.py__module__was the literal"output_boundary", so after the carve every class fell out of the censusoutput_boundary.__name__test_doxbench_mcp.py-m ideation_dashboard.doxbench_mcpwithPYTHONPATH=scripts/-m opendox.doxbench_mcpwithPYTHONPATH=src/test_outline_model.pydoc_healthtest_provider_boundary.py, for 16.6's three reasons. None of the twelve failures was a crossing. The file's docstring now records each reason.snapshot_registry.py, its second HTTP-client holder, which the carve sent to openXdox-code. It is no holder in this package now, and the claim about it is not this leg's to make.test_doxbench_turns.py,test_doxbench_packet.py,test_doxbench_threads.py,test_doxbench_bridge.pyandtest_doxbench_mutation_boundary.py) and left two in openxFactory (test_doxbench_model.pyandtest_doxbench_status_exemption.py,stays_openxfactory_adapter).PRESERVED_SCANSnow pins the three this checkout carries.PRESERVED_ELSEWHERErecords the seven with their homes, and a case asserts that none of them is here, so the record cannot go stale.runtime/app.pyspellsAuthorizationandBearerfor the identity broker's token, which it checks on the way in.runtime/oidc.py, which verifies that token, spellsAuthorizationin prose. Both are named as tier-two holders in place ofsnapshot_registry.py, and the provider tier is asserted absent from each, as it was from that module. The named list is an exemption, so it is not its own authority. Since review round 5,test_the_identity_surface_is_the_runtimes_two_modulesholds it to exactly these two modules, and a third holder has to be argued on its own PR.runtime/config.pynamesaccess_tokeninSECRET_PARAMETER_KEYS, the credential names the runtime refuses and redacts. It gets one permit: that needle, in that module, only while that tuple still names it (read withast), and no other provider-tier spelling there. Since review round 1, the permit covers only the tuple and the module's prose. The sweep asks_spelled_in_code, which reads every identifier, attribute name and string literal off the syntax tree outside the declaration and the documentation. A spelling there fails with its line. A case also holds the table to that one entry, not only to its size, so a second permit, or one moved to another module or needle, has to be argued on its own PR.The boundary is still one module wide for anything that holds a provider credential. 16.6's own measurement agrees: only
doxbench_provider.pyreaches a model provider.test_consumer_reach.py, re-derived over the whole package. T011 emptiedSTILL_REACHINGby moving its only two entries.test_the_record_is_the_whole_packages_ownnow derives the record on every run. It imports every module the package's files define, in one interpreter, with all four siblings blocked. It follows the exception chain, because a stand-in resolved at import time raisesConsumerReachUnavailablewith theModuleNotFoundErroras its cause. The modules that fail on a sibling must be exactly the record. Before this, a module outsideNEUTRAL_MODULES, which names nine, could start needingopenxdoxat import time and pass the whole file. At this head none fails.Every other failure is classified, not dropped. The one read past is a module of
opendox.runtimemissing a package of the runtime extra, where the extra is not installed. In a.[test]-only venv, that isapp,dbandoidc, onfastapi,psycopgandhttpx. Anything else fails the test by name: a syntax error, a broken module of openDox's own, an undeclared dependency, or a runtime package needed outsideopendox.runtime.RUNTIME_EXTRAtables the extra's distributions with their import names, andtest_the_runtime_extra_is_the_one_pyproject_declaresholds its keys topyproject.toml'sruntimelist.test_the_runtime_extras_modules_are_the_runtimes_ownholds the import names to two independent authorities, the runtime's own imports and the installed metadata. Each tabled name is one that a module ofopendox.runtimeimports. Every third-party package the runtime imports is tabled, or comes from one of the package's required dependencies. Where a tabled distribution is installed, each of its names is installed by it or by a distribution it requires.CONVERTED_SITEShad fallen behind the tree by five names in two files:branch_session.py'sgate_console, the module whose nine default-argument reads the guard is named for, andcli.py'scorpus_root_refusal,generate_snapshot,is_rfc3339_datetimeandSCANNED_ROOTS. They join the table.test_every_name_bound_to_the_seam_is_guardedholds the table equal to the names each module binds to the seam. None of the five is read at import time. The census reads every spelling of the seam:Y = <seam>.X, its annotated form, andY = <seam>.module(...);<seam>spelled as an alias of the module, asopendox.consumer_reachafterimport opendoxorimport opendox.consumer_reach, or throughfrom .. import consumer_reachin a subpackage;ifortryincluded.A wildcard import from the seam fails with its own message.
Thirty-seven mutations, each a copy of this tree with one planted change, and each fails the assertion it targets. One more runs in the
.[runtime,test]venv. The first thirteen:from openxdox import …;branch_session.pyreadsgate_consoleat import time;Bearerheader appears in an unnamed module;MintedToken;SECRET_PARAMETER_KEYSstops namingaccess_token;client_secret;The twelve added in review round 1:
import doc_healthwhere adoc_healthis installed;import fastapioutsideopendox.runtime;Y: T = consumer_reach.X;Y = consumer_reach.module(...);runtime/config.pyspellingaccess_tokenin a dict key, in an attribute read, and in an f-string.Eight more came from review rounds 2 and 3:
import opendox.consumer_reachthenopendox.consumer_reach.module(...);import opendoxthenopendox.consumer_reach.snapshot;from .. import consumer_reach;try;if;Two came from review round 4, and one more runs in the
.[runtime,test]venv:RUNTIME_EXTRArow;.[runtime,test], a module tabled under a distribution that does not install it.Two came from review round 5:
Authorizationin its code;runtime/config.pyspelling that name instead.Two controls pass, as they must: a new comment and a new docstring in
runtime/config.pythat nameaccess_token.The falsifier:
python -m pytest -qover the nine filesIt also passes under
--noconftest, file by file, and in a.[runtime,test]venv.The repository's own check
.github/workflows/validate.yml's three report-producing steps, run as the file writes them and summed asPin the triplesums them, in the.[test]venv above:mainat68be484agives1155/1152/3. The five new cases aretest_consumer_reach.py's, which the required job runs by name.test_provider_boundary.py's new cases are not on the job's list. No skip was added.The whole suite, with the root conftest. A test-by-test JUnit diff against
mainin the same venv:main.[test].[runtime,test](F2.1's install)test_provider_boundary.py's old ids. Nine werePRESERVED_SCANSrows for files this checkout does not carry, one was the renamed tier-two case, and one was thesnapshot_registry.pycase.test_consumer_reach.pyand 7 intest_provider_boundary.py..[test]venv's one failure is T030'stest_every_module_imports_with_no_sibling, which needs theruntimeextra there, as Remove serve.py's two import-time reaches into openxFactory (plan 034 T011, with T030) #46 recorded. T036 gives thetestextra those packages.Review round 1 (Copilot, at
6898748a)Each finding was planted at
6898748afirst, and every plant passed there. Each is fixed in86b8f522, where every plant fails, and each thread is answered with its evidence and resolved.openxdox. With adoc_healthon the path, a module gainingimport doc_healthdropped out of the census. The derivation, and the record entry check that reads the same failure, now block all four.access_tokenpermit covered the whole ofruntime/config.py. It covers the declaration and the prose now (above).Review rounds 2 and 3 (Copilot, at
86b8f522and9d52122b), no threadsimport opendox.consumer_reachbindsopendox, so a stand-in bound throughopendox.consumer_reachwent unseen. Three sibling forms were unseen the same way. All four are read since9d52122, and each passed as a plant at86b8f52.9a9b21a:ifortry, where both plants passed at9d52122;9a9b21aeCopilot reports "Needs a closer look", with no finding and no thread.Review round 4 (Copilot, at
7867614c, the first merge ofmain)RUNTIME_EXTRA's import names were checked only through its keys. Adding"planted"to fastapi's row left the whole oftest_consumer_reach.pygreen at7867614, and a missingplantedimport inopendox.runtimewould then have been read past as an absent extra. Fixed in383b3232by the new case above, which holds the names to the runtime's imports and to the installed metadata. The thread is answered with that evidence and resolved.383b3232Copilot reports "Needs a closer look", with no finding and no thread.Review round 5 (Copilot, at
7e3dc9ff, the merge of T032)IDENTITY_MODULESwas its own authority.holders_seen == permittedproves only that each listed module holds a needle. Planted at7e3dc9ff,runtime/db.pyadded to the tuple, with anAuthorizationstring in its code, passed the whole file (24 passed). The thread also names line 318, the permit table's pin, which heldREDACTION_PERMITSby its size only. Planted there, the permit moved torefresh_token, withruntime/config.pyspelling that name in place ofaccess_token, passed too (23 passed). Fixed inbc6b168d: each table is held to the surface it names (above), and both plants fail. The thread is answered with that evidence and resolved. All five threads on this PR are resolved.Landing
main68be484ais merged in. Everything above was re-run at this head.tests/test_consumer_reach.pyhas one writer at a time (T011 → T034), and this is its second.Arc: neutral-product-standalone-operability
Lane: openxfactory-4 (openXfactory-4-openDox_extraction)
🤖 Generated with Claude Code
Summary by Sourcery
Repair the standalone openDox test inventory and package-boundary checks after the carve so the affected suites accurately validate the new repository ownership and runtime behavior.
Bug Fixes:
Enhancements:
Tests:
Chores: