M-5: Vision surface (typed requestFrameAttach; B-03 closure via WKWebView round-trip) #9
Open
opened 2026-05-12 19:02:33 +00:00 by KofTwentyTwo
·
0 comments
No Branch/Tag Specified
develop
ci/secrets-historical-baseline
feature/security-findings-2026-10
dependabot/npm_and_yarn/webview/npm_and_yarn-3ac77625be
dependabot/npm_and_yarn/webview/packages/bus/npm_and_yarn-c86b58a346
dependabot/npm_and_yarn/webview/vitejs/plugin-react-6.0.2
dependabot/npm_and_yarn/webview/vite-8.0.13
dependabot/npm_and_yarn/webview/zustand-5.0.13
dependabot/npm_and_yarn/webview/types/node-25.9.1
dependabot/npm_and_yarn/webview/vitest-4.1.6
dependabot/github_actions/actions/setup-node-6
dependabot/github_actions/github/codeql-action-4
dependabot/github_actions/actions/checkout-6
dependabot/github_actions/actions/cache-5
dependabot/github_actions/pnpm/action-setup-6
feat/local-first-llm-routing
docs/local-first-llm-routing-spec
fix/v0.2-wave-1-code-fixes
docs/v0.2-wave-1-doc-drift
docs/handoff-2026-05-14
docs/multi-runner-inventory
docs/ollama-baseline-58
fix/ci-env-harness-sqlite-voice-warmup
fix/ci-xcode-26-and-batcher-timing
chore/typecheck-blocking
fix/hud-typecheck-strict-undefined
wip/voice-log-menu-stash4
v0.1.0-dev.71
v0.1.0-dev.68
v0.1.0-dev.64
v0.1.0-dev.50
Labels
Clear labels
area:agent
area:build
area:bus
area:devtool
area:hud
area:logging
area:mcp
area:memory
area:vision
area:voice
audit-finding
bug
carry-forward
comment-cleanup
dependencies
documentation
duplicate
enhancement
epic
good first issue
help wanted
invalid
javascript
migration
question
severity:critical
severity:high
severity:low
severity:medium
wontfix
Something isn't working
Comment / docstring cleanup per .planning/code-commenting-guide.md
Dependency updates
Improvements or additions to documentation
This issue or pull request already exists
New feature or request
Good for newcomers
Extra attention is needed
This doesn't seem right
Pull requests that update javascript code
Further information is requested
This will not be worked on
Milestone
No items
Projects
Clear projects
No projects
No Assignees
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: KofTwentyTwo/Jarvis#9
Reference in new issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Goal
Land Vision surface.
requestFrameAttachreturns typedResult<FrameAttachArmed, FrameAttachError>through a real WKWebView round-trip. Closes B-03 (HUD camera button click does nothing). First atomic webview+Swift commit choreography (see plan §4).Scope — surfaces in this phase
JarvisAPI.Visionwith commandrequestFrameAttach -> Result<FrameAttachArmed, FrameAttachError>frameAttachController != nil, never silently returns.success(R-003)framePending(captureId:),frameSent(turnId:captureId:),frameExpired(captureId:)— captures correlate via FrameCaptureID (UUID)cancelFrameAttachcommand +getFrameAttachStatequery (for late-connect hydration)frameAttachRequestedinbound emit to typedVision.requestFrameAttachcall expectingResultframeAttachRequestedinbound case kept for one releaseFiles (created/modified)
packages/JarvisAPI/Sources/JarvisAPI/Surfaces/Vision+Adapter.swift(new)App/AppDelegate.swift:2115-2117— keep deprecated inbound case during transitionwebview/src/...— HUD camera button calls typed API (atomic with Swift)webview/dist/— rebuild viabash scripts/build-webview.shand commitpackages/Harness/Tests/HarnessTests/VisionScenarioTests.swift(new)Test contract
Scenarios
S-VIS-001..S-VIS-006. BOTH transport modes mandatory;.jsonRoundTripWebViewis NON-SKIPPABLE forS-VIS-001— this is the gate that proves B-03 dissolved:S-VIS-001—requestFrameAttachreturnsFrameAttachArmedwithin 100 ms (happy path)S-VIS-002— nil controller →Result.failure(.cameraPermissionDenied)(R-003)S-VIS-003— 5sframeExpireddeterministic viaManualClock(G-002)S-VIS-004..006— late-connect hydration, cancelFrameAttach, frameSent correlationAcceptance criteria
bash scripts/check-vision-isolation.shgreenbash scripts/check-presence-vision-isolation.shgreen.inProcessActorrunner.jsonRoundTripWebViewrunner —S-VIS-001non-skippable (B-03 dissolution gate)requestFrameAttachwith nil controller returnsResult.failure(.cameraPermissionDenied), never.successdist/parity withbash scripts/build-webview.shoutputframeExpireddeterministic viaManualClockCarry-forward closures
Dependencies
Sub-issues
Estimate
1.5–2.0 engineer-days
Source
.planning/architecture/JARVIS-API-MIGRATION-PLAN.md§2.6 + §4 (webview lockstep choreography).planning/architecture/JARVIS-API-DESIGN-v0.1.md—Visionsurface.planning/architecture/JARVIS-API-DESIGN-v0.2.md— F-007, F-010.planning/architecture/REVIEW-MIGRATION-RISK.mdR-003, R-015 partial