Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions jevdual/docs/native-row-contract.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,3 +51,11 @@ This is built and checked offline, not a delivered or live-qualified capability.
| Same-token replay | existing operation projection and ordinary consumer; no new dispatch | producer/retained faults stay unknown, presentation faults stay unverified, no second press |

These cases run across acknowledged delivery, SDK refusal, pre-input error and lost RPC reply using the production Rust row adapter with simulated AX/input. They do not claim application-effect confirmation or authenticate arbitrary external files. Replay does not independently authenticate every historical file: retained reads use the durable validator, while ordinary replay checks the projected copies. No SDK/AX dispatch code changes are needed for this agreement check.

## AXWindow NoValue membership

The held census accepts only AXWindow kAXErrorNoValue (-25212) as a reason to prove membership through AXParent. Each complete held-reference parent chain must remain in the same PID, have reciprocal parent/child membership, and end at the exact window whose native ID was checked. Any explicit non-root AXWindow must equal that window. Unsupported/timeout/other read errors, invalid types, missing parents, cycles, inconsistent aliases and exhausted bounds refuse. The full census still validates every edge/column alias before discovery. Additional chain work is charged to the existing two-second/500000-work budget; the existing 32-parent, 2048-node and 4096-held-reference limits are unchanged.

This is an observation membership proof, not an optional-attribute shortcut. The actual click recipient still requires its explicit AXWindow, and dispatch repeats the census against held token objects before the existing foreground check and press. No across-command object continuity or atomic app-side final-read/press is promised. The motivating retained trace proves only NoValue on a local AXGroup; parent-chain positives are synthetic until a separately authorized live observation establishes actual topology.

The offline row-parent dispatch probe mirrors the actual recipient explicit-window preflight before general peer membership. Recipient NoValue/missing/unreadable/foreign values yield zero synthetic presses and ordinary/durable refusal. This strengthens fixture fidelity only: the native CF reads, initial root discovery and real input remain source-assessed rather than executed by that probe.
36 changes: 36 additions & 0 deletions jevdual/docs/notebook/2026-11-17-native-row-parent.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# Held-parent membership for row capture

## RWP1 · prediction · 2026-11-17 12:33
Hypothesis: the observed AXWindow NoValue refusal can be handled without weakening recipient authority when the existing held-object census proves a complete same-PID reciprocal parent chain to the exact window. NoValue alone is never proof.
Test: preserve the real capture error as a failing native read-policy regression; construct explicitly synthetic direct-window/NoValue-chain positives and foreign-window/PID, Unsupported/timeout/error, missing/unreadable parents, cycle, conflicting alias, incomplete children and budget negatives. Exercise the shared Rust membership algorithm through actual SDK probe and public ordinary/durable CLI, with native error-policy tests and matched generated wheel bindings. Trace/callback and prior row recipient controls remain. Freeze final source for independent Kimi K3.1 Pro, GPT-6.1 Sol, Antigravity Gemini4Hydrogen review before integration/delivery. One live guarded observation only after checked delivery and serialized owner pause, never an action/retry.
Predicts: direct-window positives are unchanged; NoValue qualifies only with complete held-parent proof. All other read errors and contradictory membership refuse with zero press. Existing two-second/2048-node/4096-reference/500000-comparison bounds account additional work; incomplete evidence never creates a row binding. Generated ABI/callback ownership and row/effect rules remain unchanged.
Against: unsafe chain accepted, explicit disagreement ignored, NoValue conflated with Unsupported, budget enlarged/unaccounted, synthetic graph presented as live evidence, or any authority dependency outside this contract. Stop on new scope dependency; preserve failures.
Refs: /Volumes/External SSD/demoApps/demo/films/showcase-2026-11-17/workspace/approved-path-readiness-002/diagnostic-001/{row-trace.json,DIAGNOSIS.md,READ-REFUSAL-SPECIMEN.json}; /Volumes/External SSD/Footwork-native-row-parent-evidence-20261117/BASELINE.json.

## RWU1 · update · 2026-11-17 13:01
Observed: RWP1 red boundary retained: native error-policy regression 1 failed/1 passed; shared membership tests 2 failed/2 passed; actual Rust adapter/public CLI 4 failed/25 passed. The four failures are synthetic complete/flattened valid NoValue parent chains in ordinary/durable mode. Initial native command used an incorrect Cargo package name and is preserved as setup failure, not evidence.
Next: implement only exact NoValue held-parent membership, preserve error/alias/budget refusal and existing recipient/evidence contracts. Kimi review route corrected by Thomas to Kimi CLI standard kimi-code/k3.1-pro; resolve current settings at dispatch.
Refs: /Volumes/External SSD/Footwork-native-row-parent-evidence-20261117/{parent-contract-red.txt,native-parent-red-correct-package.txt,public-cli-red.txt,probe-red-build.txt}.

## RWU2 · update · 2026-11-17 13:12
Observed: behavior commit 50b46ff1 builds pinned parent1 wheel; 613 affected Python tests, 76 Rust contract tests and 2 native capture-policy tests pass. Initial affected run retained 1 stale version-pin assertion failure/612 passes; corrected test names exact parent1 distribution. Archive, source and wheel-build extraction match all 903 SDK source files; generated ABI and callback ownership modules are byte-identical to trace2. No installed/runtime change or live collection.
Next: freeze exact source and artifacts for three independent council reviews using Kimi CLI standard K3.1 Pro/max, GPT-6.1 Sol/high and Antigravity Gemini4Hydrogen/high; resolve findings before CI/integration/delivery. RWP1 remains open for independent review and separately authorized single live observation.
Refs: /Volumes/External SSD/Footwork-native-row-parent-evidence-20261117/{CHECKPOINT.json,integrated-final.txt,integrated-final-pin.txt,contract-final.txt,native-parent-final.txt,WHEEL-IDENTITY.json,SDK-SOURCE-HASHES.json}.

## RWP2 · prediction · 2026-11-17 13:37
Hypothesis: the council probe mismatch is isolated to the offline dispatch adapter omitting the actual recipient explicit-window preflight; native production already refuses that condition.
Test: preserve recipient-local NoValue counterexample through ordinary/durable public CLI before correcting the probe. Include direct recipient and peer-only NoValue positives, recipient Unsupported/timeout/foreign/missing controls, zero-press refusal receipts and durable same-token replay. Rebuild/rebind only the owned probe/package after red tests; compare all production SDK files and callback/ABI bytes to frozen352cbdac.
Predicts: recipient NoValue tests fail on the retained old probe and pass with zero sends after the preflight mirror. Valid peers and direct recipients still dispatch exactly once, unverifiable; no production code changes.
Against: the correction alters production behavior, hides the original positive/negative controls, or still acknowledges a missing/unreadable/foreign recipient window.
Refs: /Volumes/External SSD/Footwork-native-row-parent-evidence-20261117/council-kimi-352cbdac/REVIEW.md; Sol I1 and Gemini F2 on same frozen source.

## RWU3 · update · 2026-11-17 13:41
Observed: RWP2 red public-CLI regressions 8 failed/41 passed on retained352cbdac probe; corrected probe 49 passed. Only SDK example row_parent_probe.rs changes, other902SDKfiles identical. Initial append used a doubled path and did not add tests; that prior29-test run is retained separately, not counted as red evidence. The scoped correction mirrors strict actual-recipient window read before general census; production source is unchanged.
Next: rebind package/wheel/probe, run affected checks and obtain fresh council on correction; preserve all original reviews and frozen artifacts.
Refs: /Volumes/External SSD/Footwork-native-row-parent-evidence-20261117/correction-001/{recipient-red.txt,recipient-red-correct-path.txt,recipient-green.txt,PRODUCTION-EQUIVALENCE.json,SDK-CORRECTION.diff}.

## RWU4 · update · 2026-11-17 13:44
Resolves: RWP2 = held
Observed: corrected package/probe passes633affectedPython tests (49focused cases), zero skips. Only offline example changes among903SDKfiles; native SDK library, callback and generated contract bytes match352cbdac wheel. Rebuilt CLI binary and wheel RECORD differ and are bound by fresh hashes; no claim of all-binary identity. Production code remains unchanged, so prior76Rust/2native-policy checks are retained evidence, not repeated runs.
Next: fresh council review of the correction and package binding, carrying original findings; no installed or live action until review/check gates clear.
Refs: /Volumes/External SSD/Footwork-native-row-parent-evidence-20261117/correction-001/{integrated-final.txt,WHEEL-IDENTITY.json,PRODUCTION-EQUIVALENCE.json,SDK-CORRECTION.diff}.
2 changes: 1 addition & 1 deletion jevdual/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ dependencies = [

[project.optional-dependencies]
desktop = [
"cua-driver==0.46.0+footwork.5486b624.cleanup2.focus1.helptag1.connected4.locate10.row4.trace2", # tests/contract/test_cua_driver_seams.py
"cua-driver==0.46.0+footwork.5486b624.cleanup2.focus1.helptag1.connected4.locate10.row4.trace2.parent1", # tests/contract/test_cua_driver_seams.py
"jeepney==0.9.0 ; sys_platform == 'linux'", # bounded AT-SPI exact-text access
"pyobjc-framework-applicationservices>=12 ; sys_platform == 'darwin'",
"pyobjc-framework-quartz>=12 ; sys_platform == 'darwin'",
Expand Down
2 changes: 1 addition & 1 deletion jevdual/tests/contract/test_cua_driver_seams.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@

cd = pytest.importorskip("cua_driver")

PINNED_VERSION = "0.46.0+footwork.5486b624.cleanup2.focus1.helptag1.connected4.locate10.row4.trace2"
PINNED_VERSION = "0.46.0+footwork.5486b624.cleanup2.focus1.helptag1.connected4.locate10.row4.trace2.parent1"


def _params(cls) -> set[str]:
Expand Down
2 changes: 1 addition & 1 deletion jevdual/tests/test_cua_driver_build.py
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ def test_local_native_patch_has_inspectable_hash_bound_provenance():
for name, hashes in foreground['files'].items():
assert hashlib.sha256(source.extractfile(name).read()).hexdigest() == hashes['after']
assert hashes['before'] != hashes['after']
steps = (('ordinary-helptag', helptag, 2), ('connected-click', connected, 2), ('ref-locate', locate, 3), ('row-recipient', row, 17))
steps = (('ordinary-helptag', helptag, 2), ('connected-click', connected, 2), ('ref-locate', locate, 3), ('row-recipient', row, 19))
for index, (step, record, count) in enumerate(steps):
step_patch = (vendor / f'patches/{step}.patch').read_bytes()
assert hashlib.sha256(step_patch).hexdigest() == record['patch_sha256']
Expand Down
95 changes: 95 additions & 0 deletions jevdual/tests/test_native_row_parent.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,95 @@
"""Synthetic held-parent graph through shared Rust capture check and public CLI.

Only the NoValue error is live-derived. No full Chrome graph was captured.
"""
import pytest

from tests import test_native_row_sdk_cli as cli
from tests import test_session_scenarios as scenarios
from tests.test_native_row_sdk import PROBE, click_wire, graph_fixture, node, probe

world = scenarios.world
fw = scenarios.fw
pytestmark = pytest.mark.skipif(not PROBE, reason="requires pinned row_parent_probe")


@pytest.mark.parametrize("durable", [False, True])
@pytest.mark.parametrize("variant", ["complete", "flattened"])
@pytest.mark.parametrize("fault", ["direct", "no_value", "unsupported", "timeout", "foreign"])
def test_public_cli_held_parent_contract(world, fw, monkeypatch, tmp_path, durable, variant, fault):
original = cli.probe
def with_membership(data):
return original({**data, "window_faults": {} if fault == "direct" else {"1": fault}})
monkeypatch.setattr(cli, "probe", with_membership)
_graph, sent = cli.sdk_row_world(world, monkeypatch, variant)
cli.start_row(fw, monkeypatch, tmp_path, durable)
result = fw("do", "click", "section:Task ID=TASK-0::combobox:Open menu",
*(["--token", "parent-contract"] if durable else []))
if fault in ("direct", "no_value"):
assert result[0] == 0, result
assert sent == [940]
assert cli.last_receipt(fw)["effect"] == "unverifiable"
else:
assert result[0] != 0, result
assert sent == []


@pytest.mark.parametrize("fault", ["foreign", "unsupported", "timeout", "missing_parent",
"cycle", "nonreciprocal", "alias", "wrong_pid", "budget"])
def test_actual_dispatch_refuses_invalid_membership(fault):
graph = graph_fixture()
data = {"mode": "discover", "graph": graph, "pid": 77, "window_id": 40335, "recipient": 940}
binding = probe(data)["binding"]
assert binding
faults = {"1": "no_value"}
extra = {}
if fault in ("foreign", "unsupported", "timeout"):
faults["1"] = fault
elif fault == "missing_parent":
node(graph, 1)["parent"] = None
elif fault == "cycle":
node(graph, 1)["parent"] = 2
elif fault == "nonreciprocal":
node(graph, 0)["children"] = []
elif fault == "alias":
# A conflicting edge outside the proved chain must still fail the full census.
node(graph, 20)["children"].append(940)
elif fault == "wrong_pid":
node(graph, 0)["pid"] = 78
elif fault == "budget":
extra["membership_budget"] = 1
answer = probe({"mode": "dispatch", "click": click_wire(), "binding": binding,
"graph": graph, "recipient": 940, "window_faults": faults, **extra})
assert answer["schema_valid"]
assert answer["presses"] == []
assert answer["receipt"]["dispatched"] is False


@pytest.mark.parametrize("durable", [False, True])
@pytest.mark.parametrize("variant", ["complete", "flattened"])
@pytest.mark.parametrize("fault", ["no_value", "unsupported", "timeout", "foreign", "missing"])
def test_actual_recipient_window_preflight_refuses_before_press(
world, fw, monkeypatch, tmp_path, durable, variant, fault,
):
from jevdual.session_operations import SessionOperations

original = cli.probe
def fault_at_dispatch(data):
if data.get("mode") == "dispatch":
data = {**data, "window_faults": {"940": fault}}
return original(data)
monkeypatch.setattr(cli, "probe", fault_at_dispatch)
_graph, sent = cli.sdk_row_world(world, monkeypatch, variant)
authority = cli.start_row(fw, monkeypatch, tmp_path, durable)
# Observation succeeds with a direct-window recipient. The independent
# recipient read fails only at dispatch, before the general peer census.
result = fw("do", "click", "section:Task ID=TASK-0::combobox:Open menu",
*(["--token", "recipient-window"] if durable else []))
assert not sent, result
assert cli.last_receipt(fw)["effect"] == "refused"
if durable:
with SessionOperations(authority) as operations:
status = operations.receipt(operations.status()[-1])
assert (status["state"], status["disposition"]) == ("final", "not_sent")
fw("do", "click", "section:Task ID=TASK-0::combobox:Open menu", "--token", "recipient-window")
assert not sent
2 changes: 1 addition & 1 deletion jevdual/uv.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions jevdual/vendor/cua-driver/PROVENANCE.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Reference commit: `5486b6246e4c807c0d793216e52df283671d9362` (release `cua-drive
Source directory: `libs/cua-driver/python/src/cua_driver`.
Python/native version: `0.46.0`. License: upstream MIT (`LICENSE.md`, copied as `LICENSE`).

Footwork distribution version: `0.46.0+footwork.5486b624.cleanup2.focus1.helptag1.connected4.locate10.row4.trace2`. The published 0.46.0 wheel does not contain the required shutdown cleanup, foreground text focus, passive HelpTag, connected-node click and ref locate patches and cannot satisfy this exact dependency. The upstream Python `__version__` remains `0.46.0`.
Footwork distribution version: `0.46.0+footwork.5486b624.cleanup2.focus1.helptag1.connected4.locate10.row4.trace2.parent1`. The published 0.46.0 wheel does not contain the required shutdown cleanup, foreground text focus, passive HelpTag, connected-node click and ref locate patches and cannot satisfy this exact dependency. The upstream Python `__version__` remains `0.46.0`.

Three Python files remain byte-for-byte from the exact release source. The contract UniFFI module carries the row2 ABI; the SDK UniFFI module preserves exact landed fdbf48f callback ownership/drop hardening after regeneration. __init__.py additionally exports ExpectedRow and RowReceipt. The published macOS wheel has the same files except that its packaging removes the `x-release-please-version` comment from `__init__.py`. Generated records and native library must always be upgraded together.

Expand All @@ -20,7 +20,7 @@ Three Python files remain byte-for-byte from the exact release source. The contr

## Source archive

`native-source.tar.gz` SHA256: `941c3b35a6d467a14c64a4bfe5a4d6a84a67b032675b893b856cb8dcf256b52a` (6,448,145 bytes). It is the end of a six-step patch chain on the selected release source: cleanup2, focus1, helptag1, connected4, locate10, row4. Each step's manifest under `patches/` binds its base archive, patch, patched archive and changed files by SHA256. The focus1 archive (`804aeb8b2ba5b2b49772250a0435032bd9510835a56a33122d1cab531810cfb2`, 6,403,795 bytes) remains in Git history; `python3 scripts/cua_source_chain.py --base <focus1 archive> --output <file>` rebuilds this archive from it and checks every hash.
`native-source.tar.gz` SHA256: `26a6a46dc089553a5505cfe109871e4f21b2638885b702a911cfdaeb3e44b90b` (6,451,272 bytes). It is the end of a six-step patch chain on the selected release source: cleanup2, focus1, helptag1, connected4, locate10, row4. Each step's manifest under `patches/` binds its base archive, patch, patched archive and changed files by SHA256. The focus1 archive (`804aeb8b2ba5b2b49772250a0435032bd9510835a56a33122d1cab531810cfb2`, 6,403,795 bytes) remains in Git history; `python3 scripts/cua_source_chain.py --base <focus1 archive> --output <file>` rebuilds this archive from it and checks every hash.

The complete upstream release archive has SHA256 `032ce99f2e33154082cf854a1a04213e8a7b9eeae0e524564c7c6adb0ae93112`. The selected, unpatched native archive has SHA256 `257a36f5a793ad66d9c3e276709a7c81b667ed960ca5a3544e2d0ea43678fad1`.

Expand Down
4 changes: 2 additions & 2 deletions jevdual/vendor/cua-driver/build_support.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@
import tarfile
from pathlib import Path, PurePosixPath

VERSION = "0.46.0+footwork.5486b624.cleanup2.focus1.helptag1.connected4.locate10.row4.trace2"
VERSION = "0.46.0+footwork.5486b624.cleanup2.focus1.helptag1.connected4.locate10.row4.trace2.parent1"
SOURCE_COMMIT = "5486b6246e4c807c0d793216e52df283671d9362"
SOURCE_SHA256 = "941c3b35a6d467a14c64a4bfe5a4d6a84a67b032675b893b856cb8dcf256b52a"
SOURCE_SHA256 = "26a6a46dc089553a5505cfe109871e4f21b2638885b702a911cfdaeb3e44b90b"
TOOLCHAIN = "1.97.1"


Expand Down
Binary file modified jevdual/vendor/cua-driver/native-source.tar.gz
Binary file not shown.
Loading
Loading