# Development and verification This page contains the longer commands omitted from the README. Keep the alpha.5 build/release lane and the alpha.13 compatibility lane in separate DSH checkouts, homes, profiles, and evidence records. ## Build lanes The normal lane uses the published alpha.5 packages in `package.json` and produces the release package. The alpha.13 lane overlays the public declarations from a clean local checkout; it does not claim that an alpha.13 npm package exists. ```powershell Set-Location npm ci npm run verify:environment npm run typecheck npm run typecheck:tests npm test npm run build npm run verify:distribution npm run pack:check # Against the exact local DSH alpha.13 checkout: $env:DSH_ALPHA13_RUNTIME = '' npm run typecheck:alpha13 npm run build:alpha13 $env:DSH_ALPHA13_RUNTIME = $null ``` `build.mjs` validates all direct installed dependencies against the lockfile, then hashes the actual compiler/bundler versions, source tree, compiler configuration, lockfile, build scripts, dependency graph, and selected runtime identity. A matching `output/build/stamp.json` plus matching `lib/` digest makes a repeated build a no-op; `--force` is available when deliberately regenerating output. `pack:check` uses `--ignore-scripts` so a dry-run does not start a second build. See the [version and artifact map](workspace-layout.md) before choosing a runtime or an older package. ## Alpha.13 public contract Use a clean checkout at DSH `dsh-v0.1.3-alpha.1`, commit `d347e703908d0406b7a7ef80e3a0e594d86b2215`, and an isolated profile. After `build:alpha13`, run: ```powershell $env:DSH_ALPHA13_RUNTIME = '' node scripts/adapter-runtime-contract.mjs ``` The contract test uses only public `Context`, `SessionStore`, `ctx.sessions.list()`, `Session.snapshotEvents()`, `prepare/enter/announce`, and append events. It covers a non-empty startup session, Session v2 tool identity, unrelated and matching results, attempt-versus-completion, dispose, seed reopen, abort, and child completion. It does not use `SessionHandle`, `agentLoop.create()`, model output, tool arguments, or transcript content. ## Isolated Web canary Build one candidate tgz, install that exact file into the alpha.13 profile, and restart `dsh web` only after confirming that no active task is running. Every restart prints a new one-time URL; use that URL in the authenticated browser. ```powershell $env:DSH_ALPHA13_RUNTIME = '' $env:DSH_ALPHA13_PROFILE = '' $env:DSH_ALPHA13_PACKAGE = '' $env:DSH_ALPHA13_WEB_PORT = '' $env:DSH_ALPHA13_UI_EVIDENCE = 'output/playwright/alpha13-lifecycle-/ui-observation.json' $env:DSH_ALPHA13_OUTPUT = 'output/gates/alpha13-compatibility-.json' npm run compatibility:alpha13 ``` The canary fails unless the installed `node_modules/dsh-deepcanary` file set and bytes match the supplied tgz, the public runtime contract passes, the Web process responds, and a separate UI evidence file is bound to the same candidate version/runtime. The old `DSH_ALPHA13_UI_OBSERVED=true` shortcut is intentionally unsupported. The UI evidence file is a sanitized observation record, not a transcript. Its minimum shape is: ```json { "schemaVersion": 1, "status": "observed", "surface": "Edge DSH Web UI", "pluginVersion": "", "dshTag": "dsh-v0.1.3-alpha.1", "packageSha256": "", "profileRef": "/web", "webPort": 43157, "checks": { "authenticated": true, "pluginPanelVisible": true, "currentInboxRendered": true }, "screenshotPath": "output/playwright/alpha13-lifecycle-/panel.png", "screenshotSha256": "" } ``` ## Playwright CLI loop Use Playwright CLI from `output/playwright/