Repository navigation
§ 3.4 RULED Q7: a contributed binding's CSS leaves styles.css for the binding's own sheet - #27
Conversation
… binding's own sheet RULED Q7 (Brett Heap, 2026-09-12, `opensoft/openXfactory#656` comment `5648049748`): *"a contributed binding's CSS lives WITH THE BINDING, in its own sheet; openDox's declared design tokens (the `--st-*` family, S7) are the one stable styling surface; nothing else in `styles.css` is."* Slice S5 recorded the extraction as owed and blocked (`openxdox.view_extensions.STYLE_RESIDUE`); the S7 LANDED note (`5688498049`) register item 1 records it still owed. This is openDox's half. THE SEAM. `ViewBinding` gains an optional `styles` slot — one bundle-relative `./….css` specifier, validated by `_SHEET`, which is `_MODULE`'s grammar with `.css` and a second pattern rather than one widened to `(js|css)`: a `<link>` fetches without `type="module"`'s CORS rules, so the seam that admits a sheet cannot be the one that admits a script. `as_manifest_entry()` carries it, so `/capabilities` publishes it with no new route. `views/view_extension.js` validates the same field with the same refusal (§ 4.1's "one vocabulary, both halves") and `resolveBinding` injects ONE `<link rel="stylesheet">` into `document.head` — never `document.body`, RULED Q8 — deduped by resolved href, before the module import so the sheet and the module fetch together. A sheet that fails to load is a NAMED console refusal and the panel mounts unstyled: a binding's contract is its manifest entry, not its appearance. WHAT LEFT `styles.css`, MEASURED. 59 rule blocks, 98 lines, plus one line changed in place — every selector whose every class is named by openXdox's six contributed modules and by no file of openDox's own bundle. The census is re-derived by `measure-css-census.py` (persisted with this act) at openDox-code `0b4e8bbf` / openXdox-code `0a0265f7`: 54 gate-exclusive classes, 22 shared. `STYLE_RESIDUE`'s `51 / 24` reproduces EXACTLY at `cb343ae8` under the same tool's literal-only scan — and the 51 was three short, because `.dispose-accepted`, `.dispose-rejected` and `.dispose-deferred` are built by `"disposebtn dispose-" + v.outcome` (`dispose.js`:275) and no literal search can see them. The two MIXED rules — the only two in the file naming a gate class beside an openDox one — are handled and not exempted: `:176`'s selector list is SPLIT (openDox keeps `.filterpop[hidden]`), and `:2535` `.swb-draftchrome .swb-cactions` moves whole, carrying the one openDox class a contributed sheet names as host context. WHAT STAYED. Every `--st-*` token in all four theme blocks, every shared selector, and the six orphaned `.intentchip*` rules — `intent-binding.js` delegates to the absent `views/intent-feed.js` (RULED OQ-F `not_moved`), so they are the intent-feed residue and not this act's. THE PROOF. `tests/test_binding_stylesheets.py`, `--noconftest` safe and on `validate.yml`'s explicit list as the last entry: the slot refused at both halves of the seam, the absent case carried, the injector driven under `node` against the real registry (one link for two bindings naming one sheet, none for a binding declaring none, `head` and never `body`, the failed-sheet warning), and the extraction itself measured against the file — no gate-exclusive selector survives in `styles.css`, the tokens and the shared selectors do, and where an assembly has placed the six modules the declared set is RE-DERIVED from them rather than trusted. `tests/fixtures/web_boundary_census.yaml` re-derived by `measure-census.py` (`styles.css` 2595 -> 2497, `views/view_extension.js` 877 -> 956). `validate.yml`'s exact invocation at this commit: 706 passed, 2 skipped (the two that need an assembled bundle). WHAT THIS DOES NOT DO. It ships no sheet: the four sheets land at openXdox-code with the bindings that own them (RULED Q5's package data), and the six `ViewBinding` specs name them there. It touches neither `app.js` nor `index.html`. The declared-edit window for the 89 carve-commit lines this act removes from `styles.css` is openxFactory's row annotation, which lands FIRST (RULED Q-L1, `#656` comment `5628560136`). Lane: openxfactory-4 Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Reviewer's GuideThis PR completes openDox’s Q7 half by adding a manifest-carried, binding-owned stylesheet slot with symmetric server/client validation, injecting deduplicated links into document.head before module loading, and extracting contributed-only CSS from styles.css with census-based regression tests. It does not ship the contributed sheets or advance the downstream pin, so those landing steps remain necessary. Sequence diagram for binding stylesheet resolutionsequenceDiagram
participant Resolver as resolveBinding
participant Injector as injectBindingStyles
participant Head as document.head
participant Module as BindingModule
participant Console as Console
Resolver->>Injector: injectBindingStyles(binding, bundleRoot, document)
Injector->>Injector: new URL(binding.styles, bundleRoot)
alt New resolved href
Injector->>Head: appendChild(link rel=stylesheet)
else Href already injected
Injector-->>Resolver: return null
end
Resolver->>Module: import(binding.module)
Head-->>Console: console.warn on link.onerror
Note over Console: Panel mounts unstyled after stylesheet failure
File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
…eaving an undocumented option key SELF-REVIEW BEFORE THE FIRST COPILOT ROUND. `resolveBinding` grew a third option — `options.document`, the document the stylesheet `<link>` is injected into — and nothing in the module said so. An option key a caller can only learn by reading the one call site is the same defect `requires` was before RULED Q4: a declaration the seam does not publish. It is declared now, with the precedent that makes it the right shape rather than a convenience: `regionHost(binding, doc)` one function over already takes an explicit document, for the reason this needs one — a test drives several documents through one process and the global is the wrong one in all but the first. Omitted, the injector reads the global `document`; where there is none (node, a worker) it does nothing and the binding still resolves. AND THE ORDER THAT MATTERS MORE THAN THE ONE ALREADY NOTED IS NAMED: the injection runs AFTER RULED Q4's verdict, so a binding whose requirement is unmet answers `null` several lines up and never reaches it — a panel that does not mount does not put its sheet in the document either. `tests/fixtures/web_boundary_census.yaml` re-derived by `measure-census.py` for the twelve comment lines (`views/view_extension.js` 956 -> 968). `validate.yml`'s exact invocation at this commit: 706 passed, 2 skipped. Lane: openxfactory-4 Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
…t moves SELF-REVIEW, second finding. `tests/fixtures/web_boundary_census.yaml`'s `note:` fields are a running narrative of WHY each `loc:` is what it is — the `views/view_extension.js` row narrates nine steps by hand — and this act moved two of them (`styles.css` 2595 -> 2497, `views/view_extension.js` 877 -> 968) while narrating neither. A census whose numbers move and whose prose does not is the same defect as a runbook table nothing re-derives. Both rows now carry this act's steps: the 59 rule blocks that left `styles.css` and the one selector list split in place, and the `styles` grammar, the `viewBinding()` refusal and `injectBindingStyles` at the registry, plus the self-review round that declared `options.document`. AND THE GAP THIS ACT DOES NOT ABSORB IS NAMED RATHER THAN QUIETLY CLOSED: the `views/view_extension.js` narrative already ran behind its own `loc:` before RULED Q7 touched the file — `loc: 877` at `0b4e8bbf` with the prose ending at 850 — so the 850 -> 877 steps belong to an earlier slice, and the note now says so instead of letting this act's sentence imply it covered them. `validate.yml`'s exact invocation at this commit: 706 passed, 2 skipped. Lane: openxfactory-4 Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
There was a problem hiding this comment.
🟡 Changes recommended
Four moderate findings and one provenance nit remain unresolved.
Get a fresh assessment by requesting another Copilot review.
Pull request overview
Moves contributed binding CSS from shared styles.css into declarative, binding-owned stylesheets.
Changes:
- Adds stylesheet validation and capabilities-manifest propagation.
- Injects deduplicated stylesheet links into
document.head. - Removes contributed selectors and updates tests, census data, and CI.
File summaries
| File | Summary |
|---|---|
tests/test_binding_stylesheets.py |
Adds coverage. Moderate (2 votes): misses inline custom-property declarations. Moderate (1 vote): relies on a hard-coded exclusive-class set. |
tests/fixtures/web_boundary_census.yaml |
Updates measurements. Nit (1 vote): add Q7 and stylesheet-extraction provenance notes. |
src/opendox/web/views/view_extension.js |
Validates and injects stylesheets. Moderate (2 votes): accepts styles: null. Moderate (2 votes): does not forward custom documents through mounting. |
src/opendox/web/styles.css |
Removes contributed binding rules while retaining shared styles and tokens. |
src/opendox/view_extension.py |
Validates and publishes binding stylesheet declarations. |
.github/workflows/validate.yml |
Runs the new stylesheet test suite. |
Review details
Suppressed comments (2)
tests/fixtures/web_boundary_census.yaml:400
- The census numbers now include this Q7 change, but this row's provenance still ends at the S5 entry (
loc 841 -> 850) and does not record the 79-line registry addition. The fixture records later slice amendments in its header/row notes; append a Q7 measurement note (and the corresponding stylesheet-extraction note) so the declared totals remain traceable.
loc: 968
tests/test_binding_stylesheets.py:349
- This loop does not re-derive the exclusive class set from
gate_text; it only verifies that every token already present in the hard-codedGATE_EXCLUSIVEtuple appears in the contributed modules. If a future contributed module adds a new gate-only class and its rule remains instyles.css, both checks ignore it, so the extraction proof passes incorrectly. Derive the module class set (or compare it against the declared set) and assert the full derived set is absent fromstyles.css.
for token in GATE_EXCLUSIVE:
stem = token.rsplit("-", 1)[0] + "-"
named = re.search(rf"(?<![A-Za-z0-9_-]){re.escape(token)}(?![A-Za-z0-9_-])",
gate_text) or re.search(re.escape(stem) + r'"', gate_text)
- Files reviewed: 6/6 changed files
- Comments generated: 3
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
There was a problem hiding this comment.
🔵 Needs a closer look
Moderate implementation and test-coverage issues remain, along with a census annotation correction.
Review details
Suppressed comments (4)
src/opendox/web/views/view_extension.js:698
mountContributedViewssupports an explicitoptions.documentand uses it for its region hosts, but the new stylesheet path only receivesoptions.documentthroughresolveView; the generic pass callsresolveBinding(binding)without forwarding itsdoc. Consequently a custom-document/Node mount appends the link to the global document (or injects nothing) while the panel mounts in the supplied document, leaving it unstyled. Forward the pass's document when resolving bindings and cover that path.
injectBindingStyles(binding, bundleRoot,
(options && options.document) || undefined);
src/opendox/web/views/view_extension.js:205
- The Python seam rejects
styles=Noneas a non-string, but this guard treats JavaScriptstyles: nullas an absent sheet and normalizes it to"". That lets a malformed manifest pass the client even though the contract says non-string values refuse and only omission/""mean no sheet; removenullfrom the absent-value guard so it reaches the type check.
if (b.styles !== undefined && b.styles !== null && b.styles !== "") {
if (typeof b.styles !== "string" || !SHEET.test(b.styles)
|| b.styles.split("/").includes("..")) {
tests/fixtures/web_boundary_census.yaml:212
- This updated census note still names the old token vocabulary (
--st-brainstorm/--st-staged/--st-proposal/--st-realized) and the pre-extraction chip range:1278-1295. The current stylesheet declares--st-captured/--st-organized/--st-proposed/--st-completion, and the remaining.intentchip*rules are at lines 1247-1256, so the fixture's annotation contradicts the file it records; update both references.
note: "four --st-brainstorm/--st-staged/--st-proposal/--st-realized status colour tokens (16 definitions); :1278-1295 styles intent-feed's chips. loc 2595 -> 2497 on RULED Q7 (openxFactory#656 comment 5648049748): 59 rule blocks — every selector whose every class is named by openXdox's six contributed modules and by no file of this bundle — LEFT for the four sheets openXdox-code ships beside the bindings that own them, and one selector list was SPLIT in place so this file keeps `.filterpop[hidden]`. Every `--st-*` token in all four theme blocks and all 22 shared selectors STAY: they are openDox's"
tests/test_binding_stylesheets.py:334
- This does not actually re-derive the contributed class set: when the six modules are present it checks only that each hard-coded
GATE_EXCLUSIVEtoken appears somewhere in them. A newly added gate-only class omitted from this tuple would not be checked, and in this code-leg checkout_assembled_views()skips the test entirely, so the CSS extraction can leave such a selector behind while the suite still passes. Derive the set from the six modules (including the dynamicdispose-form) and compare it with the declared set, or use that derived set for the leftover assertion.
def test_the_gate_exclusive_set_is_re_derived_where_the_modules_are_present() -> None:
"""Where an assembly has placed the six modules, the declared set above is
CHECKED against them rather than trusted: every class in `GATE_EXCLUSIVE` is
named by at least one of the six, and none is named by openDox's own
bundle."""
- Files reviewed: 6/6 changed files
- Comments generated: 0 new
- Review effort level: Lite
…d make both extraction guards able to fail
FOUR FINDINGS, ALL TAKEN, EACH WITH THE MUTATION THAT PROVES THE REPAIR.
1. `styles: null` WAS ACCEPTED BY THE CLIENT AND REFUSED BY THE SERVER. The
guard read `!== undefined && !== null && !== ""`, so a malformed
`/capabilities` entry normalized to `""` here while
`ViewBinding.__post_init__` refuses `styles=None` as a non-string. That is
§ 4.1's "one vocabulary, both halves" broken for the SECOND time on this
module — `_ENTRY` was written because `str.isidentifier()` and the browser's
check meant two different things — and a second instance is not one to
leave. Omission and `""` are the two absent forms; `null` is neither and now
reaches the type check. MUTATION: restore `!== null` -> `refusals` reads
`[…, null]` and the client-half test fails.
2. THE GENERIC MOUNT PASS DID NOT CARRY ITS OWN DOCUMENT. `mountContributedViews`
chooses `doc` for its region hosts and then called `resolveBinding(binding)`,
forwarding nothing — so a caller mounting into an iframe, a probe document or
a test one got its PANEL there and its STYLESHEET in the global document, or
nowhere where there is no global: a binding mounted unstyled with nothing
refused and nothing logged. The pass now resolves with `{ document: doc }`,
and a NEW node-driven test drives the real registry in a throwaway bundle and
asserts the `<link>` lands in the SUPPLIED document's head (its `body` stub
throws, RULED Q8). MUTATION: drop the forwarding -> that test fails with an
empty link list.
3. THE `--st-*` GUARD ONLY SAW A DECLARATION AT THE START OF A LINE, and every
sheet in this bundle is written one rule per line — `.x { --st-proposed: red }`
declares the token after a `{`, a second declaration after a `;`, and the
guard saw neither. It now matches the three contexts a declaration can
follow (start, `{`, `;`) and NOT `(`, which is what a `var()` READ is bounded
by — the distinction RULED Q7 draws. A new test drives the scanner against
both shapes, because a guard that cannot fail is a comment.
4. THE EXTRACTION PROOF COULD NOT SEE A CLASS THE TUPLE NEVER HEARD OF, and in
THIS checkout it could not run at all: the re-derivation test skips where no
assembly has placed openXdox's six modules, which is every openDox-code
checkout. So the proof now has a TUPLE-FREE half that runs everywhere — the
ORPHAN REGISTER. Every class `styles.css` still declares in a selector is
named by openDox's own bundle or is one of 28 DECLARED orphans (6
`.intentchip*` whose builder is RULED OQ-F `not_moved` and never arrived,
plus rules whose builders the carve left elsewhere), counted with the
concatenation forms no literal search can see. A gate-only selector left
behind is named by neither. MUTATION: append `.refusalpanel-footer { }` — a
gate-family class `GATE_EXCLUSIVE` does not contain -> the register
assertion fails and names it. The derived-set check in the re-derivation
test is kept and strengthened the same way, for the assembly case.
5. THE CENSUS NOTE FOR `styles.css` WAS STALE IN TWO PLACES THIS ACT MADE
WRONG (round 2's finding, taken here): it named the pre-S7 token vocabulary
(`--st-brainstorm`/`--st-staged`/`--st-proposal`/`--st-realized`) and the
pre-extraction chip range `:1278-1295`. MEASURED: the tokens are
`--st-captured`/`--st-organized`/`--st-proposed`/`--st-completion`, and the
`.intentchip*` rules now sit at `:1247-1256` because the 59 blocks that left
took 31 lines out from above them. Both corrected, with the reason.
The `views/view_extension.js` provenance finding was already TAKEN at
`1cde5458`, one commit before the review that raised it.
`validate.yml`'s exact invocation at this commit: 708 passed, 2 skipped.
Lane: openxfactory-4
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
There was a problem hiding this comment.
🔵 Needs a closer look
Three moderate test-coverage issues remain unresolved.
Review details
Suppressed comments (3)
tests/test_binding_stylesheets.py:488
- Because the accepted
stylesgrammar allows nested bundle-relative paths such as./views/gate/panel.css, this direct-child glob skips valid contributed sheets underviews/subdirectories. A nested sheet could declare an--st-*token without this guard seeing it, despite the test claiming to cover every contributed stylesheet; recurse through the directory instead.
sheets = sorted(views.glob("*.css"))
tests/test_binding_stylesheets.py:374
ownis the raw concatenation of JavaScript and HTML, sonamed_by_opendox()treats comments and documentation as ownership evidence. A gate-only selector mentioned in an openDox comment can therefore be classified as named even though the bundle never emits that class, allowing this extraction check to pass with stale CSS. Strip comments before this scan (or derive the set from actual class-producing expressions) so the invariant cannot be bypassed by prose.
own = "\n".join(p.read_text(encoding="utf-8")
for p in sorted((WEB / "views").glob("*.js")))
own += (WEB / "app.js").read_text(encoding="utf-8")
tests/test_binding_stylesheets.py:409
- This assertion only checks that a small list of class tokens still appears; it does not verify each shared selector/rule claimed by the census. Removing an unlisted shared rule (or one duplicate occurrence of a listed class) leaves the test green, so the extraction could break openDox-owned styling without detection. Assert the complete shared-selector set or derive it from the same census used to classify the moved rules.
for shared in ("swb-cbtn", "swb-cfield", "swb-clabel", "swb-cslot",
"disposebtn", "dispose-intile", "cbtn", "repobtn",
"docstatus", "reason-form", "rf-label", "repopick-msg",
"dc-h", "dc-line", "dc-note", "swb-draftchrome"):
assert shared in declared, shared
- Files reviewed: 6/6 changed files
- Comments generated: 0 new
- Review effort level: Lite
…is complete, and the sheet scan recurses
THREE FINDINGS, ALL TAKEN, EACH WITH ITS MUTATION.
1. A COMMENT COUNTED AS EVIDENCE THAT openDox NAMES A CLASS. The orphan
register asks "does openDox's own bundle NAME this class", and it read the
raw concatenation of every `.js` and the `.html` — so a gate-only selector
left behind in `styles.css` could be excused by a COMMENT that mentions it
and code that never emits it, which is the one way that register could be
talked out of a finding. Comments are blanked now, by a QUOTE-AWARE walk and
not a regex: `"https://…"` carries a `//` inside a string, and blanking from
there would delete real code — a false RED for the same reason the finding
is about a false GREEN.
AND THE CORRECTION MOVED THE REGISTER, NOT THE EXTRACTION: `divider` and
`ghost` join it, because openDox names each in a comment and nowhere else.
28 -> 30, every one of them named with its reason.
MUTATION: append `.refusalpanel-footer { }` to `styles.css` AND a comment in
`views/docs.js` mentioning it — before this commit the comment excused the
rule and the suite was green; now it fails.
2. THE SHARED-SELECTOR CHECK WAS A SAMPLE OF SIXTEEN NAMES. Removing an
unlisted shared rule left it green, so an extraction that took openDox-owned
styling with it said nothing. `SHARED_CLASSES` is now the census's own
`shared` bucket in full — all 22 classes named by BOTH columns at
openDox-code `0b4e8bbf` / openXdox-code `0a0265f7`, which is exactly the set
this extraction puts at risk; a class openDox alone names was never a
candidate to leave — plus the one declared host-context class.
MUTATION: delete `.swb-cslot:empty { display: none; }` from `styles.css` ->
the assertion fails and names it.
3. THE CONTRIBUTED-SHEET SCAN MISSED A NESTED SHEET. `_SHEET` admits
`./views/gate/panel.css`, and a direct-child `glob("*.css")` would have let
a sheet in a subdirectory declare an `--st-*` token while the test claimed
to cover every contributed stylesheet. It recurses now.
`validate.yml`'s exact invocation at this commit: 708 passed, 2 skipped.
Lane: openxfactory-4
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
There was a problem hiding this comment.
🔵 Needs a closer look
The assembled CSS ownership proof must exclude comments and docstrings before deriving class ownership.
Review details
Suppressed comments (1)
Previously missed (1) — in code that hasn't changed since the last review.
tests/test_binding_stylesheets.py:519
- These corpora are read raw, so
names()treats class names that appear only in comments or docstrings as ownership evidence. The no-assembly path deliberately calls_blank_code_comments, but this assembled path does not; a gate-only selector can therefore be accepted as openDox-owned (or a contributed module can be treated as owning a class it only documents), letting the extraction proof go green without runtime ownership. Blank comments for both corpora while preserving string literals before deriving names.
- Files reviewed: 6/6 changed files
- Comments generated: 0 new
- Review effort level: Lite
… stopped counting Copilot round 3 on the paired annotation (openxFactory #1068) bounded the census's bare-class-literal rule by POSITION: a literal names a class after `(`, after `,`, after an assignment `=`, or as the value of a class-naming key, and nowhere else. `why` was in this tuple only because a gate module carried it as a value in a non-class position; it is openDox's alone. RE-DERIVED from the same run that produced the annotation's figures, not adjusted to match: 54 exclusive classes over 59 blocks and 89 lines — UNCHANGED, so not one byte of this leg moves — and 21 shared. The same re-derivation lands in `openxdox.view_extensions.STYLE_RESIDUE` and in the manifest note. `validate.yml`'s exact invocation at this commit: 708 passed, 2 skipped. Lane: openxfactory-4 Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Copilot round 3. The no-assembly path stopped counting a comment as evidence that openDox names a class one commit ago; the ASSEMBLED path — the one that runs where a bundle carries openXdox's six modules — still read both corpora raw. Either side could be talked out of a finding by prose: a gate-only selector excused by an openDox comment that mentions it, or a contributed module credited with a class it only documents. Same quote-aware walk, both corpora, for the reason the other path already gives. No figure moves. `validate.yml`'s exact invocation at this commit: 708 passed, 2 skipped. Lane: openxfactory-4 Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
There was a problem hiding this comment.
🔵 Needs a closer look
Two moderate findings remain in stylesheet ownership re-derivation tests.
Review details
Suppressed comments (2)
tests/test_binding_stylesheets.py:520
- This re-derivation feeds raw JavaScript and HTML, including comments/docstrings, into
names(). A gate-only class mentioned only in an openDox comment would therefore be classified as openDox-owned andderived_leftoverswould stay green even if its selector remained instyles.css; the earlier proof correctly uses_blank_code_comments. Blank comments here as well before matching the own-bundle corpus.
# only in a comment counted as ownership on EITHER side — a gate-only
# selector excused by openDox prose, or a contributed module credited with
# a class it only documents. Same walk, same reason.
gate_text = "\n".join(
tests/test_binding_stylesheets.py:537
- The assembled-path derivation repeats the same false-ownership problem:
names()treats any token with an openDox prefix such asswb-pane-as owned, even when only a contributed module names the concrete class. That lets a newly introduced gate-only selector under this prefix remain instyles.csswithoutderived_leftoversfinding it; derive concrete emitted values or otherwise avoid prefix-only ownership evidence.
# tuple (Copilot review, round 1). Checking only that every DECLARED token
# is named by the six answers a question nobody asked: a gate-only class
# this tuple forgot would be named by the six, left behind in `styles.css`,
# and invisible to both halves of the old assertion. The derivation is the
# census tool's own: every class token `styles.css` still declares in a
# SELECTOR, classified by which side of the seam names it, with the
# concatenation forms (`"disposebtn dispose-" + v.outcome`) counted by
- Files reviewed: 6/6 changed files
- Comments generated: 0 new
- Review effort level: Lite
…er shape is decided The shape of this field was put to Brett Heap with the measurement that raised it — openXdox's six contributed bindings need FOUR sheets, because one owns no selector of its own and two name eleven blocks between them — against the alternative of a TUPLE of specifiers with a shared sheet named beside each binding's own. **RULED openxFactory#656 comment `5700475319` (Brett Heap, 2026-09-16, by interactive multi-choice): KEEP the measured shape — a single specifier, and href de-duplication LOAD-BEARING rather than decorative.** The citation goes on the field's own note, which is where the decision is made and where a successor will read it, and a test asserts it: widening `styles` to a tuple is changing a ruled decision, not a refactor, and the reference has to move with it rather than be left behind attributing someone's own choice to a ruling. `tests/fixtures/web_boundary_census.yaml` re-derived for the note's lines. No behaviour, no selector and no declared line moves. `validate.yml`'s exact invocation at this commit: 709 passed, 2 skipped. Lane: openxfactory-4 Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
There was a problem hiding this comment.
🔵 Needs a closer look
Two moderate findings remain unresolved, along with one documentation nit.
Review details
Suppressed comments (3)
src/opendox/view_extension.py:275
_SHEET.match()uses Python's$anchor, which accepts a final newline before the end of the string, while the client-sideSHEET.test()rejects that same value. Consequentlystyles="./views/gate.css\n"can pass the Python declaration seam but fail when the manifest is read in the browser, violating the claimed one-vocabulary contract. Use a strict end anchor/full match here and add the trailing-newline case to the seam test.
_SHEET = re.compile(r"^\./[A-Za-z0-9_./-]+\.css$")
tests/fixtures/web_boundary_census.yaml:212
- The census note says there are 22 shared selectors, but
SHARED_CLASSESdefines 21 and the test explicitly describes that bucket as 21;swb-draftchromeis tracked separately as host context. Please reconcile the note with the measured bucket, since this fixture is the record used to justify which selectors stayed.
note: "four status colour tokens (16 definitions) -- `--st-captured`/`--st-organized`/`--st-proposed`/`--st-completion` since slice S7 named them BY ROLE, where this sentence had carried the pre-S7 `--st-brainstorm`/`--st-staged`/`--st-proposal`/`--st-realized` (Copilot review of the Q7 extraction, round 1); :1247-1256 styles intent-feed's chips, re-measured here because THIS act moved them -- the range read :1278-1295 and the 59 blocks that left took 31 lines out from above them. loc 2595 -> 2497 on RULED Q7 (openxFactory#656 comment 5648049748): 59 rule blocks — every selector whose every class is named by openXdox's six contributed modules and by no file of this bundle — LEFT for the four sheets openXdox-code ships beside the bindings that own them, and one selector list was SPLIT in place so this file keeps `.filterpop[hidden]`. Every `--st-*` token in all four theme blocks and all 22 shared selectors STAY: they are openDox's"
tests/test_binding_stylesheets.py:499
- This assertion only protects the 21 shared classes. If extraction accidentally removes a class that only openDox names,
declaredsimply shrinks and this check still passes; the orphan comparison also examines only the classes that remain. Add a complete retained-selector baseline or an equivalent derived assertion so deleting an openDox-owned rule is detected, since the PR claims those selectors stay instyles.css.
def test_the_design_tokens_and_the_shared_selectors_stayed() -> None:
"""The other half of the same sentence: the `--st-*` family IS openDox's."""
css = STYLES.read_text(encoding="utf-8")
for role in ("--st-captured", "--st-organized", "--st-proposed",
- Files reviewed: 6/6 changed files
- Comments generated: 0 new
- Review effort level: Lite
…t, and reconcile the census note to 21 THREE FINDINGS, ALL TAKEN, EACH WITH ITS MUTATION. 1. **PYTHON'S `$` MATCHES BEFORE A FINAL NEWLINE AND JAVASCRIPT'S DOES NOT.** `styles="./views/gate.css\n"` passed this seam and `views/view_extension.js`'s `SHEET.test()` would have refused the same value when the manifest reached the browser — § 4.1's one vocabulary broken by a regex dialect, which is the THIRD time this seam has been caught by that class of difference (`_ENTRY` was written because `str.isidentifier()` and the browser's check meant two things). `_SHEET` uses `\Z`, and the trailing-newline case is in the parametrized refusal test. **REGISTERED FOR A LATER DECLARED ACT, NOT FIXED HERE:** `_MODULE`, `_ID` and `_ENTRY` carry the same `$` and the same hole — measured, `_MODULE` admits `"./views/gate.js\n"`. Repairing a grammar this act does not introduce belongs to an act of its own; the note on `_SHEET` says so and names them. MUTATION: put `$` back -> the refusal test fails on the newline case. 2. **THE SHARED-CLASS ASSERTION COULD NOT SEE A DELETION.** It protects 21 names; a rule only openDox names could have left with the extraction and `declared` would simply SHRINK, with the orphan register — which examines only what REMAINS — equally blind. The whole retained set is pinned by count now: `styles.css` declares **572** classes in selectors, a census figure on the same footing as `web_boundary_census.yaml`'s `loc`, re-derived when openDox adds or removes a rule of its own and NOT moved by this act again. MUTATION: delete `.filteraddselect` — an openDox-only class used in one rule — and the assertion fails naming 571 against 572. 3. **THE CENSUS NOTE STILL SAID 22 SHARED** where `SHARED_CLASSES` and the test say 21. It says 21, with why (the census stopped counting a bare literal in a non-class position on round 3, and `why` was shared only because a gate module carried it as a value), and with `.swb-draftchrome` named as HOST CONTEXT rather than a member of that bucket. The 572 total is recorded there too, so the fixture states both figures the suite asserts. `validate.yml`'s exact invocation at this commit: 710 passed, 2 skipped. Lane: openxfactory-4 Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
There was a problem hiding this comment.
🔵 Needs a closer look
Fix grammar parity, allow retries after stylesheet load failures, and reject partial module assemblies.
Review details
Suppressed comments (3)
src/opendox/view_extension.py:275
- The Python grammar is not actually identical to the JavaScript
SHEETgrammar: Python's$also matches immediately before a final newline, sostyles="./views/gate.css\n"is accepted here and emitted in the manifest, while the client'sSHEET.test()rejects it. That leaves a valid server-side binding that every browser refuses; use an end-of-input anchor/full match and add a trailing-newline parity case.
#:
src/opendox/web/views/view_extension.js:658
- The URL is added to the per-document dedupe set before the stylesheet has loaded, but this handler only logs failures. After a transient 404 or network error, every later render sees the URL as already injected and skips creating a new link, so the panel remains permanently unstyled until a full page reload. Remove the failed href from
seenin this handler (or otherwise permit a retry).
link.onerror = function () {
console.warn("view binding " + JSON.stringify(binding.id) + " names styles "
tests/test_binding_stylesheets.py:295
- This helper treats a partial assembly as if there were no assembly: if even one of the six expected modules is missing, the derived ownership check is skipped. A bundle with five contributed modules can therefore pass without checking the modules it does contain, hiding a packaging/assembly error; distinguish the all-absent case from a partial set and fail the latter.
def _assembled_views() -> Path | None:
"""`views/` if an assembly has placed the contributed modules there."""
views = WEB / "views"
return views if all((views / name).is_file() for name in GATE_MODULES) else None
- Files reviewed: 6/6 changed files
- Comments generated: 0 new
- Review effort level: Lite
…etry, and a PARTIAL assembly fails instead of skipping TWO FINDINGS, BOTH TAKEN, EACH WITH ITS MUTATION. (The round's third — Python's `$` against JavaScript's — was taken at `4257f5bd`, one commit before the review was written.) 1. **A TRANSIENT 404 WAS PERMANENT.** The href joins the per-document set BEFORE the fetch resolves — it has to, or two bindings naming one sheet in the same pass would each inject a link — so a dropped connection or a momentary 404 left the href marked injected forever: every later render skipped it, and the panel stayed unstyled until a full page reload, with only the first console line to say why. `onerror` now removes the href from the set and detaches the dead `<link>`. The dedupe is about ONE SUCCESSFUL INJECTION per document, not one attempt ever, and the comment says so. MUTATION: drop the `seen.delete(href)` -> the new node-driven retry test fails (`retried` false, one link where there should be two). 2. **A PARTIAL ASSEMBLY READ AS NO ASSEMBLY.** `_assembled_views()` returned `None` unless all six contributed modules were present, so a bundle carrying FIVE skipped the derived ownership check entirely and a packaging error hid behind a pytest skip. Absent is a legitimate state — this leg ships none of the six and RULED Q5 places them at assembly — but a bundle that has SOME of them has been assembled wrongly, and `install_view_modules` refuses rather than placing a partial set, so this is a failure and not a silence. It distinguishes the two now and names the missing files. MUTATION: make a partial set return `None` again -> the new test fails. `validate.yml`'s exact invocation at this commit: 712 passed, 2 skipped. Lane: openxfactory-4 Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
There was a problem hiding this comment.
🔵 Needs a closer look
Moderate issues remain in deduplicated stylesheet error ownership and test coverage for injection-before-import ordering.
Review details
Suppressed comments (2)
src/opendox/web/views/view_extension.js:660
ViewBindingslots are unique by(region, id), not byidalone, but this deduped link keeps only the first binding'sdata-view-bindingandonerrorclosure. If two permitted bindings in different regions share this href and id, the failed-sheet warning cannot identify which binding is unstyled (and the second binding gets no warning); include the region/slot and retain all owners for a deduped href.
link.setAttribute("data-view-binding", binding.id);
link.onerror = function () {
// A FAILED SHEET IS FORGOTTEN, so the next render may try again (Copilot
// review, round 5). The href joins `seen` BEFORE the fetch resolves —
// it has to, or two bindings naming one sheet in the same pass would each
tests/test_binding_stylesheets.py:660
- This harness only checks that
mount()eventually runs and that a link exists afterward; the fixture module never observes its own evaluation. MovinginjectBindingStylesbelowawait import()would therefore keep this test green while violating the new before-import contract atview_extension.js:685-706. Have the throwaway module record/assert that the expected head link is present during module evaluation so this ordering is covered.
"""`_assembled_views()`'s own rule, driven (Copilot review, round 5)."""
views = tmp_path / "views"
views.mkdir()
monkeypatch.setattr(sys.modules[__name__], "WEB", tmp_path)
- Files reviewed: 6/6 changed files
- Comments generated: 0 new
- Review effort level: Lite
There was a problem hiding this comment.
🔵 Needs a closer look
The cross-layer change has an unresolved moderate client-side newline-validation test gap.
Review details
Suppressed comments (1)
tests/test_binding_stylesheets.py:388
- The client-side parity harness does not exercise the final-newline case even though this PR explicitly relies on Python
\Zversus the JSSHEETanchor to keep both halves aligned (the Python parameterization covers"./views/gate.css\n"at lines 350-358). If that JS validation regresses to accepting the newline, this suite will stay green; include the same input in the clientbadlist and update the expected refusal count.
for (const bad of ["/views/gate.css", "https://cdn.example/g.css",
"./views/gate.js", "./views/../x.css", 7, null]) {
- Files reviewed: 6/6 changed files
- Comments generated: 0 new
- Review effort level: Lite
…is 18 COPILOT ROUND 6 ON #27 — one finding, in the review BODY as a suppressed comment with no thread, plus the census figure this act cites moving under openxFactory #1068's round-5 repairs. TAKEN — THE NEWLINE PARITY CASE. This act rests on Python's `\Z` and JavaScript's `$` refusing `"./views/gate.css\n"` ALIKE, and § 4.1's "one vocabulary, both halves" is the whole reason `_SHEET` sits beside `_MODULE` in each. The Python half parameterizes exactly that input; the client harness did not, so a `SHEET` regex that regressed to `$` under the `m` flag would have left this suite green with the two halves disagreeing about a specifier. The input is in the client `bad` list now and the refusal count is SEVEN, not six. THE SHARED SET IS 18, NOT 21 — and the extraction is unchanged. openxFactory #1068's round 5 narrowed the census's gate-side scan again: a `.token` counts only inside a literal SHAPED like a selector with the dot in selector POSITION, and an assignment only where the target is class-named. `g` (`"e.g. Field Pilots"`, gate-projects.js), `lens` (`"gate.lens: ..."`, gate-lens.js) and `topic` (`btn.title = "commission proposal authoring for this staging topic "`, dispose.js:402) were shared only through those false reads. MEASURED at openDox-code `0b4e8bbf` / openXdox-code `0a0265f7`: 54 gate-exclusive classes, 59 exclusive blocks AT THE SAME SELECTORS AND EXTENTS, 89 lines — a class moving from SHARED to openDox's own is a class that stays either way. `SHARED_CLASSES`, its note, the retained-set comment and `tests/fixtures/web_boundary_census.yaml` all carry 18 with the three names and the reason. GATE: `validate.yml`'s exact pytest line -> 712 passed, 2 skipped. Lane: openxfactory-4 Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
There was a problem hiding this comment.
🟡 Changes recommended
Fix the JavaScript newline validation issue and the contributed-module ownership check.
Get a fresh assessment by requesting another Copilot review.
Review details
Suppressed comments (1)
tests/test_binding_stylesheets.py:510
- When an assembled bundle places the six contributed modules in
WEB/views, this glob includes them inown, so a gate-only class is treated as named by openDox and can be hidden from the orphan check. The derived check below already excludesGATE_MODULES; exclude them here too so this no-assembly proof still represents only openDox-owned files.
own = "\n".join(_blank_code_comments(p.read_text(encoding="utf-8"))
for p in sorted((WEB / "views").glob("*.js")))
- Files reviewed: 6/6 changed files
- Comments generated: 1
- Review effort level: Lite
…rpus COPILOT ROUND 7 ON #27 — the one body finding, taken. WHERE AN ASSEMBLY HAS PLACED THE SIX, `(WEB / "views").glob("*.js")` swept them into `own` — the corpus the ORPHAN half of the extraction proof calls "named by openDox". A gate-only class left behind in `styles.css` would then have read as openDox's own and the check would have hidden exactly the defect it exists to catch. The derived check below it already excluded `GATE_MODULES` for the same reason (round 3); this one now does too, so the half of the proof that runs with NO tuple and NO assembly is about openDox-owned files in both worlds. GATE: `validate.yml`'s exact pytest line -> 712 passed, 2 skipped. Lane: openxfactory-4 Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
|
There was a problem hiding this comment.
Sorry @brettheap, you've used your own review budget of 250,000 diff characters for the last 7 days.
You can request another review in 1 day and 4 hours by commenting @sourcery-ai review. Upgrade to get a review now.
…e the census totals This leg was CONFLICTING against `main` after openDox-code#24 (`0e65b5f8`, the retirement) and #27 (`5c137a90`, RULED Q7's CSS extraction) landed. ONE file conflicted — `tests/fixtures/web_boundary_census.yaml`'s per-class `totals:`, which both acts re-state. RESOLVED BY DERIVING FROM THE MERGED ROWS, never by adding the two sides' numbers. `tests/test_web_boundary.py::test_the_declared_totals_are_re_derived_ from_the_rows` sums `files:` per class and refuses a drift, so the merged rows are the only lawful source: class A 26 files 17904 | 17998 -> **18019** loc class B 1 file 73 | 73 -> 73 class C 14 files 12617 | 12466 -> **12519** loc class ? 1 file 1435 | 1435 -> 1435 At the shared base `0b4e8bbf` those were A 17883 and C 12564, and the two acts move DISJOINT ROWS, which is why the rows themselves auto-merged and only the summary conflicted. Measured row by row against that base: this leg views/docs.js A 204 -> 212 views/display.js A 679 -> 692 views/board.js C 306 -> 318 views/explorer.js C 325 -> 342 views/lineage.js C 186 -> 198 views/staging-workbench.js C 3459 -> 3471 (+21 A, +53 C) #27 views/view_extension.js A 877 -> 992 styles.css C 2595 -> 2497 (+115 A, -98 C) 17883 + 21 + 115 = 18019 and 12564 + 53 - 98 = 12519 — a CHECK on the derivation above and never its source. Every row's own `loc` was then re-measured against the merged tree with the test's own rule (`text.count("\n")`, what `wc -l` counts): ZERO mismatches over all 42 rows. `.github/workflows/validate.yml` AUTO-MERGED with both appends intact, which is the outcome this leg's own note predicted when it put `tests/test_display_facet_leaves.py` in a SEPARATE step rather than as a 28th entry on the list #27 also appends to. The note now records that as measured rather than forecast. Re-run at this merged head, exactly as the workflow invokes them: pytest -q <the 28-file list> --noconftest 712 passed, 2 skipped pytest -q tests/test_display_facet_leaves.py --noconftest 12 passed The two skips are #27's own, and deliberate: no assembly has placed openXdox's six contributed modules in this bundle (RULED Q5). The list was 694 passed before #27 added `tests/test_binding_stylesheets.py` to it. THE TREE IS NO LONGER BYTE-IDENTICAL TO `e06ae7cd`, and that is said plainly because a ruling rests on it: RULED `#656` comment `5716232555` Q1 (a) lands this pull request on the reviews already held, on the ground that head `b0e66a7f`'s tree equalled `e06ae7cd`'s — the head Copilot reviewed "Approval recommended". This merge commit adds `main`'s content to that tree — #24's two deletions and #27's four files. NOTHING OF THE LEG'S OWN WORK MOVES WITH IT: the seven leaf fixes and `tests/test_display_facet_leaves.py` are byte-identical to `b0e66a7f`, and the only hunks authored here are the census `totals:` block above and a four-line note in the `validate.yml` step comment recording that the separate-step decision held. The holder is the one who decides whether the held reviews still carry over a merge commit. Refs #656 (stays OPEN). Lane: openxfactory-4 Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
…er reached (#28) Lane: openxfactory-4 (openXfactory-4-openDox_extraction) **The leg of the § 3.4 slice-S7 RESIDUE pair.** Its paired openxFactory row annotation (`chore/s7-residue-declared-edits`) declares every carve line this branch edits and **lands FIRST**, which is RULING **Q-L1**'s order ([`#656` comment `5628560136`](opensoft/openXfactory#656 (comment))). CLAIM: [`5714327188`](opensoft/openXfactory#656 (comment)). Refs #656 (stays OPEN). ## What this is SEVEN display-facet **leaves** that slice S7's own review found **inside the modules S7 had already parameterized at their mounts** — two threads Copilot opened on #21 at its gated head `c7a216c7` and **five it left SUPPRESSED in review [`5192900474`](#21 (review) body, with zero threads opened**. The S7 LANDED note ([`#656` comment `5688498049`](opensoft/openXfactory#656 (comment))) carried them forward as owed, and the gate's own rule — read the review BODY, never the thread count — is why they were not lost. Every one is the same failure: the vocabulary is installed where a view is MOUNTED and never threaded to a LEAF inside it. | file | leaf | what a host saw | | --- | --- | --- | | `views/docs.js` | `docHaystack()` indexed the raw `d.stage` while the row renders `vocab.documentStageWord(d.stage)` | a host mapping `brainstorm` to `jotted` hid every such document from a search for the word on screen | | `views/staging-workbench.js` | the nested `renderDocWheel` mounted without `display` | one pane in two vocabularies — `doc-wheel.js` resets its module vocabulary to `opts.display \|\| neutralDisplay()` on **every** render | | `views/staging-workbench.js` | `runAddSection()` handed `insertSection` no `options.display` | the **only** interactive add route placed and duplicate-checked sections against the neutral `SECTION_ORDER` inside an outline rendered in the host's words | | `views/board.js` | `brainstormCard()`'s date metadata spelled `captured` | one card in two vocabularies, beneath a heading that resolves the same status through the facet | | `views/display.js` | `applyTokens()` only ever ADDED inline `--st-*` properties | a role the new facet does not declare kept the old facet's colour, and an inline custom property outranks the stylesheet's theme-aware default | | `views/explorer.js` | the stale-tile fallback title rendered the raw `DRILL_KINDS` seam key | `proposal · REQ-14` in a dialog heading whose every other label resolves | | `views/lineage.js` | `renderStats()` kept the PREVIOUS render's vocabulary (`\|\| vocab`) | a render after a host facet was withdrawn went on speaking the withdrawn host's words instead of coming up visibly un-domained | **SIX OF THE SEVEN ARE INVISIBLE TO `tests/test_web_boundary.py` ASSERTION 4 and always would have been** — `captured` is in neither `_STATUS_WORDS` nor `_STAGE_WORDS`, a mount that forwards no option spells nothing at all, and a fallback that keeps the previous vocabulary is a missing RESET rather than a literal. The boundary census can be green while a pane renders in two vocabularies at once, which is why a review round and not the census found these. **`views/lineage.js` was the ONE site of eleven.** Measured over `src/opendox/web/views/*.js`: eleven modules install a module-level vocabulary at their render entry point and ten already reset to `neutralDisplay()`. `test_every_module_vocabulary_resets` is now the ratchet, and it pins the SET too, so a twelfth module that adopts the idiom and forgets the reset fails here instead of waiting for a review round. ## The proof `tests/test_display_facet_leaves.py`, **12 tests**, on the same footing as its neighbours in `validate.yml`'s narrowed list: it imports no `opendox` submodule at all, reads bundle files as text, and drives the REAL `views/display.js`, `views/explorer.js` and `views/outline-model.js` under the `node` the runner already has (skipped, never failed, where node is absent). `--noconftest` safe. THREE assertions RUN the module and nine read it, and the split is the tree's, not a preference: `applyTokens`, `drillKindWord` and `insertSection` are reachable from a pure ES-module harness; the other four sites live inside render functions that need a DOM to enter. Where a source assertion could pass on a decoration alone, a behavioural probe of the thing it feeds sits beside it — `test_insert_section_honours_the_declared_order` drives the real `insertSection` with a host that orders `conflicts` FIRST and shows the same press landing the section at opposite ends of the same fragment, which is what makes `runAddSection`'s one added argument matter. **PROVED AGAINST THE DEFECT, not just alongside the fix.** This file alone, dropped into a pristine worktree at `0b4e8bbf`, is **11 failed / 2 passed** — each failure its own leaf (it was 10 of 12 until Copilot's review at `b4efe155` earned a thirteenth test, below). The two that pass there are deliberate and say so in their docstrings: `applyTokens`' return contract is unchanged by the fix, and `insertSection` already honoured `options.display`, which is exactly why the caller omitting it was invisible. ## Measured, under `validate.yml`'s own invocation ``` python -m pytest -q <the 28-file list> --noconftest 712 passed, 2 skipped python -m pytest -q tests/test_display_facet_leaves.py --noconftest 13 passed ``` Re-run at the merged head `b4efe155`. The list was `694 passed` — slice S8's own figure, unchanged by this branch — until **#27 landed and appended `tests/test_binding_stylesheets.py`** to it; the two skips are that file's own and deliberate (no assembly has placed openXdox's six contributed modules in this bundle, RULED Q5). python 3.12.3 / pytest 8.4.2. **The census is RE-MEASURED, not adjusted**: `tests/fixtures/web_boundary_census.yaml`'s own ratchet re-derives every `loc` from the tree and re-sums the class totals, so the six rows this branch grows and the two totals move together — A `17883 -> 17904`, C `12564 -> 12617` at the base, and **A `18019` / C `12519` at the merged head**, DERIVED from the merged rows and never added from the two sides: #27 moves `views/view_extension.js` A `877 -> 992` and `styles.css` C `2595 -> 2497`, this branch moves six other rows, the two row sets are DISJOINT, and every one of the 42 rows' `loc` was re-measured against the merged tree with the test's own rule — zero mismatches. `tests/test_display_facet.py`'s two inline style doubles carried only `setProperty`; `applyTokens` now clears before it writes, so they carry `removeProperty` too and delete what they recorded — the shape that file's own `_DOM_STUB` has always had. It is an ADMITTED created file, so this is not a declared edit. ## A SEPARATE `- name: pytest (S7 residue)` STEP, and it is a merge decision with a measurement behind it openDox-code **#27** (RULED Q7's binding stylesheets) appends `tests/test_binding_stylesheets.py` at the same list tail, so a second append there is a textual conflict on whichever of the two lands second — over a line whose ORDER carries no meaning. A separate step conflicts with nothing, reports its own red/green in the check's log, and folds back onto the list in one hunk whenever an act wants it there. **That is now measured rather than forecast.** #27 landed first (`5c137a90`) and this branch merged `main` at `b4efe155`: `.github/workflows/validate.yml` AUTO-MERGED with both appends intact, and the census fixture's `totals:` block was the merge's ONLY conflict. ## What this does NOT do — residue, by name 1. **`tests/test_doc_wheel.py:393` reads a 600-CHARACTER window** from `renderDocWheel(selector` to find `renderAbstract(abstract,` — 470 characters apart at `0b4e8bbf`. A house-style comment block at that exact site (531 characters) moves the callback out of the window and turns a WIRING assertion red for a reason that has nothing to do with wiring. The wheel mount therefore carries a one-line comment here and the argument for it lives in the new test file, the manifest note and the commit message. **Repairing the window is an edit to a carved test file at lines the paired annotation does not declare**, so it is registered rather than taken — the same disposition Act 1 gave slice S8's two path constants, and the one this act exists to discharge. 2. **`views/viewer.js:262`'s `doc.stage` pill** stays where the S7 note's register put it: a boundary-note amendment, not a declared edit. 3. The **one unapplied** declared-edit row at this leg (`doxbench_scope_types.py`'s three `adapter calls` lines, a group-3 record against open successor openxFactory#838) is untouched and still unapplied. ## Gate | | | | --- | --- | | required check | `validate` only | | base | `main` @ `0b4e8bbf` | | landing | AFTER its paired openxFactory annotation (RULING Q-L1) | 🤖 Generated with [Claude Code](https://claude.com/claude-code) Lane: openxfactory-4 Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>




Lane: openxfactory-4 (openXfactory-4-openDox_extraction)
Refs #656 (stays OPEN).
CLAIM: 5699629486 (openxFactory#656 comment 5699629486)
LANDING ORDER — this act is three pull requests and they land in this order:
chore/q7-css-extraction-declared-edits— the Q-L1 row annotation. LANDS FIRST: it is what makes the openDox-code leg's 89 removed lines a DECLARED edit instead of anarrival-undeclared-editrefusal, and it carries the created-file admissions for both legs.build/q7-binding-stylesheets— theViewBinding.stylesslot, the<link>injection, and the 59 rule blocks leavingsrc/opendox/web/styles.css.pyproject.tomlpinsopendox @ …@a99eba03, which has nostylesfield. The bump to an openDox carrying leg 2 is what turns the sheets on.build/q7-binding-stylesheets— the four sheets beside the modules. Safe to land at ANY point after 1: it feature-detects the pinnedViewBindingand its sheets are inert until the pin moves.THIS PR IS STEP 2. It must not merge before openxFactory
chore/q7-css-extraction-declared-edits: without that annotation,scripts/verify-carve-arrival.py --destination opendox_code --phase Brefuses this head witharrival-undeclared-editnaming 89 carve lines onscripts/ideation_dashboard/web/styles.css, andtests/test_binding_stylesheets.pyis a created file no admission names.RULED openxFactory#656 comment
5700475319(Brett Heap, 2026-09-16, by interactive multi-choice) — the two questions this act put to him, both answered as this act already does them, and both now CITED where the decision is stated (a decision recorded without its ruling reads, one act later, as the author's preference):stylesspecifier, href de-duplication LOAD-BEARING. Refused: a tuple-valuedstyleswith a seventh shared sheet; six sheets duplicating the eleven blocks both workbench modules name.--st-custom properties MOVE VERBATIM, with the coupling REGISTERED BY MEASUREMENT inopenxdox.view_extensions.STYLE_RESIDUE["open_coupling"], asserted by openXdox-code's suite. Refused: widening the stable surface by ruling; a second declared token family; deferring to the BUILD arc.RULED Q7 (Brett Heap, 2026-09-12,
opensoft/openxFactory#656comment5648049748): "a contributed binding's CSS lives WITH THE BINDING, in its ownsheet; openDox's declared design tokens (the
--st-*family, S7) are the onestable styling surface; nothing else in
styles.cssis." Slice S5 recorded theextraction as owed and blocked (
openxdox.view_extensions.STYLE_RESIDUE); theS7 LANDED note (
5688498049) register item 1 records it still owed. This isopenDox's half.
THE SEAM.
ViewBindinggains an optionalstylesslot — one bundle-relative./….cssspecifier, validated by_SHEET, which is_MODULE's grammar with.cssand a second pattern rather than one widened to(js|css): a<link>fetches without
type="module"'s CORS rules, so the seam that admits a sheetcannot be the one that admits a script.
as_manifest_entry()carries it, so/capabilitiespublishes it with no new route.views/view_extension.jsvalidates the same field with the same refusal (§ 4.1's "one vocabulary, both
halves") and
resolveBindinginjects ONE<link rel="stylesheet">intodocument.head— neverdocument.body, RULED Q8 — deduped by resolved href,before the module import so the sheet and the module fetch together. A sheet
that fails to load is a NAMED console refusal and the panel mounts unstyled: a
binding's contract is its manifest entry, not its appearance.
WHAT LEFT
styles.css, MEASURED. 59 rule blocks, 98 lines, plus one linechanged in place — every selector whose every class is named by openXdox's six
contributed modules and by no file of openDox's own bundle. The census is
re-derived by openxFactory
scripts/measure_opendox_css_census.pyat openDox-code0b4e8bbf/ openXdox-code0a0265f7: 54 gate-exclusive classes, 18 shared (18, NOT 21: Copilot's rounds 5-6 narrowed the census's gate-side scan again — an assignment counts only where the target is class-named, and a.tokenonly inside a literal SHAPED like a selector with the dot in selector POSITION — so"e.g. Field Pilots","gate.lens: ..."andbtn.title = "... this staging topic "stop namingg,lensandtopic. WHAT LEAVES IS UNCHANGED: the same 54 gate-exclusive classes, the same 59 blocks at the same extents, the same 89 lines — a class moving from SHARED to openDox's own is a class that stays either way).STYLE_RESIDUE's51 / 24reproduces EXACTLY atcb343ae8under the sametool's literal-only scan — and the 51 was three short, because
.dispose-accepted,.dispose-rejectedand.dispose-deferredare built by"disposebtn dispose-" + v.outcome(dispose.js:275) and no literal search cansee them.
The two MIXED rules — the only two in the file naming a gate class beside an
openDox one — are handled and not exempted:
:176's selector list is SPLIT(openDox keeps
.filterpop[hidden]), and:2535.swb-draftchrome .swb-cactionsmoves whole, carrying the one openDox class a contributed sheetnames as host context.
WHAT STAYED. Every
--st-*token in all four theme blocks, every sharedselector, and the six orphaned
.intentchip*rules —intent-binding.jsdelegates to the absent
views/intent-feed.js(RULED OQ-Fnot_moved), so theyare the intent-feed residue and not this act's.
THE PROOF.
tests/test_binding_stylesheets.py,--noconftestsafe and onvalidate.yml's explicit list as the last entry: the slot refused at bothhalves of the seam, the absent case carried, the injector driven under
nodeagainst the real registry (one link for two bindings naming one sheet, none for
a binding declaring none,
headand neverbody, the failed-sheet warning),and the extraction itself measured against the file — no gate-exclusive selector
survives in
styles.css, the tokens and the shared selectors do, and where anassembly has placed the six modules the declared set is RE-DERIVED from them
rather than trusted.
tests/fixtures/web_boundary_census.yamlre-derived bymeasure-census.py(styles.css2595 -> 2497,views/view_extension.js877 ->956).
validate.yml's exact invocation at this commit: 708 passed, 2 skipped (the twothat need an assembled bundle).
WHAT THIS DOES NOT DO. It ships no sheet: the four sheets land at openXdox-code
with the bindings that own them (RULED Q5's package data), and the six
ViewBindingspecs name them there. It touches neitherapp.jsnorindex.html. The declared-edit window for the 89 carve-commit lines this actremoves from
styles.cssis openxFactory's row annotation, which lands FIRST(RULED Q-L1,
#656comment5628560136).Summary by Sourcery
Move contributed view styling into binding-owned stylesheets and make the binding contract load and validate those styles consistently across the server and browser.
New Features:
Bug Fixes:
Enhancements:
CI:
Tests: