diff --git a/.codecast/ci.toml b/.codecast/ci.toml new file mode 100644 index 0000000000..ea32cbf754 --- /dev/null +++ b/.codecast/ci.toml @@ -0,0 +1,35 @@ +# codecast's own CI runner (`cast ci run `): what .github/workflows/ci.yml cannot say. The jobs, their steps, +# matrices and `if:` gates come from ci.yml itself, read for the push or pull_request event the run stands in for; +# this file adds only the host-side facts. Schema: packages/shared/contracts/ciConfig.ts. + +repository = "codecast-sh/codecast" +name = "codecast-ci" +# A CI pool host (c8id.16xlarge, 64 vCPU / 128 GB) takes one run at a time; within it, job runners go sixteen at +# once, four cores each, each in a checkout of its own, as GitHub gives each job a runner of its own. +runs_per_host = 1 +parallel_jobs = 16 + +# The pool has no job cap, so ci.yml's matrices run their wide set on a push too (ci.yml, typecheck's note). +[vars] +CI_WIDE = "true" + +# Runner setup that needs root on GitHub's image: the pool's host image carries these tools already, and a slot user +# has no sudo. +[skip_steps] +"Install tmux" = "the CI host image has tmux" +"Install tmux (e2e tests need a real tmux server)" = "the CI host image has tmux" +"Allow the Electron sandbox, and a display for it" = "the CI host image has xvfb and allows unprivileged user namespaces" + +# ci.yml needs no secrets and no services. Every job counts as ci.yml says: computer-macos is continue-on-error +# (advisory), and verify is the one check GitHub requires; it runs after every gated job and fails when any of them +# did not end as its gate said. + +# Each test shard's JUnit report, beside its log: `scripts/ci/test-shards.ts --record` balances the shards from them. +[jobs.test-cli] +keep = ["$RUNNER_TEMP/junit.xml"] + +[jobs.test-web] +keep = ["$RUNNER_TEMP/junit.xml"] + +[jobs.test-convex] +keep = ["$RUNNER_TEMP/junit.xml"] diff --git a/.codecast/deploy.toml b/.codecast/deploy.toml index a7f31e748d..a0773c186a 100644 --- a/.codecast/deploy.toml +++ b/.codecast/deploy.toml @@ -62,6 +62,9 @@ live = "github-status:codecast - web" name = "cli" when = ["packages/cli/**", "packages/shared/**", "platform/**"] unless = ["**/*.test.ts", "**/*.test.tsx", "**/*.test.js", "**/*.test.cjs", "**/*.test.mjs", "**/__tests__/**", "**/__fixtures__/**", "**/*.testkit.ts", "**/Tests/**"] +# GitHub Actions cuts it today. `scripts/cut-cli-release.sh --runner codecast` cuts it on codecast's own machines +# (the signing Mac and a Linux CI host, gated on codecast's own CI verdict): switch this line to it once codecast's CI +# records main's verdicts and the signing certificate is on the signing Mac (pl-1157, ct-103165). run = "scripts/cut-cli-release.sh" live = "json:https://dl.codecast.sh/latest.json#sourceCommit,version" policy = "release" diff --git a/.codecast/flows/codecast-fix.cast b/.codecast/flows/codecast-fix.cast new file mode 100644 index 0000000000..a8a8eb38ab --- /dev/null +++ b/.codecast/flows/codecast-fix.cast @@ -0,0 +1,6 @@ +// Codecast's live flow (sd-3248, 2026-11-14): the Standard line as it ships, +// under its own name so the team can make it live. It changes no station; +// extending keeps it on the shipped line as that line improves. +digraph codecast_fix { + graph [extends="line", label="Codecast fix"] +} diff --git a/.codecast/release/cut.toml b/.codecast/release/cut.toml new file mode 100644 index 0000000000..ea09a9ace3 --- /dev/null +++ b/.codecast/release/cut.toml @@ -0,0 +1,40 @@ +# The CLI release's macOS half on codecast's own machines: `cast ci run --workflow +# .github/workflows/cut-cli-release.yml --config .codecast/release/cut.toml --os darwin --unsandboxed`, started by +# scripts/cut-cli-release.sh on the signing Mac. The workflow is the one GitHub ran; this file says what a Mac that is +# not a throwaway runner provides. Schema: packages/shared/contracts/ciConfig.ts. A dispatched run is never recorded +# as the commit's CI. + +repository = "codecast-sh/codecast" +name = "codecast-release-cut" +workflow = ".github/workflows/cut-cli-release.yml" + +# The workflow leaves finalize to the driver here, and restores the keychain settings it changes. +[vars] +CLI_RELEASE_RUNNER = "codecast" + +# The signing identity, only for the job that signs. Where these live is decided in sd-5228; the names are the vault's. +[secrets.MACOS_SIGN_CERT_P12] +vault = "cli-release-sign-cert-p12" +jobs = ["build"] + +[secrets.MACOS_SIGN_CERT_PASSPHRASE] +vault = "cli-release-sign-cert-passphrase" +jobs = ["build"] + +# The staging upload (the builder's five objects, which finalize checks against the manifest). +[secrets.R2_ACCESS_KEY_ID] +vault = "cli-release-r2-access-key-id" +jobs = ["build"] + +[secrets.R2_SECRET_ACCESS_KEY] +vault = "cli-release-r2-secret-access-key" +jobs = ["build"] + +[secrets.R2_ENDPOINT] +vault = "r2-endpoint" +jobs = ["build"] + +# What the driver hands finalize: the builder's manifest and when its uploads began. +[jobs.build] +os = "darwin" +keep = ["$RUNNER_TEMP/release-manifest.json", "$RUNNER_TEMP/uploaded-after"] diff --git a/.codecast/release/finalize.toml b/.codecast/release/finalize.toml new file mode 100644 index 0000000000..79319d62c1 --- /dev/null +++ b/.codecast/release/finalize.toml @@ -0,0 +1,43 @@ +# The CLI release's publishing half on codecast's own machines: `cast ci run --workflow +# .github/workflows/finalize-cli-release.yml --config .codecast/release/finalize.toml` on a Linux CI pool host, started +# by scripts/cut-cli-release.sh once the macOS half is green. Its CI gate is codecast's own verdict (the driver hands it +# in as ci_verdict). Schema: packages/shared/contracts/ciConfig.ts. A dispatched run is never recorded as CI. + +repository = "codecast-sh/codecast" +name = "codecast-release-finalize" +workflow = ".github/workflows/finalize-cli-release.yml" + +[vars] +CLI_RELEASE_RUNNER = "codecast" + +# The codecast GitHub App (2712850) on codecast-sh (installation 105761679): contents write, for the version commit, +# the tag and the GitHub release. Minted per run, an hour long; the key never reaches the job. +[secrets.GITHUB_APP_PRIVATE_KEY] +vault = "github-app-private-key" +jobs = [] + +[secrets.GITHUB_TOKEN] +github_app = { id = 2712850, installation = 105761679, key_secret = "GITHUB_APP_PRIVATE_KEY" } # ggignore: names another secret entry, holds no value +jobs = ["finalize"] + +[secrets.R2_ACCESS_KEY_ID] +vault = "cli-release-r2-access-key-id" +jobs = ["finalize"] + +[secrets.R2_SECRET_ACCESS_KEY] +vault = "cli-release-r2-secret-access-key" +jobs = ["finalize"] + +[secrets.R2_ENDPOINT] +vault = "r2-endpoint" +jobs = ["finalize"] + +# The Ed25519 key latest.json is signed with (docs/architecture/release-signing.md). Where it lives is decided in +# sd-5228; the names are the vault's. +[secrets.RELEASE_MANIFEST_SIGNING_KEY] +vault = "cli-release-manifest-signing-key" +jobs = ["finalize"] + +[secrets.RELEASE_MANIFEST_KEY_ID] +vault = "cli-release-manifest-key-id" +jobs = ["finalize"] diff --git a/.codecast/workspace.toml b/.codecast/workspace.toml index 8e0cbc3018..7a2d3cfca4 100644 --- a/.codecast/workspace.toml +++ b/.codecast/workspace.toml @@ -7,7 +7,7 @@ # Schema: https://codecast.sh/docs/workspace [setup] -# Gitignored secrets/config a worktree needs to actually run web + convex + cli. +# Gitignored secrets/config a worktree needs to actually run web, convex, cli and mobile. # (git worktrees do not inherit these — they live outside version control.) copy = [ ".env", @@ -15,6 +15,7 @@ copy = [ "packages/convex/.env.local", "packages/web/.env.local", "packages/cli/.env.local", + "packages/mobile/.env", ] # A fresh worktree has its own (empty) node_modules — bun doesn't share them # across worktrees, so install once on creation. If this fails, the daemon diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c799751d9b..c809361ae0 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -197,16 +197,21 @@ jobs: if: needs.code_paths.outputs.run_typecheck == 'true' runs-on: ubuntu-latest timeout-minutes: 20 - # The programs in .codecast/check.toml over three jobs of about equal - # cold time (web alone, ~200s; the others pair up below it). mobile is - # left out: `cast check mobile` is its only check (see the contract test). + # The programs in .codecast/check.toml. A push to main checks them all in + # one job: its build info is never more than a push old, so the job takes + # about a minute. A pull request may start further from main, so it spreads + # them over three jobs of about equal cold time (web alone, ~200s). The + # free plan runs 20 jobs at once for the whole repository, and a wide + # matrix on every push to main left whole runs queued behind each other. + # A runner with no such cap sets the repository variable CI_WIDE to true + # (codecast's own pool, in .codecast/ci.toml [vars]) and runs the wide set + # on a push as well; every matrix below follows the same rule. + # mobile is left out: `cast check mobile` is its only check (see the + # contract test). strategy: fail-fast: false matrix: - include: - - { key: web, programs: web } - - { key: cli-evals, programs: cli evals } - - { key: convex-sim-playground, programs: convex sim playground } + include: ${{ fromJSON(github.event_name == 'push' && vars.CI_WIDE != 'true' && '[{"key":"all","programs":"web cli evals convex sim playground"}]' || '[{"key":"web","programs":"web"},{"key":"cli-evals","programs":"cli evals"},{"key":"convex-sim-playground","programs":"convex sim playground"}]') }} name: typecheck (${{ matrix.programs }}) steps: - uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4 @@ -223,13 +228,18 @@ jobs: with: path: ${{ runner.temp }}/tsbuildinfo key: tsbuildinfo-${{ matrix.key }}-${{ github.sha }} - restore-keys: tsbuildinfo-${{ matrix.key }}- + # main saves the whole set under "all"; a pull request's group starts from it. + restore-keys: | + tsbuildinfo-all- + tsbuildinfo-${{ matrix.key }}- - name: Typecheck # web's program outgrew V8's default ~4 GB heap: on 2026-11-08 its tsc - # died in GC at 4029 MB (exit 134). + # died in GC at 4029 MB (exit 134). A 64 MB young generation (V8's + # default is 16) scavenges less: web's cold check 176s -> 164s on a + # pool runner's four cores. env: - NODE_OPTIONS: --max-old-space-size=6144 + NODE_OPTIONS: --max-old-space-size=6144 --max-semi-space-size=64 # Each program's tsconfig is the one .codecast/check.toml names for it. run: | status=0 @@ -285,6 +295,13 @@ jobs: if: needs.code_paths.outputs.run_test_convex == 'true' runs-on: ubuntu-latest timeout-minutes: 20 + # One process for the whole suite on GitHub; a runner with no job cap + # (CI_WIDE, see typecheck) splits it by recorded time. + strategy: + fail-fast: false + matrix: + shard: ${{ fromJSON(vars.CI_WIDE == 'true' && '["1/3","2/3","3/3"]' || '["1/1"]') }} + name: test-convex (${{ matrix.shard }}) steps: - uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4 @@ -292,7 +309,21 @@ jobs: - name: Unit tests (convex package) working-directory: packages/convex - run: bun test convex/ scripts/ + # Each shard is one serial process, as the whole suite was: under + # --parallel a test that depended on its neighbours' order failed. + run: | + files="$(bun ../../scripts/ci/test-shards.ts packages/convex ${{ matrix.shard }})" + # shellcheck disable=SC2086 # one argument per file + bun test --reporter=junit --reporter-outfile=${{ runner.temp }}/junit.xml $files + + - name: Upload test timings + if: always() + uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4 + with: + name: junit-convex-${{ strategy.job-index }} + path: ${{ runner.temp }}/junit.xml + if-no-files-found: ignore + retention-days: 7 test-web: needs: [code_paths] @@ -306,8 +337,9 @@ jobs: strategy: fail-fast: false matrix: - shard: [1, 2, 3, 4] - name: test-web (${{ matrix.shard }}/4) + # Two shards on a push to main, four on a pull request (see typecheck). + shard: ${{ fromJSON(github.event_name == 'push' && vars.CI_WIDE != 'true' && '["1/2","2/2"]' || '["1/4","2/4","3/4","4/4"]') }} + name: test-web (${{ matrix.shard }}) steps: - uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4 @@ -325,14 +357,14 @@ jobs: env: SIM_OUT: ${{ runner.temp }}/sim run: | - files="$(bun ../../scripts/ci/test-shards.ts packages/web ${{ matrix.shard }}/4)" + files="$(bun ../../scripts/ci/test-shards.ts packages/web ${{ matrix.shard }})" # shellcheck disable=SC2086 # one argument per file bun test --parallel --reporter=junit --reporter-outfile=${{ runner.temp }}/junit.xml $files # The exact counts behind the perf benches (packages/web/perf/README.md). # Plain bun, not bun test: the test preload stands in for the diff viewer. - name: Perf budgets (web) - if: matrix.shard == 1 + if: startsWith(matrix.shard, '1/') working-directory: packages/web run: scripts/perf-budgets.sh @@ -340,7 +372,7 @@ jobs: if: always() uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4 with: - name: junit-web-${{ matrix.shard }} + name: junit-web-${{ strategy.job-index }} path: ${{ runner.temp }}/junit.xml if-no-files-found: ignore retention-days: 7 @@ -349,7 +381,7 @@ jobs: if: failure() uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4 with: - name: sim-artifacts-${{ matrix.shard }} + name: sim-artifacts-${{ strategy.job-index }} path: ${{ runner.temp }}/sim if-no-files-found: ignore retention-days: 14 @@ -364,7 +396,9 @@ jobs: strategy: fail-fast: false matrix: - part: ["1/3", "2/3", "3/3", "e2e"] + # Fewer unit shards on a push to main than on a pull request (see + # typecheck), and more on a runner with no job cap (CI_WIDE). + part: ${{ fromJSON(vars.CI_WIDE == 'true' && '["1/4","2/4","3/4","4/4","e2e"]' || github.event_name == 'push' && '["1/2","2/2","e2e"]' || '["1/3","2/3","3/3","e2e"]') }} name: test-cli (${{ matrix.part }}) steps: - uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4 diff --git a/.github/workflows/cut-cli-release.yml b/.github/workflows/cut-cli-release.yml index 76410f96b5..334a38b248 100644 --- a/.github/workflows/cut-cli-release.yml +++ b/.github/workflows/cut-cli-release.yml @@ -13,6 +13,12 @@ name: Cut signed CLI release # # Not covered here: npm publish and the Homebrew tap. Those remain laptop-only # mirrors in packages/cli/scripts/deploy.sh. +# +# The same workflow runs on codecast's own machines (`cast ci run --workflow`, +# started by scripts/cut-cli-release.sh with vars.CLI_RELEASE_RUNNER=codecast, +# .codecast/release/cut.toml): on a Mac that is not a throwaway VM. There the +# driver, not this job, starts finalize, and every keychain change below is +# undone when the job ends. on: workflow_dispatch: @@ -126,6 +132,9 @@ jobs: cert="$RUNNER_TEMP/codecast-sign.p12" printf '%s' "$CERT_P12_BASE64" | base64 --decode > "$cert" + # A Mac that outlives the job (codecast's signing Mac) gets its search + # list back when the keychain is removed. + security list-keychains -d user | tr -d '"' | xargs > "$RUNNER_TEMP/keychains-before" security create-keychain -p "$keychain_password" "$keychain" security set-keychain-settings -lut 5400 "$keychain" security unlock-keychain -p "$keychain_password" "$keychain" @@ -163,6 +172,10 @@ jobs: if [[ -n "${SIGN_KEYCHAIN:-}" && -f "$SIGN_KEYCHAIN" ]]; then security delete-keychain "$SIGN_KEYCHAIN" fi + if [[ -s "$RUNNER_TEMP/keychains-before" ]]; then + # shellcheck disable=SC2046 + security list-keychains -d user -s $(cat "$RUNNER_TEMP/keychains-before") + fi - name: Verify the signatures and embedded version shell: bash @@ -210,6 +223,10 @@ jobs: cd packages/cli bun test src/browser/appIdentity.test.ts src/browser/appIdentity.native.test.ts --timeout 30000 browser_keychain="$RUNNER_TEMP/browser-test.keychain-db" + # The test swaps the user's default keychain and search list; a Mac + # that outlives the job gets both back in the removal step. + security default-keychain -d user | tr -d '" ' > "$RUNNER_TEMP/default-keychain-before" + security list-keychains -d user | tr -d '"' | xargs > "$RUNNER_TEMP/browser-keychains-before" security create-keychain -p '' "$browser_keychain" security unlock-keychain -p '' "$browser_keychain" security default-keychain -d user -s "$browser_keychain" @@ -268,6 +285,13 @@ jobs: if: always() shell: bash run: | + if [[ -s "$RUNNER_TEMP/default-keychain-before" ]]; then + security default-keychain -d user -s "$(cat "$RUNNER_TEMP/default-keychain-before")" + fi + if [[ -s "$RUNNER_TEMP/browser-keychains-before" ]]; then + # shellcheck disable=SC2046 + security list-keychains -d user -s $(cat "$RUNNER_TEMP/browser-keychains-before") + fi if [[ -f "$RUNNER_TEMP/browser-test.keychain-db" ]]; then security delete-keychain "$RUNNER_TEMP/browser-test.keychain-db" fi @@ -351,6 +375,8 @@ jobs: # cutoff second. uploaded_after=$(date -u +%Y-%m-%dT%H:%M:%SZ) echo "UPLOADED_AFTER=$uploaded_after" >> "$GITHUB_ENV" + # Finalize's input when codecast's driver starts it (it reads the job's kept files). + echo "$uploaded_after" > "$RUNNER_TEMP/uploaded-after" sleep 2 cd packages/web/binaries for artifact in \ @@ -365,8 +391,10 @@ jobs: --no-progress done + # On codecast's machines the driver starts finalize itself, once this job + # is green, from the manifest and upload time the job kept. - name: Dispatch the finalize workflow - if: ${{ !inputs.dry_run }} + if: ${{ !inputs.dry_run && vars.CLI_RELEASE_RUNNER != 'codecast' }} env: GH_TOKEN: ${{ github.token }} shell: bash diff --git a/.github/workflows/finalize-cli-release.yml b/.github/workflows/finalize-cli-release.yml index 45e00715b6..1a62ca7353 100644 --- a/.github/workflows/finalize-cli-release.yml +++ b/.github/workflows/finalize-cli-release.yml @@ -1,5 +1,13 @@ name: Finalize pre-uploaded CLI release +# Also run by codecast's own machines (`cast ci run --workflow`, started by +# scripts/cut-cli-release.sh with vars.CLI_RELEASE_RUNNER=codecast, +# .codecast/release/finalize.toml). There the CI gate is codecast's own verdict +# on the source commit (commit_ci, kind runner), which the driver reads and +# hands in as ci_verdict, instead of GitHub's verify job. A dry run checks the +# identity, rebuilds the non-macOS binaries against the builder's manifest and +# checks the verdict, and writes nothing anywhere. + on: workflow_dispatch: inputs: @@ -28,6 +36,16 @@ on: required: true default: "180" type: string + dry_run: + description: Validate, rebuild and check CI only; stage, tag and publish nothing + required: false + default: false + type: boolean + ci_verdict: + description: codecast's CI verdict on the source commit (JSON, when codecast runs the release) + required: false + default: "" + type: string permissions: contents: write @@ -110,7 +128,7 @@ jobs: fi git merge-base --is-ancestor "$SOURCE_COMMIT" HEAD - printf '%s' "$EXPECTED_ARTIFACTS_JSON" | jq -S . > /tmp/release-expected.json + printf '%s' "$EXPECTED_ARTIFACTS_JSON" | jq -S . > $RUNNER_TEMP/release-expected.json jq -e \ --arg version "$RELEASE_VERSION" \ --arg source "$SOURCE_COMMIT" \ @@ -118,8 +136,8 @@ jobs: .source_commit == $source and (.built | type == "string" and length > 0) and (.artifacts | type == "object")' \ - /tmp/release-expected.json >/dev/null - if [[ "$(jq -r '.artifacts | keys | length' /tmp/release-expected.json)" != "5" ]]; then + $RUNNER_TEMP/release-expected.json >/dev/null + if [[ "$(jq -r '.artifacts | keys | length' $RUNNER_TEMP/release-expected.json)" != "5" ]]; then echo "::error::artifact manifest must contain exactly five entries" exit 1 fi @@ -128,12 +146,12 @@ jobs: --arg artifact "$artifact" \ '.artifacts[$artifact].sha256 | type == "string" and test("^[0-9a-f]{64}$")' \ - /tmp/release-expected.json >/dev/null + $RUNNER_TEMP/release-expected.json >/dev/null jq -e \ --arg artifact "$artifact" \ '.artifacts[$artifact].size | type == "number" and . > 1000000 and floor == .' \ - /tmp/release-expected.json >/dev/null + $RUNNER_TEMP/release-expected.json >/dev/null # The cast computer helper is a separately signed app bundle inside # the darwin binaries, so it is part of what a darwin artifact IS. # A darwin entry without it means the builder shipped a macOS CLI @@ -145,13 +163,13 @@ jobs: --arg artifact "$artifact" \ '.artifacts[$artifact].computer_helper_sha256 | type == "string" and test("^[0-9a-f]{64}$")' \ - /tmp/release-expected.json >/dev/null + $RUNNER_TEMP/release-expected.json >/dev/null ;; *) jq -e \ --arg artifact "$artifact" \ '.artifacts[$artifact] | has("computer_helper_sha256") | not' \ - /tmp/release-expected.json >/dev/null + $RUNNER_TEMP/release-expected.json >/dev/null ;; esac done @@ -160,11 +178,11 @@ jobs: # mean two different helpers went out under one version. if ! jq -e '.artifacts["codecast-darwin-arm64"].computer_helper_sha256 == .artifacts["codecast-darwin-x64"].computer_helper_sha256' \ - /tmp/release-expected.json >/dev/null; then + $RUNNER_TEMP/release-expected.json >/dev/null; then echo "::error::the two darwin artifacts carry different cast computer helpers" exit 1 fi - expected_keys=$(jq -r '.artifacts | keys[]' /tmp/release-expected.json) + expected_keys=$(jq -r '.artifacts | keys[]' $RUNNER_TEMP/release-expected.json) actual_keys=$(printf '%s\n' "${artifacts[@]}" | sort) if [[ "$(sort <<<"$expected_keys")" != "$actual_keys" ]]; then echo "::error::artifact manifest contains an unexpected filename" @@ -202,12 +220,12 @@ jobs: shell: bash run: | set -euo pipefail - build_root=/tmp/cli-fallback-build - output_root=/tmp/cli-fallback + build_root=$RUNNER_TEMP/cli-fallback-build + output_root=$RUNNER_TEMP/cli-fallback git worktree add --detach "$build_root" "$SOURCE_COMMIT" jq --arg version "$RELEASE_VERSION" '.version = $version' \ - "$build_root/packages/cli/package.json" > /tmp/fallback-cli-package.json - mv /tmp/fallback-cli-package.json "$build_root/packages/cli/package.json" + "$build_root/packages/cli/package.json" > $RUNNER_TEMP/fallback-cli-package.json + mv $RUNNER_TEMP/fallback-cli-package.json "$build_root/packages/cli/package.json" ( cd "$build_root" bun install --frozen-lockfile @@ -232,7 +250,7 @@ jobs: done ) - : > /tmp/cli-fallback-ready + : > $RUNNER_TEMP/cli-fallback-ready for artifact in \ codecast-linux-arm64 \ codecast-linux-x64 \ @@ -240,22 +258,39 @@ jobs: expected_sha=$(jq -r \ --arg artifact "$artifact" \ '.artifacts[$artifact].sha256' \ - /tmp/release-expected.json) + $RUNNER_TEMP/release-expected.json) expected_bytes=$(jq -r \ --arg artifact "$artifact" \ '.artifacts[$artifact].size' \ - /tmp/release-expected.json) + $RUNNER_TEMP/release-expected.json) actual_sha=$(sha256sum "$output_root/$artifact" | awk '{print $1}') actual_bytes=$(stat -c %s "$output_root/$artifact") if [[ "$actual_sha" == "$expected_sha" && "$actual_bytes" == "$expected_bytes" ]]; then - echo "$artifact" >> /tmp/cli-fallback-ready + echo "$artifact" >> $RUNNER_TEMP/cli-fallback-ready echo "$artifact reproduced byte-for-byte on the release runner" else echo "::warning::$artifact was not byte-identical; waiting for the builder upload" fi done + # A dry run uploads nothing. Whether the non-macOS binaries rebuild here + # byte-for-byte is reported, not required: a release ships the builder's + # bytes, checked against its manifest, whenever they do not. + - name: Report the non-macOS rebuilds + if: ${{ inputs.dry_run }} + shell: bash + run: | + set -euo pipefail + for artifact in codecast-linux-arm64 codecast-linux-x64 codecast-windows-x64.exe; do + if grep -Fxq "$artifact" $RUNNER_TEMP/cli-fallback-ready; then + echo "$artifact: rebuilt byte-for-byte; a release would take these bytes" + else + echo "::notice::$artifact: not byte-identical here; a release would ship the builder's upload" + fi + done + - name: Wait for all five mutable staging objects + if: ${{ !inputs.dry_run }} env: AWS_ACCESS_KEY_ID: ${{ secrets.R2_ACCESS_KEY_ID }} AWS_SECRET_ACCESS_KEY: ${{ secrets.R2_SECRET_ACCESS_KEY }} @@ -282,20 +317,20 @@ jobs: while true; do all_ready=true - : > /tmp/cli-object-state.txt - : > /tmp/cli-object-snapshot.tsv + : > $RUNNER_TEMP/cli-object-state.txt + : > $RUNNER_TEMP/cli-object-snapshot.tsv for artifact in "${artifacts[@]}"; do - if grep -Fxq "$artifact" /tmp/cli-fallback-ready; then + if grep -Fxq "$artifact" $RUNNER_TEMP/cli-fallback-ready; then expected_bytes=$(jq -r \ --arg artifact "$artifact" \ '.artifacts[$artifact].size' \ - /tmp/release-expected.json) + $RUNNER_TEMP/release-expected.json) printf '%s ready from byte-identical runner build bytes=%s\n' \ "$artifact" "$expected_bytes" \ - >> /tmp/cli-object-state.txt + >> $RUNNER_TEMP/cli-object-state.txt printf '%s\tfallback\tfallback\tfallback\t%s\n' \ "$artifact" "$expected_bytes" \ - >> /tmp/cli-object-snapshot.tsv + >> $RUNNER_TEMP/cli-object-snapshot.tsv continue fi metadata=$(aws s3api head-object \ @@ -308,23 +343,23 @@ jobs: expected_bytes=$(jq -r \ --arg artifact "$artifact" \ '.artifacts[$artifact].size' \ - /tmp/release-expected.json) + $RUNNER_TEMP/release-expected.json) modified_epoch=$(date -u -d "$modified" +%s) if (( modified_epoch <= cutoff_epoch )) || [[ "$bytes" != "$expected_bytes" ]]; then printf '%s waiting modified=%s bytes=%s expected=%s\n' \ "$artifact" "$modified" "$bytes" "$expected_bytes" \ - >> /tmp/cli-object-state.txt + >> $RUNNER_TEMP/cli-object-state.txt all_ready=false else printf '%s ready modified=%s bytes=%s\n' \ "$artifact" "$modified" "$bytes" \ - >> /tmp/cli-object-state.txt + >> $RUNNER_TEMP/cli-object-state.txt fi printf '%s\tstaging\t%s\t%s\t%s\n' \ "$artifact" "$etag" "$modified" "$bytes" \ - >> /tmp/cli-object-snapshot.tsv + >> $RUNNER_TEMP/cli-object-snapshot.tsv done - cat /tmp/cli-object-state.txt + cat $RUNNER_TEMP/cli-object-state.txt if [[ "$all_ready" == true ]]; then break fi @@ -336,6 +371,7 @@ jobs: done - name: Download and validate the builder artifacts + if: ${{ !inputs.dry_run }} env: AWS_ACCESS_KEY_ID: ${{ secrets.R2_ACCESS_KEY_ID }} AWS_SECRET_ACCESS_KEY: ${{ secrets.R2_SECRET_ACCESS_KEY }} @@ -351,25 +387,25 @@ jobs: codecast-linux-x64 codecast-windows-x64.exe ) - mkdir -p /tmp/cli-release + mkdir -p $RUNNER_TEMP/cli-release for artifact in "${artifacts[@]}"; do - if grep -Fxq "$artifact" /tmp/cli-fallback-ready; then - cp "/tmp/cli-fallback/$artifact" "/tmp/cli-release/$artifact" + if grep -Fxq "$artifact" $RUNNER_TEMP/cli-fallback-ready; then + cp "$RUNNER_TEMP/cli-fallback/$artifact" "$RUNNER_TEMP/cli-release/$artifact" else - aws s3 cp "s3://$R2_BUCKET/$artifact" "/tmp/cli-release/$artifact" \ + aws s3 cp "s3://$R2_BUCKET/$artifact" "$RUNNER_TEMP/cli-release/$artifact" \ --endpoint-url "$R2_ENDPOINT" \ --no-progress fi expected_sha=$(jq -r \ --arg artifact "$artifact" \ '.artifacts[$artifact].sha256' \ - /tmp/release-expected.json) + $RUNNER_TEMP/release-expected.json) expected_bytes=$(jq -r \ --arg artifact "$artifact" \ '.artifacts[$artifact].size' \ - /tmp/release-expected.json) - actual_sha=$(sha256sum "/tmp/cli-release/$artifact" | awk '{print $1}') - actual_bytes=$(stat -c %s "/tmp/cli-release/$artifact") + $RUNNER_TEMP/release-expected.json) + actual_sha=$(sha256sum "$RUNNER_TEMP/cli-release/$artifact" | awk '{print $1}') + actual_bytes=$(stat -c %s "$RUNNER_TEMP/cli-release/$artifact") if [[ "$actual_sha" != "$expected_sha" || "$actual_bytes" != "$expected_bytes" ]]; then echo "::error::$artifact does not match the builder manifest" exit 1 @@ -381,7 +417,7 @@ jobs: local format=$2 local architecture=$3 local descriptor - descriptor=$(file -b "/tmp/cli-release/$artifact") + descriptor=$(file -b "$RUNNER_TEMP/cli-release/$artifact") if [[ "$descriptor" != *"$format"* || "$descriptor" != *executable* ]]; then echo "::error::$artifact has unexpected file descriptor: $descriptor" @@ -406,8 +442,8 @@ jobs: assert_binary_kind codecast-linux-arm64 'ELF 64-bit' arm64 assert_binary_kind codecast-linux-x64 'ELF 64-bit' x64 assert_binary_kind codecast-windows-x64.exe 'PE32+' x64 - chmod +x /tmp/cli-release/codecast-linux-x64 - actual_version=$(/tmp/cli-release/codecast-linux-x64 --version | tr -d '[:space:]') + chmod +x $RUNNER_TEMP/cli-release/codecast-linux-x64 + actual_version=$($RUNNER_TEMP/cli-release/codecast-linux-x64 --version | tr -d '[:space:]') if [[ "$actual_version" != "$RELEASE_VERSION" ]]; then echo "::error::linux-x64 reports version $actual_version, expected $RELEASE_VERSION" exit 1 @@ -428,7 +464,7 @@ jobs: echo "::error::$artifact changed while the release snapshot was downloading" exit 1 fi - done < /tmp/cli-object-snapshot.tsv + done < $RUNNER_TEMP/cli-object-snapshot.tsv # The CI gate for a release (deploy.toml's cli target leaves it here): the # cut builds and signs while CI runs on the same commit, and nothing is @@ -440,6 +476,7 @@ jobs: # that holds the source commit: green on any of them passes, and red on the # newest of them fails. - name: Wait for CI on the source commit + if: ${{ vars.CLI_RELEASE_RUNNER != 'codecast' }} shell: bash env: GH_TOKEN: ${{ github.token }} @@ -498,7 +535,24 @@ jobs: echo "::error::CI reached no verdict on $SOURCE_COMMIT in 90 minutes" exit 1 + # The CI gate when codecast runs the release: codecast's own verdict on the + # source commit, or on a later main commit holding it, must be green before + # anything public is written. The driver read it from commit_ci when it + # started this job; this step refuses one that does not pass for this commit. + - name: Check codecast's CI verdict on the source commit + if: ${{ vars.CLI_RELEASE_RUNNER == 'codecast' }} + shell: bash + env: + CI_VERDICT: ${{ inputs.ci_verdict }} + DRY_RUN: ${{ inputs.dry_run }} + run: | + set -euo pipefail + args=(check --source "$SOURCE_COMMIT") + [[ "$DRY_RUN" == "true" ]] && args+=(--dry-run) + printf '%s' "$CI_VERDICT" | bun scripts/ci/release-ci-verdict.ts "${args[@]}" + - name: Stage immutable release objects + if: ${{ !inputs.dry_run }} env: AWS_ACCESS_KEY_ID: ${{ secrets.R2_ACCESS_KEY_ID }} AWS_SECRET_ACCESS_KEY: ${{ secrets.R2_SECRET_ACCESS_KEY }} @@ -515,18 +569,18 @@ jobs: codecast-windows-x64.exe ) prefix="cli/releases/v$RELEASE_VERSION/$SOURCE_COMMIT" - echo "$prefix" > /tmp/cli-release-prefix - cp /tmp/release-expected.json /tmp/cli-release/release.json + echo "$prefix" > $RUNNER_TEMP/cli-release-prefix + cp $RUNNER_TEMP/release-expected.json $RUNNER_TEMP/cli-release/release.json for artifact in "${artifacts[@]}" release.json; do - local_file="/tmp/cli-release/$artifact" + local_file="$RUNNER_TEMP/cli-release/$artifact" expected_sha=$(sha256sum "$local_file" | awk '{print $1}') expected_bytes=$(stat -c %s "$local_file") key="$prefix/$artifact" if metadata=$(aws s3api head-object \ --bucket "$R2_BUCKET" \ --key "$key" \ - --endpoint-url "$R2_ENDPOINT" 2>/tmp/immutable-head-error); then + --endpoint-url "$R2_ENDPOINT" 2>$RUNNER_TEMP/immutable-head-error); then actual_sha=$(jq -r '.Metadata.sha256 // ""' <<<"$metadata") actual_source=$(jq -r '.Metadata["source-sha"] // ""' <<<"$metadata") actual_bytes=$(jq -r '.ContentLength' <<<"$metadata") @@ -538,8 +592,8 @@ jobs: fi continue fi - if ! grep -Eq '(404|Not Found|NoSuchKey)' /tmp/immutable-head-error; then - cat /tmp/immutable-head-error >&2 + if ! grep -Eq '(404|Not Found|NoSuchKey)' $RUNNER_TEMP/immutable-head-error; then + cat $RUNNER_TEMP/immutable-head-error >&2 echo "::error::could not safely determine whether immutable object exists: $key" exit 1 fi @@ -552,6 +606,7 @@ jobs: done - name: Verify immutable public release bytes + if: ${{ !inputs.dry_run }} shell: bash run: | set -euo pipefail @@ -563,14 +618,14 @@ jobs: codecast-windows-x64.exe release.json ) - prefix=$(cat /tmp/cli-release-prefix) - mkdir -p /tmp/cli-public + prefix=$(cat $RUNNER_TEMP/cli-release-prefix) + mkdir -p $RUNNER_TEMP/cli-public # All six at once. A stalled transfer (under 100 kB/s for 30s) is # dropped and retried rather than held to the 15 minute cap, which # one release spent waiting on a single download. verify_one() { local artifact="$1" expected actual - expected=$(sha256sum "/tmp/cli-release/$artifact" | awk '{print $1}') + expected=$(sha256sum "$RUNNER_TEMP/cli-release/$artifact" | awk '{print $1}') for attempt in $(seq 1 10); do if curl -fsSL \ --retry 3 --retry-all-errors \ @@ -578,8 +633,8 @@ jobs: --speed-limit 100000 --speed-time 30 \ -H 'Cache-Control: no-cache' \ "https://dl.codecast.sh/$prefix/$artifact" \ - -o "/tmp/cli-public/$artifact"; then - actual=$(sha256sum "/tmp/cli-public/$artifact" | awk '{print $1}') + -o "$RUNNER_TEMP/cli-public/$artifact"; then + actual=$(sha256sum "$RUNNER_TEMP/cli-public/$artifact" | awk '{print $1}') [[ "$actual" == "$expected" ]] && return 0 fi sleep 15 @@ -596,6 +651,7 @@ jobs: exit "$failed" - name: Revalidate main and atomically publish version commit and tag + if: ${{ !inputs.dry_run }} id: version_commit shell: bash run: | @@ -628,7 +684,7 @@ jobs: blob=$(git show "$SOURCE_COMMIT:packages/cli/package.json" | jq --arg version "$RELEASE_VERSION" '.version = $version' | git hash-object -w --stdin) - export GIT_INDEX_FILE=/tmp/release-index + export GIT_INDEX_FILE=$RUNNER_TEMP/release-index git read-tree "$SOURCE_COMMIT" git update-index --cacheinfo "$mode,$blob,packages/cli/package.json" tree=$(git write-tree) @@ -643,8 +699,8 @@ jobs: refs=() if [[ "$current" == "$PREVIOUS_VERSION" ]]; then jq --arg version "$RELEASE_VERSION" '.version = $version' \ - packages/cli/package.json > /tmp/cli-package.json - mv /tmp/cli-package.json packages/cli/package.json + packages/cli/package.json > $RUNNER_TEMP/cli-package.json + mv $RUNNER_TEMP/cli-package.json packages/cli/package.json git add packages/cli/package.json git commit -m "chore(cli): bump version to $RELEASE_VERSION" refs+=(HEAD:main) @@ -663,6 +719,7 @@ jobs: echo "Release commit: \`$release_sha\`" >> "$GITHUB_STEP_SUMMARY" - name: Create or verify GitHub release + if: ${{ !inputs.dry_run }} id: github_release env: GH_TOKEN: ${{ github.token }} @@ -687,7 +744,7 @@ jobs: if ! gh release view "$tag" >/dev/null 2>&1; then files=() for artifact in "${artifacts[@]}"; do - files+=("/tmp/cli-release/$artifact") + files+=("$RUNNER_TEMP/cli-release/$artifact") done gh release create "$tag" "${files[@]}" \ --draft \ @@ -698,12 +755,12 @@ jobs: echo "created_draft=$created_draft" >> "$GITHUB_OUTPUT" for artifact in "${artifacts[@]}"; do - expected_sha=$(sha256sum "/tmp/cli-release/$artifact" | awk '{print $1}') + expected_sha=$(sha256sum "$RUNNER_TEMP/cli-release/$artifact" | awk '{print $1}') expected_digest="sha256:$expected_sha" asset_name=$(gh release view "$tag" --json assets --jq \ ".assets[] | select(.name == \"$artifact\") | .name") if [[ -z "$asset_name" ]]; then - gh release upload "$tag" "/tmp/cli-release/$artifact" + gh release upload "$tag" "$RUNNER_TEMP/cli-release/$artifact" fi digest="" @@ -714,7 +771,7 @@ jobs: sleep 3 done if [[ -z "$digest" ]]; then - verify_dir="/tmp/cli-github/$artifact" + verify_dir="$RUNNER_TEMP/cli-github/$artifact" mkdir -p "$verify_dir" gh release download "$tag" \ --pattern "$artifact" \ @@ -739,6 +796,7 @@ jobs: fi - name: Verify the release is still a draft + if: ${{ !inputs.dry_run }} # Why: this workflow owns the one draft -> published transition. If the # release it created is already public, something else published it and # the bytes behind it were never checked (ct-49566). @@ -769,6 +827,7 @@ jobs: fi - name: Verify every required release asset is present + if: ${{ !inputs.dry_run }} # Why: publishing a release that is missing a platform points clients at # a download that does not exist (ct-49566). env: @@ -777,6 +836,7 @@ jobs: run: bun scripts/ci/verify-release-required-assets.ts "v$RELEASE_VERSION" - name: Publish the GitHub release + if: ${{ !inputs.dry_run }} # Why: the only draft -> published transition, and it runs after both # checks above, before latest.json points anyone at these bytes. env: @@ -800,6 +860,7 @@ jobs: fi - name: Publish latest.json last + if: ${{ !inputs.dry_run }} env: AWS_ACCESS_KEY_ID: ${{ secrets.R2_ACCESS_KEY_ID }} AWS_SECRET_ACCESS_KEY: ${{ secrets.R2_SECRET_ACCESS_KEY }} @@ -808,8 +869,8 @@ jobs: shell: bash run: | set -euo pipefail - prefix=$(cat /tmp/cli-release-prefix) - aws s3 cp "s3://$R2_BUCKET/latest.json" /tmp/current-r2-latest.json \ + prefix=$(cat $RUNNER_TEMP/cli-release-prefix) + aws s3 cp "s3://$R2_BUCKET/latest.json" $RUNNER_TEMP/current-r2-latest.json \ --endpoint-url "$R2_ENDPOINT" \ --no-progress current_public=$(curl -fsSL \ @@ -817,7 +878,7 @@ jobs: --connect-timeout 20 --max-time 120 \ -H 'Cache-Control: no-cache' \ "https://dl.codecast.sh/latest.json") - current_r2_version=$(jq -r '.version' /tmp/current-r2-latest.json) + current_r2_version=$(jq -r '.version' $RUNNER_TEMP/current-r2-latest.json) current_public_version=$(jq -r '.version' <<<"$current_public") if [[ "$current_public_version" != "$current_r2_version" ]]; then echo "::error::public and authoritative latest.json versions disagree" @@ -825,7 +886,7 @@ jobs: fi current_version="$current_r2_version" if [[ "$current_version" == "$RELEASE_VERSION" ]]; then - released=$(jq -r '.released' /tmp/current-r2-latest.json) + released=$(jq -r '.released' $RUNNER_TEMP/current-r2-latest.json) elif [[ "$current_version" == "$PREVIOUS_VERSION" ]]; then released=$(date -u +%Y-%m-%dT%H:%M:%SZ) else @@ -838,7 +899,7 @@ jobs: --arg released "$released" \ --arg source "$SOURCE_COMMIT" \ --arg prefix "https://dl.codecast.sh/$prefix" \ - --slurpfile expected /tmp/release-expected.json \ + --slurpfile expected $RUNNER_TEMP/release-expected.json \ '{ version: $version, released: $released, @@ -865,14 +926,14 @@ jobs: sha256: $expected[0].artifacts["codecast-windows-x64.exe"].sha256 } } - }' > /tmp/cli-release/latest.json + }' > $RUNNER_TEMP/cli-release/latest.json # The previous signature goes first, so the only gap a client can # see is "unsigned" (refused for one poll, retried on the next), # never a signature over other bytes. The sign step below uploads # the new signature. aws s3 rm "s3://$R2_BUCKET/latest.json.sig" --endpoint-url "$R2_ENDPOINT" --only-show-errors || true - aws s3 cp /tmp/cli-release/latest.json "s3://$R2_BUCKET/latest.json" \ + aws s3 cp $RUNNER_TEMP/cli-release/latest.json "s3://$R2_BUCKET/latest.json" \ --endpoint-url "$R2_ENDPOINT" \ --content-type application/json \ --cache-control "no-cache, no-store, must-revalidate" \ @@ -883,6 +944,7 @@ jobs: # refuse a latest.json that no pinned key signed # (docs/architecture/release-signing.md), so a missing key fails the run. - name: Sign latest.json + if: ${{ !inputs.dry_run }} env: AWS_ACCESS_KEY_ID: ${{ secrets.R2_ACCESS_KEY_ID }} AWS_SECRET_ACCESS_KEY: ${{ secrets.R2_SECRET_ACCESS_KEY }} @@ -898,10 +960,10 @@ jobs: exit 1 fi bun platform/packages/cli-kit/release/sign-manifest.ts \ - --manifest /tmp/cli-release/latest.json \ + --manifest $RUNNER_TEMP/cli-release/latest.json \ --key-id "$RELEASE_MANIFEST_KEY_ID" \ - --out /tmp/cli-release/latest.json.sig - aws s3 cp /tmp/cli-release/latest.json.sig "s3://$R2_BUCKET/latest.json.sig" \ + --out $RUNNER_TEMP/cli-release/latest.json.sig + aws s3 cp $RUNNER_TEMP/cli-release/latest.json.sig "s3://$R2_BUCKET/latest.json.sig" \ --endpoint-url "$R2_ENDPOINT" \ --content-type application/json \ --cache-control "no-cache, no-store, must-revalidate" \ @@ -909,10 +971,11 @@ jobs: --no-progress - name: Verify the exact public manifest and referenced bytes + if: ${{ !inputs.dry_run }} shell: bash run: | set -euo pipefail - expected_manifest_sha=$(sha256sum /tmp/cli-release/latest.json | awk '{print $1}') + expected_manifest_sha=$(sha256sum $RUNNER_TEMP/cli-release/latest.json | awk '{print $1}') matched=false for attempt in $(seq 1 20); do if curl -fsSL \ @@ -920,8 +983,8 @@ jobs: --connect-timeout 20 --max-time 120 \ -H 'Cache-Control: no-cache' \ "https://dl.codecast.sh/latest.json" \ - -o /tmp/cli-public/latest.json; then - actual_manifest_sha=$(sha256sum /tmp/cli-public/latest.json | awk '{print $1}') + -o $RUNNER_TEMP/cli-public/latest.json; then + actual_manifest_sha=$(sha256sum $RUNNER_TEMP/cli-public/latest.json | awk '{print $1}') if [[ "$actual_manifest_sha" == "$expected_manifest_sha" ]]; then matched=true break @@ -936,11 +999,11 @@ jobs: for platform in darwin-arm64 darwin-x64 linux-arm64 linux-x64 windows-x64; do url=$(jq -r --arg platform "$platform" '.binaries[$platform].url' \ - /tmp/cli-public/latest.json) + $RUNNER_TEMP/cli-public/latest.json) expected=$(jq -r --arg platform "$platform" '.binaries[$platform].sha256' \ - /tmp/cli-public/latest.json) + $RUNNER_TEMP/cli-public/latest.json) filename=$(basename "$url") - actual=$(sha256sum "/tmp/cli-public/$filename" | awk '{print $1}') + actual=$(sha256sum "$RUNNER_TEMP/cli-public/$filename" | awk '{print $1}') if [[ "$actual" != "$expected" ]]; then echo "::error::$platform referenced checksum does not match verified public bytes" exit 1 @@ -957,6 +1020,7 @@ jobs: } >> "$GITHUB_STEP_SUMMARY" - name: Refresh legacy stable aliases + if: ${{ !inputs.dry_run }} continue-on-error: true timeout-minutes: 3 env: @@ -974,9 +1038,9 @@ jobs: codecast-linux-x64 codecast-windows-x64.exe ) - prefix=$(cat /tmp/cli-release-prefix) + prefix=$(cat $RUNNER_TEMP/cli-release-prefix) for artifact in "${artifacts[@]}"; do - expected=$(sha256sum "/tmp/cli-release/$artifact" | awk '{print $1}') + expected=$(sha256sum "$RUNNER_TEMP/cli-release/$artifact" | awk '{print $1}') aws s3api copy-object \ --bucket "$R2_BUCKET" \ --key "$artifact" \ diff --git a/.gitignore b/.gitignore index 74c170d8fb..7990612322 100644 --- a/.gitignore +++ b/.gitignore @@ -48,6 +48,10 @@ test-results/ !.codecast/line.toml !.codecast/deploy.toml !.codecast/generated.toml +# What the repo's ci.yml cannot tell codecast's own CI runner (cast ci run) +!.codecast/ci.toml +# A CLI release on codecast's own machines: what its two workflows need on the signing Mac and a Linux host +!.codecast/release/ # The project's own line graph and station prompts (docs/architecture/line-map.md LX5) !.codecast/line/ # How this project's change flow differs from the library's (cast flow edit) diff --git a/AGENTS.md b/AGENTS.md index 7cdaa0d58d..e91aba3599 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -4,6 +4,10 @@ Work directly in the main checkout. Other sessions may have uncommitted work in the tree — scan `git status`/`git diff` before editing shared files and never revert changes you didn't make. +Take a worktree only when parallel edits would collide, and make it with `cast ws acquire `, or `cast spawn --subagent --isolated` for a worker. Either puts it at `.codecast/worktrees/` on branch `codecast/`, copies the gitignored env files `.codecast/workspace.toml` lists, runs `bun install` and gives it its own `PORT_WEB`, which `cast dev` serves on. `cast ws destroy ` removes it once its work has landed. Never make one with a raw `git worktree add` or at a path of your own (`~/src/worktrees`, `~/src/scratch`): such a tree has no env files or ports, and the worktree cleanup never reclaims it. + +The convex package's `.env.local`, copied into every worktree, holds the prod admin key, so any Convex CLI command run there (`convex codegen`, `convex dev`) pushes that tree's whole function set to prod and reverts whatever main has that it lacks. Run none in a worktree: typecheck against the committed `_generated`, and deploy only through `deploy.sh` from a tree that contains origin/main. + ## Vendored platform packages `platform/packages/` is a GENERATED mirror of the shared `@platform/*` packages whose canonical home is `~/src/platform`. Never edit it by hand: change the canonical copy, then run `scripts/vendor-platform.sh` to refresh the mirror (`--check` reports drift). The script also purges bun's `node_modules/.bun/@platform+*` copies and `packages/web/node_modules/.vite` and reinstalls, because bun keeps serving the stale copy and vite the stale module graph otherwise. A running dev server restarts itself when that cache disappears (`plugins/depsCacheGuard.ts`); never delete the cache under a live server without that plugin, or every dep it has not served yet answers 504 "Outdated Optimize Dep". The mirror exists because Railway, the CLI release workflow and the desktop build all run from a fresh clone, so every `@platform` dep must point inside the checkout (`file:../../platform/packages/`), never at `~/src/platform`. The package set is derived from the workspace `package.json` files, so adopting a new platform package is one dep line plus a rerun. A real vendor run also rewrites `platform/package.json`, the mirror's own workspace root generated from the canonical repo's root, `platform/tsconfig.base.json`, the base every mirrored tsconfig extends, and `platform/vendor-manifest.txt`, a content hash per mirrored package and of those root files; commit them with the mirror. CI cannot run `--check`, because a runner has no `~/src/platform`, so the `test-platform` job runs `--check-manifest` instead: it re-hashes the mirror against that manifest and re-reads the dep lines the mirror was generated from, which catches a hand-edited mirror, a package adopted without a rerun, and a dep pointing outside the checkout. The same job runs `scripts/vendor-platform.sh --test`: it installs the mirror once as that workspace, the way the canonical repo installs, so a package's `@platform` peer resolves to its mirrored sibling rather than npm and the shared test tooling sits at the root; then it runs every mirrored package's own `bun test` and names each red one. The repo's own lockfile never sees the mirror's workspace. @@ -96,6 +100,8 @@ Read `docs/brand/facts.md` before claiming anything about codecast in public, an Most people use codecast through the app (web, desktop, phone), not the CLI. User-facing writing describes a feature the way they meet it: the screen, the menu, the button, what it shows and what happens next, with screenshots of the real UI. A CLI command can appear as a small aside for people who script or for agents, never as the spine of a piece, its section headings, or its main illustrations. When a feature has a UI, show the UI; when it is CLI-only today, say so plainly rather than presenting terminal output as the experience. +Blog posts, documentation guides and field-manual chapters are markdown. A page is a row in its section's registry (`blog/posts.ts`, `documentation/guides/guides.ts`, `blog/field-manual/chapters.ts` under `packages/web/app/(marketing)/`) plus `content/.md` beside it; routes, the sitemap, RSS, social cards and llms.txt all follow from the row. `content/SiteMarkdown.tsx` renders every section, and its header lists what the markdown can hold beyond the usual (captioned and wide screenshots, terminals, prompts, small card shots, keycaps, end notes after a final `---`); anything bespoke is a named export of `figures/.tsx` placed with a ```figure fence. `draft: true` keeps a row off the site except on a dev server, and a future date holds it back until the first deploy on or after that day. `lib/__tests__/siteContent.test.ts` fails on a row without a body, a body without a row, a figure that is not exported and an image missing from `public/`. + ## UI conventions **Design from the person's job, then cut everything else. A screen is not a book or a doc.** Every screen, panel and dialog exists for something a person came to do. Before building one, name that job and its one primary action, then judge the result by whether a person who knows nothing of the code can finish the job there, fast, without reading. A screen that only looks organized has failed. @@ -167,6 +173,8 @@ Exactly one window per origin is the elected sync host (Web Locks; `store/syncRe Never use raw `set()` to modify `sessions`, `conversations`, `clientState`, `tasks`, `docs`, or `plans`. +**A draft never outlives its action.** When an action commits, mutative revokes every proxy its draft handed out, and the next read of one throws "Cannot perform 'get' on a proxy that has been revoked". A proxy escapes two ways. It is copied into a synced collection, which is frozen whole, so finalize never swaps it out: build the replacement from the plain table, never by spreading the draft (`liftExcludesForIncoming` in chatSlice, `replayOntoPush` in orgSlice). Or a module-level memo keeps it. A memo keyed by input identity is safe, because a proxy key never matches a committed object again. A memo keyed by value signatures is not: the next caller whose signature matches gets the draft's rows (an action's `computeVisualOrder(this)` filled `placeInboxRows`' memo and the sidebar crashed on it). A selector that memoizes on signatures places over `current(draft)` when handed a draft, as `placeInboxRows` does. + ### Sync All incoming data goes through `syncTable(field, data, opts?)`. Don't create per-table sync functions: register the table in `CLIENT_SYNC_REGISTRY` (`store/clientSyncRegistry.ts`, above). inboxStore's `SYNC_REGISTRY` spreads those defaults and only adds store-internal opts (transforms, merge functions, normalize) per key. diff --git a/bun.lock b/bun.lock index bb4022603e..991bb232e2 100644 --- a/bun.lock +++ b/bun.lock @@ -15,7 +15,7 @@ }, "packages/cli": { "name": "@codecast/cli", - "version": "1.1.296", + "version": "1.1.355", "bin": { "codecast": "./dist/main.js", "cast": "./dist/main.js", @@ -80,7 +80,7 @@ }, "packages/electron": { "name": "@codecast/electron", - "version": "1.1.132", + "version": "1.1.137", "dependencies": { "@platform/desktop": "file:../../platform/packages/desktop", }, @@ -360,6 +360,7 @@ "devDependencies": { "@babel/core": "^7.29.0", "@eslint/js": "^9.19.0", + "@rolldown/plugin-babel": "^0.3.1", "@sentry/vite-plugin": "^5.1.1", "@tailwindcss/typography": "^0.5.19", "@types/babel__core": "^7.20.5", @@ -367,7 +368,7 @@ "@types/react": "^19.0.1", "@types/react-dom": "^19.0.1", "@typescript-eslint/parser": "^8.55.0", - "@vitejs/plugin-react": "^4.5.2", + "@vitejs/plugin-react": "^6.3.0", "autoprefixer": "^10.4.20", "babel-plugin-react-compiler": "1.0.0", "eslint": "^9.19.0", @@ -377,12 +378,12 @@ "fast-check": "^4.10.2", "globals": "^15.14.0", "jsdom": "^30.0.1", - "postcss": "^8.4.49", + "postcss": "^8.5.33", "source-map": "^0.7.4", "tailwindcss": "^3.4.16", "tsx": "^4.21.0", "typescript": "^5.7.2", - "vite": "^6.3.5", + "vite": "^8.3.8", "vite-plugin-pwa": "^1.3.0", "workbox-window": "^7.4.1", }, @@ -1262,6 +1263,8 @@ "@oslojs/encoding": ["@oslojs/encoding@1.1.0", "", {}, "sha512-70wQhgYmndg4GCPxPPxPGevRKqTIJ2Nh4OkiMWmDAVYsTQ+Ta7Sq+rPevXyXGdzr30/qZBnyOalCszoMxlyldQ=="], + "@oxc-project/types": ["@oxc-project/types@0.160.0", "", {}, "sha512-gw4k9syEmnckbOgw2A2FU1TBDdX9hfwV9jEn/uio65pguPzwWiXQS3OIJDMEhv9m06tj9XiEe6RoD0YA+LgreA=="], + "@panva/hkdf": ["@panva/hkdf@1.2.1", "", {}, "sha512-6oclG6Y3PiDFcoyk8srjLfVKyMfVCKJ27JwNPViuXziFpmdz+MZnZN/aKY0JGXgYuO/VghU0jcOAZgWXZ1Dmrw=="], "@peculiar/asn1-android": ["@peculiar/asn1-android@2.11.0", "", { "dependencies": { "@peculiar/asn1-schema": "^2.11.0", "asn1js": "^3.0.10", "tslib": "^2.8.1" } }, "sha512-llW/qjavL+tOxt5i9whUv4wsbsLpUwI6k/DrvKsdA/H7A/TB/6CosMFgvei28fcJ8ncD0c5lig1oBBlo4KGMCw=="], @@ -1436,6 +1439,40 @@ "@resvg/resvg-wasm": ["@resvg/resvg-wasm@2.6.2", "", {}, "sha512-FqALmHI8D4o6lk/LRWDnhw95z5eO+eAa6ORjVg09YRR7BkcM6oPHU9uyC0gtQG5vpFLvgpeU4+zEAz2H8APHNw=="], + "@rolldown/binding-android-arm-eabi": ["@rolldown/binding-android-arm-eabi@1.3.4", "", { "os": "android", "cpu": "arm" }, "sha512-xCW8CkL/ualx/SbYqeG9iK87lJCZGDQ0soE+kaORJ0Bd+pHALyE4qK7BStmEAyYWLEzZ3/biSIpA6/7GDFvzIg=="], + + "@rolldown/binding-android-arm64": ["@rolldown/binding-android-arm64@1.3.4", "", { "os": "android", "cpu": "arm64" }, "sha512-5lifIO+b/prcM9sx/bkPN4w6UEToEfQ3gjhx0+0neuL+dkYskI792CfAq03T51jc8JFcaYXs2hi3l8RjiH/VWQ=="], + + "@rolldown/binding-darwin-arm64": ["@rolldown/binding-darwin-arm64@1.3.4", "", { "os": "darwin", "cpu": "arm64" }, "sha512-RCgxTI4AJQxhVF//BI3ImQOsXTHrF4Eg+f99jBy8WoETA2kSEGFxpnrVmW0leQq/2aBR4R5AC6csmy3rc66e3Q=="], + + "@rolldown/binding-darwin-x64": ["@rolldown/binding-darwin-x64@1.3.4", "", { "os": "darwin", "cpu": "x64" }, "sha512-zNPJVVPUaDEj+L0lImoK3rFv2b+Z5gNijI6DWu/fcD3/1TfmRXKb9ZyxbSN+2AhlctqjbNzUvCsMa+EBhnEM4Q=="], + + "@rolldown/binding-freebsd-x64": ["@rolldown/binding-freebsd-x64@1.3.4", "", { "os": "freebsd", "cpu": "x64" }, "sha512-upP6g7ZIRy5by1RDQ/EphHIdJ5xK0eUD7sUgfZFWJ49s4XdbYsIvIlAPtrFpayR70Hhf9J22lb4Pm8/9FhrZmg=="], + + "@rolldown/binding-linux-arm-gnueabihf": ["@rolldown/binding-linux-arm-gnueabihf@1.3.4", "", { "os": "linux", "cpu": "arm" }, "sha512-SAX5C5+poMLCxu8dkPF6h5yst40rkzs+9Y3cbPn2OFSydmHjAEprrGi64zGgnYyPIVZfdGUFqJ2fJbfbnHI+mA=="], + + "@rolldown/binding-linux-arm64-gnu": ["@rolldown/binding-linux-arm64-gnu@1.3.4", "", { "os": "linux", "cpu": "arm64", "libc": "glibc" }, "sha512-nwHqdlRZS6GWBef3dG5/pMY6RNTBBUjj7s0Da+m6xsFpe7jx6IC46SLZcCu8f46JOfCovZmwnrz51EzGE+7Fyw=="], + + "@rolldown/binding-linux-arm64-musl": ["@rolldown/binding-linux-arm64-musl@1.3.4", "", { "os": "linux", "cpu": "arm64", "libc": "musl" }, "sha512-Gr78X2ur/AgLCkmZgHffk/FerIX8S5zb/eII4bCcvJo0ANzeXhTShahdNbpnY6bpiszIAgIfiuKS9ziziWsamw=="], + + "@rolldown/binding-linux-ppc64-gnu": ["@rolldown/binding-linux-ppc64-gnu@1.3.4", "", { "os": "linux", "cpu": "ppc64", "libc": "glibc" }, "sha512-o9Wcn8nWrsQasaBRYM4d//FwhlBsTJYWkPVlhlt6FwzpwEoovY4IopRZjk5Fq3+ntRuSDORJjF/nA8sFeF2q6w=="], + + "@rolldown/binding-linux-s390x-gnu": ["@rolldown/binding-linux-s390x-gnu@1.3.4", "", { "os": "linux", "cpu": "s390x", "libc": "glibc" }, "sha512-UDWu4jkVcx2kiBKm3Ec//4lVCbeTWj8gmJ9SyLWCdLWtTlyq7fQVeVV/14nXvRtSLErvJ2+yA/Ux5taS31Y17Q=="], + + "@rolldown/binding-linux-x64-gnu": ["@rolldown/binding-linux-x64-gnu@1.3.4", "", { "os": "linux", "cpu": "x64", "libc": "glibc" }, "sha512-W9mGtTa0w4fWh8RLMNPyaEhhcuqUfO07Q4I1bBc4PDMNg7gQSw0yPQNQ3D0qwbkXwxbyL4YrIzc8n6k1vuFExQ=="], + + "@rolldown/binding-linux-x64-musl": ["@rolldown/binding-linux-x64-musl@1.3.4", "", { "os": "linux", "cpu": "x64", "libc": "musl" }, "sha512-8B+ofyQZ7/aCmkqnyMonPr5zKLqMVNczhRGFNtdIuItiwNn8iQWJawMq2E58r7bxD1XEbtRRsULY/eCWwZQ01Q=="], + + "@rolldown/binding-openharmony-arm64": ["@rolldown/binding-openharmony-arm64@1.3.4", "", { "os": "none", "cpu": "arm64" }, "sha512-TlD0FSZaC7o2B4NCe9V5N11ugTnhzTM9ksj4sgRLvrKosDzjEkvlsTX3ehkw4ZlPv8AADimZZTvJGEa16pfXug=="], + + "@rolldown/binding-wasm32-wasi": ["@rolldown/binding-wasm32-wasi@1.3.4", "", { "dependencies": { "@oxc-project/types": "0.160.0" }, "cpu": "none" }, "sha512-jwO8P3o53ygo7b5061B7BeaJ1BGv3BKZ6jroFdw/01qWry7Z+qNBlDvulzbTle5s/A0Fc1FRgsTxrke9DvsSbA=="], + + "@rolldown/binding-win32-arm64-msvc": ["@rolldown/binding-win32-arm64-msvc@1.3.4", "", { "os": "win32", "cpu": "arm64" }, "sha512-8adGMrNtrdzi2WD1ozhYapER59gD8Q/DV6SCKJlyG2HqULPdeQUBvMa33lTsiEYwIqTZUaIU2MmvPp5f1wbtXA=="], + + "@rolldown/binding-win32-x64-msvc": ["@rolldown/binding-win32-x64-msvc@1.3.4", "", { "os": "win32", "cpu": "x64" }, "sha512-rIMjtESdXJCIoOiUTroQ1Y1rjVDZkuUVRUxs3APX2vNv175D7TDWvzdELiIhzGq9cUNUFat+co+PTmPHPqSREg=="], + + "@rolldown/plugin-babel": ["@rolldown/plugin-babel@0.3.2", "", { "dependencies": { "artichokie": "^0.4.5", "picomatch": "^4.0.7" }, "peerDependencies": { "@babel/core": "^7.29.0 || ^8.0.0-rc.1", "@babel/plugin-transform-runtime": "^7.29.0 || ^8.0.0-rc.1", "@babel/runtime": "^7.27.0 || ^8.0.0-rc.1", "rolldown": "^1.0.0-rc.5", "vite": "^8.0.0" }, "optionalPeers": ["@babel/plugin-transform-runtime", "@babel/runtime", "vite"] }, "sha512-nIv2+a7docQQnftHn6WD5cYXQrYBt7ZrbBXq46eGwX4xndGMgvQ00Keb9DUo/g9dUZjZIpkgsi578XdkqJd9gg=="], + "@rolldown/pluginutils": ["@rolldown/pluginutils@1.0.0-beta.27", "", {}, "sha512-+d0F4MKMCbeVUJwG96uQ4SgAznZNSq93I3V+9NHA4OpvqG8mRCpGdKmK8l/dl02h2CCDHwW2FqilnTyDcAnqjA=="], "@rollup/plugin-babel": ["@rollup/plugin-babel@6.1.0", "", { "dependencies": { "@babel/helper-module-imports": "^7.18.6", "@rollup/pluginutils": "^5.0.1" }, "peerDependencies": { "@babel/core": "^7.0.0", "@types/babel__core": "^7.1.9", "rollup": "^1.20.0||^2.0.0||^3.0.0||^4.0.0" }, "optionalPeers": ["@types/babel__core", "rollup"] }, "sha512-dFZNuFD2YRcoomP4oYf+DvQNSUA9ih+A3vUqopQx5EdtPGo3WBnQcI/S8pwpz91UsGfL0HsMSOlaMld8HrbubA=="], @@ -1972,6 +2009,8 @@ "arraybuffer.prototype.slice": ["arraybuffer.prototype.slice@1.0.4", "", { "dependencies": { "array-buffer-byte-length": "^1.0.1", "call-bind": "^1.0.8", "define-properties": "^1.2.1", "es-abstract": "^1.23.5", "es-errors": "^1.3.0", "get-intrinsic": "^1.2.6", "is-array-buffer": "^3.0.4" } }, "sha512-BNoCY6SXXPQ7gF2opIP4GBE+Xw7U+pHMYKuzjgCN3GwiaIR09UUeKfheyIry77QtrCBlC0KK0q5/TER/tYh3PQ=="], + "artichokie": ["artichokie@0.4.5", "", {}, "sha512-ma9643oYgSgA6CeDvKIU0zxL1eKOkbgH8/v83xFpFYB2VOPFoEmmg1iC+ooHFjLIJ3qdtfwPbEKpIW3/YxPovg=="], + "asap": ["asap@2.0.6", "", {}, "sha512-BSHWgDSAiKs50o2Re8ppvp3seVHXSRM44cdSsT9FfNEUUZLOGWVCsiWaRPWM1Znn+mqZ1OfVZ3z3DWEzSp7hRA=="], "asn1js": ["asn1js@3.1.0", "", { "dependencies": { "pvtsutils": "^1.3.6", "pvutils": "^1.2.0", "tslib": "^2.8.1" } }, "sha512-HWYi1THkOqguCiO+vwj09ZkQFD2kKEsejYHAYCtX0D80WVdoDnvRc9IukXX/jeb0T9NRWJnRtqwdbHltnFjwXA=="], @@ -2010,7 +2049,7 @@ "babel-plugin-polyfill-corejs2": ["babel-plugin-polyfill-corejs2@0.4.17", "", { "dependencies": { "@babel/compat-data": "^7.28.6", "@babel/helper-define-polyfill-provider": "^0.6.8", "semver": "^6.3.1" }, "peerDependencies": { "@babel/core": "^7.4.0 || ^8.0.0-0 <8.0.0" } }, "sha512-aTyf30K/rqAsNwN76zYrdtx8obu0E4KoUME29B1xj+B3WxgvWkp943vYQ+z8Mv3lw9xHXMHpvSPOBxzAkIa94w=="], - "babel-plugin-polyfill-corejs3": ["babel-plugin-polyfill-corejs3@0.14.2", "", { "dependencies": { "@babel/helper-define-polyfill-provider": "^0.6.8", "core-js-compat": "^3.48.0" }, "peerDependencies": { "@babel/core": "^7.4.0 || ^8.0.0-0 <8.0.0" } }, "sha512-coWpDLJ410R781Npmn/SIBZEsAetR4xVi0SxLMXPaMO4lSf1MwnkGYMtkFxew0Dn8B3/CpbpYxN0JCgg8mn67g=="], + "babel-plugin-polyfill-corejs3": ["babel-plugin-polyfill-corejs3@0.13.0", "", { "dependencies": { "@babel/helper-define-polyfill-provider": "^0.6.5", "core-js-compat": "^3.43.0" }, "peerDependencies": { "@babel/core": "^7.4.0 || ^8.0.0-0 <8.0.0" } }, "sha512-U+GNwMdSFgzVmfhNm8GJUX88AadB3uo9KpJqS3FaqNIPKgySuvMb+bHPsOmmuWyIcuqZj/pzt1RUIUZns4y2+A=="], "babel-plugin-polyfill-regenerator": ["babel-plugin-polyfill-regenerator@0.6.8", "", { "dependencies": { "@babel/helper-define-polyfill-provider": "^0.6.8" }, "peerDependencies": { "@babel/core": "^7.4.0 || ^8.0.0-0 <8.0.0" } }, "sha512-M762rNHfSF1EV3SLtnCJXFoQbbIIz0OyRwnCmV0KPC7qosSfCO0QLTSuJX3ayAebubhE6oYBAYPrBA5ljowaZg=="], @@ -3414,6 +3453,8 @@ "nanoid": ["nanoid@5.1.9", "", { "bin": { "nanoid": "bin/nanoid.js" } }, "sha512-ZUvP7KeBLe3OZ1ypw6dI/TzYJuvHP77IM4Ry73waSQTLn8/g8rpdjfyVAh7t1/+FjBtG4lCP42MEbDxOsRpBMw=="], + "napi-windows-process-start-time": ["napi-windows-process-start-time@0.1.0", "", { "os": "win32", "cpu": [ "x64", "arm64", ] }, "sha512-zHxhzKsIFu3elch3eFw69WEUGc79DFhbc3nD/WEOzWL/pFFLZRW13EHnuO0c+0YjncE5uCaS9ICHxOBXkb6vPw=="], + "natural-compare": ["natural-compare@1.4.0", "", {}, "sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw=="], "negotiator": ["negotiator@0.6.3", "", {}, "sha512-+EUsqGPLsM+j/zdChZjsnX51g4XrHFOIXwfnCVPGlQk/k5giakcKsuxCObBRu6DSm9opw/O6slWbJdghQM4bBg=="], @@ -3586,7 +3627,7 @@ "possible-typed-array-names": ["possible-typed-array-names@1.1.0", "", {}, "sha512-/+5VFTchJDoVj3bhoqi6UeymcD00DAwb1nJwamzPvHEszJ4FpF6SNNbUbOS8yI56qHzdV8eK0qEfOSiodkTdxg=="], - "postcss": ["postcss@8.5.12", "", { "dependencies": { "nanoid": "^3.3.11", "picocolors": "^1.1.1", "source-map-js": "^1.2.1" } }, "sha512-W62t/Se6rA0Az3DfCL0AqJwXuKwBeYg6nOaIgzP+xZ7N5BFCI7DYi1qs6ygUYT6rvfi6t9k65UMLJC+PHZpDAA=="], + "postcss": ["postcss@8.5.34", "", { "dependencies": { "nanoid": "^3.3.20", "picocolors": "^1.1.1", "source-map-js": "^1.2.4" } }, "sha512-P1Qzj0XXZjMda74C7qiVnBG90UKNbyNUAOeQRBW8X63RsIMV57gevRqjnkELdwtZ/S2/uQFksJhmwuN8xShLPw=="], "postcss-import": ["postcss-import@15.1.0", "", { "dependencies": { "postcss-value-parser": "^4.0.0", "read-cache": "^1.0.0", "resolve": "^1.1.7" }, "peerDependencies": { "postcss": "^8.0.0" } }, "sha512-hpr+J05B2FVYUAXHeK1YyI267J/dDDhMU6B6civm8hSY1jYJnBXxzKDKDswzJmtLHryrjhnDjqqp/49t8FALew=="], @@ -3854,6 +3895,8 @@ "robust-predicates": ["robust-predicates@3.0.3", "", {}, "sha512-NS3levdsRIUOmiJ8FZWCP7LG3QpJyrs/TE0Zpf1yvZu8cAJJ6QMW92H1c7kWpdIHo8RvmLxN/o2JXTKHp74lUA=="], + "rolldown": ["rolldown@1.3.4", "", { "dependencies": { "@oxc-project/types": "=0.160.0", "@rolldown/pluginutils": "^1.0.0" }, "optionalDependencies": { "@rolldown/binding-android-arm-eabi": "1.3.4", "@rolldown/binding-android-arm64": "1.3.4", "@rolldown/binding-darwin-arm64": "1.3.4", "@rolldown/binding-darwin-x64": "1.3.4", "@rolldown/binding-freebsd-x64": "1.3.4", "@rolldown/binding-linux-arm-gnueabihf": "1.3.4", "@rolldown/binding-linux-arm64-gnu": "1.3.4", "@rolldown/binding-linux-arm64-musl": "1.3.4", "@rolldown/binding-linux-ppc64-gnu": "1.3.4", "@rolldown/binding-linux-s390x-gnu": "1.3.4", "@rolldown/binding-linux-x64-gnu": "1.3.4", "@rolldown/binding-linux-x64-musl": "1.3.4", "@rolldown/binding-openharmony-arm64": "1.3.4", "@rolldown/binding-wasm32-wasi": "1.3.4", "@rolldown/binding-win32-arm64-msvc": "1.3.4", "@rolldown/binding-win32-x64-msvc": "1.3.4" }, "bin": { "rolldown": "./bin/cli.mjs" } }, "sha512-p2rq4bfBmF0M6yaR8+A89fbkBQynZI2fxUW4G07eq9kpctAkpo7q5BZ4X4Mo4XZ7HHROu33cX9PeopUFN6u+2Q=="], + "rollup": ["rollup@4.60.2", "", { "dependencies": { "@types/estree": "1.0.8" }, "optionalDependencies": { "@rollup/rollup-android-arm-eabi": "4.60.2", "@rollup/rollup-android-arm64": "4.60.2", "@rollup/rollup-darwin-arm64": "4.60.2", "@rollup/rollup-darwin-x64": "4.60.2", "@rollup/rollup-freebsd-arm64": "4.60.2", "@rollup/rollup-freebsd-x64": "4.60.2", "@rollup/rollup-linux-arm-gnueabihf": "4.60.2", "@rollup/rollup-linux-arm-musleabihf": "4.60.2", "@rollup/rollup-linux-arm64-gnu": "4.60.2", "@rollup/rollup-linux-arm64-musl": "4.60.2", "@rollup/rollup-linux-loong64-gnu": "4.60.2", "@rollup/rollup-linux-loong64-musl": "4.60.2", "@rollup/rollup-linux-ppc64-gnu": "4.60.2", "@rollup/rollup-linux-ppc64-musl": "4.60.2", "@rollup/rollup-linux-riscv64-gnu": "4.60.2", "@rollup/rollup-linux-riscv64-musl": "4.60.2", "@rollup/rollup-linux-s390x-gnu": "4.60.2", "@rollup/rollup-linux-x64-gnu": "4.60.2", "@rollup/rollup-linux-x64-musl": "4.60.2", "@rollup/rollup-openbsd-x64": "4.60.2", "@rollup/rollup-openharmony-arm64": "4.60.2", "@rollup/rollup-win32-arm64-msvc": "4.60.2", "@rollup/rollup-win32-ia32-msvc": "4.60.2", "@rollup/rollup-win32-x64-gnu": "4.60.2", "@rollup/rollup-win32-x64-msvc": "4.60.2", "fsevents": "~2.3.2" }, "bin": { "rollup": "dist/bin/rollup" } }, "sha512-J9qZyW++QK/09NyN/zeO0dG/1GdGfyp9lV8ajHnRVLfo/uFsbji5mHnDgn/qYdUHyCkM2N+8VyspgZclfAh0eQ=="], "rope-sequence": ["rope-sequence@1.3.4", "", {}, "sha512-UT5EDe2cu2E/6O4igUr5PSFs23nvvukicWHx6GnOPlHAiiYbzNuCRQCuiUdHJQcqKalLKlrYJnjY0ySGsXNQXQ=="], @@ -4574,8 +4617,6 @@ "@babel/plugin-transform-reserved-words/@babel/helper-plugin-utils": ["@babel/helper-plugin-utils@7.29.7", "", {}, "sha512-G7sHYigPY17oO5SYWnfD/0MTBwVR781S/JI643e/JhUYgVgWE/61SoW3NH9KWUKyKq5LVh3npif99Wkt6j86Jw=="], - "@babel/plugin-transform-runtime/babel-plugin-polyfill-corejs3": ["babel-plugin-polyfill-corejs3@0.13.0", "", { "dependencies": { "@babel/helper-define-polyfill-provider": "^0.6.5", "core-js-compat": "^3.43.0" }, "peerDependencies": { "@babel/core": "^7.4.0 || ^8.0.0-0 <8.0.0" } }, "sha512-U+GNwMdSFgzVmfhNm8GJUX88AadB3uo9KpJqS3FaqNIPKgySuvMb+bHPsOmmuWyIcuqZj/pzt1RUIUZns4y2+A=="], - "@babel/plugin-transform-spread/@babel/helper-plugin-utils": ["@babel/helper-plugin-utils@7.29.7", "", {}, "sha512-G7sHYigPY17oO5SYWnfD/0MTBwVR781S/JI643e/JhUYgVgWE/61SoW3NH9KWUKyKq5LVh3npif99Wkt6j86Jw=="], "@babel/plugin-transform-spread/@babel/helper-skip-transparent-expression-wrappers": ["@babel/helper-skip-transparent-expression-wrappers@7.29.7", "", { "dependencies": { "@babel/traverse": "^7.29.7", "@babel/types": "^7.29.7" } }, "sha512-brcMGQaVzIeUb+6/bs1Av0f8YuNNjKY2JyvfRCsFuFsdKccEQ5Ges2y74D74NZ1Rz8lKJ9ksJkfqwQFJ/iNEyQ=="], @@ -4632,6 +4673,8 @@ "@babel/preset-env/@babel/plugin-transform-unicode-regex": ["@babel/plugin-transform-unicode-regex@7.29.7", "", { "dependencies": { "@babel/helper-create-regexp-features-plugin": "^7.29.7", "@babel/helper-plugin-utils": "^7.29.7" }, "peerDependencies": { "@babel/core": "^7.0.0-0" } }, "sha512-7D/x/23/d/3VqZ0QA+LGbZMlGwZjztBygSWWWsfTPoQ1oQ6Q1P6Mr3d0kk42XabyUVw+fha3LqdRsFqeKqvCyA=="], + "@babel/preset-env/babel-plugin-polyfill-corejs3": ["babel-plugin-polyfill-corejs3@0.14.2", "", { "dependencies": { "@babel/helper-define-polyfill-provider": "^0.6.8", "core-js-compat": "^3.48.0" }, "peerDependencies": { "@babel/core": "^7.4.0 || ^8.0.0-0 <8.0.0" } }, "sha512-coWpDLJ410R781Npmn/SIBZEsAetR4xVi0SxLMXPaMO4lSf1MwnkGYMtkFxew0Dn8B3/CpbpYxN0JCgg8mn67g=="], + "@babel/preset-modules/@babel/helper-plugin-utils": ["@babel/helper-plugin-utils@7.29.7", "", {}, "sha512-G7sHYigPY17oO5SYWnfD/0MTBwVR781S/JI643e/JhUYgVgWE/61SoW3NH9KWUKyKq5LVh3npif99Wkt6j86Jw=="], "@bacons/apple-targets/glob": ["glob@10.5.0", "", { "dependencies": { "foreground-child": "^3.1.0", "jackspeak": "^3.1.2", "minimatch": "^9.0.4", "minipass": "^7.1.2", "package-json-from-dist": "^1.0.0", "path-scurry": "^1.11.1" }, "bin": { "glob": "dist/esm/bin.mjs" } }, "sha512-DfXN8DfhJ7NH3Oe7cFmu3NCu1wKbkReJ8TorzSAFbSKrlNaQSKfIzqYqVY8zlbs2NLBbWpRiU52GX2PbaBVNkg=="], @@ -4708,6 +4751,10 @@ "@codecast/web/@platform/update-prompt": ["@platform/update-prompt@file:platform/packages/update-prompt", { "devDependencies": { "@types/node": "^22.0.0", "typescript": "^5.7.2" }, "bin": { "platform-release-prompt": "src/cli.ts" } }], + "@codecast/web/@vitejs/plugin-react": ["@vitejs/plugin-react@6.3.0", "", { "dependencies": { "@rolldown/pluginutils": "^1.0.1" }, "peerDependencies": { "@rolldown/plugin-babel": "^0.1.7 || ^0.2.0 || ^0.3.0", "babel-plugin-react-compiler": "^1.0.0", "oxc-transform-react": ">=0.152.0 <0.157.0", "vite": "^8.0.0" }, "optionalPeers": ["@rolldown/plugin-babel", "babel-plugin-react-compiler", "oxc-transform-react"] }, "sha512-H9E955aVvD2F4zNHCw4eIZbIfF6xKldlh7MNu+hSU7xwQzh65lI/N+CJWqmfhi0PEjDXIt/H7T7J/4wU63KJiw=="], + + "@codecast/web/vite": ["vite@8.4.0", "", { "dependencies": { "lightningcss": "^1.33.0", "picomatch": "^4.0.7", "postcss": "^8.5.33", "rolldown": "~1.3.2", "tinyglobby": "^0.2.17" }, "optionalDependencies": { "fsevents": "~2.3.3", "napi-windows-process-start-time": "^0.1.0" }, "peerDependencies": { "@types/node": "^20.19.0 || >=22.12.0", "@vitejs/devtools": "^0.7.1 || ^0.8.0", "esbuild": "^0.27.0 || ^0.28.0", "jiti": ">=1.21.0", "less": "^4.0.0", "sass": "^1.70.0", "sass-embedded": "^1.70.0", "stylus": ">=0.54.8", "sugarss": "^5.0.0", "terser": "^5.16.0", "tsx": "^4.8.1", "yaml": "^2.4.2" }, "optionalPeers": ["@types/node", "@vitejs/devtools", "esbuild", "jiti", "less", "sass", "sass-embedded", "stylus", "sugarss", "terser", "tsx", "yaml"], "bin": { "vite": "bin/vite.js" } }, "sha512-X2nUJg+9cutlz3hzqyO6p+WTwk9H257DjwAEf9EQYUFrQbDItmetadi9gYmb+l7VDy4r3VXLUnmLTwuPmzejDw=="], + "@codemirror/lang-javascript/@codemirror/lint": ["@codemirror/lint@6.9.7", "", { "dependencies": { "@codemirror/state": "^6.0.0", "@codemirror/view": "^6.42.0", "crelt": "^1.0.5" } }, "sha512-28/+iWLYxKxsvGYhSYL7zaCZqLz5+FFFDq9tVsvGv9kv8RY4fFAchJ5WX9M3YrrRlTIsECjsXPqeNgnSmNP2dg=="], "@codemirror/lsp-client/marked": ["marked@15.0.12", "", { "bin": { "marked": "bin/marked.js" } }, "sha512-8dD6FusOQSrpv9Z1rdNMdlSgQOIP880DHqnohobOmYLElGEqAL/JvxvuxZO16r4HtjTlfPRDC1hbvxC9dPN2nA=="], @@ -4970,6 +5017,8 @@ "@react-navigation/routers/nanoid": ["nanoid@3.3.11", "", { "bin": { "nanoid": "bin/nanoid.cjs" } }, "sha512-N8SpfPUnUp1bK+PMYW8qSWdl9U+wwNWI4QKxOYDy9JAro3WMX7p2OeVRF9v+347pnakNevPmiHhNmZ2HbFA76w=="], + "@rolldown/plugin-babel/picomatch": ["picomatch@4.0.7", "", {}, "sha512-qcJu88Q2IWqJsDD529JKMdwGm/dvInW4HvQnRwiH9JtihJvzGOscDtHE3x1pBKeUOTysQ8kVmLnJ2kJu7yhcGA=="], + "@rollup/plugin-babel/@babel/helper-module-imports": ["@babel/helper-module-imports@7.29.7", "", { "dependencies": { "@babel/traverse": "^7.29.7", "@babel/types": "^7.29.7" } }, "sha512-ejHwrQQYcm9xnTivShn2IDOlIzInN34AXskvq9QicvCtEzq1Vzclu/tKF8Jq1Cg8JG2GL6/EmjgsCT7lXepE3g=="], "@rollup/plugin-node-resolve/resolve": ["resolve@1.22.12", "", { "dependencies": { "es-errors": "^1.3.0", "is-core-module": "^2.16.1", "path-parse": "^1.0.7", "supports-preserve-symlinks-flag": "^1.0.0" }, "bin": { "resolve": "bin/resolve" } }, "sha512-TyeJ1zif53BPfHootBGwPRYT1RUt6oGWsaQr8UyZW/eAm9bKoijtvruSDEmZHm92CwS9nj7/fWttqPCgzep8CA=="], @@ -5328,7 +5377,9 @@ "plist/@xmldom/xmldom": ["@xmldom/xmldom@0.9.10", "", {}, "sha512-A9gOqLdi6cV4ibazAjcQufGj0B1y/vDqYrcuP6d/6x8P27gRS8643Dj9o1dEKtB6O7fwxb2FgBmJS2mX7gpvdw=="], - "postcss/nanoid": ["nanoid@3.3.11", "", { "bin": { "nanoid": "bin/nanoid.cjs" } }, "sha512-N8SpfPUnUp1bK+PMYW8qSWdl9U+wwNWI4QKxOYDy9JAro3WMX7p2OeVRF9v+347pnakNevPmiHhNmZ2HbFA76w=="], + "postcss/nanoid": ["nanoid@3.3.20", "", { "bin": { "nanoid": "bin/nanoid.cjs" } }, "sha512-uKdg2G3GNCKQn9byYOpxbGqrT2fGO5KRt5J/8b3pok8rT6qxGWF6hxMyJiEYtAf+FVyYuD9hRaDqX5uPFYJ4ZQ=="], + + "postcss/source-map-js": ["source-map-js@1.2.4", "", {}, "sha512-J7ZjMvHd9O1fcT/5V09QWaaSl2BbWx3F6O08spde82Namf9UB0GxRVIPiNbVsdKkoizHiSpTodo3vp2bAy91MA=="], "postcss-import/resolve": ["resolve@1.22.12", "", { "dependencies": { "es-errors": "^1.3.0", "is-core-module": "^2.16.1", "path-parse": "^1.0.7", "supports-preserve-symlinks-flag": "^1.0.0" }, "bin": { "resolve": "bin/resolve" } }, "sha512-TyeJ1zif53BPfHootBGwPRYT1RUt6oGWsaQr8UyZW/eAm9bKoijtvruSDEmZHm92CwS9nj7/fWttqPCgzep8CA=="], @@ -5396,6 +5447,8 @@ "rimraf/glob": ["glob@7.2.3", "", { "dependencies": { "fs.realpath": "^1.0.0", "inflight": "^1.0.4", "inherits": "2", "minimatch": "^3.1.1", "once": "^1.3.0", "path-is-absolute": "^1.0.0" } }, "sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q=="], + "rolldown/@rolldown/pluginutils": ["@rolldown/pluginutils@1.1.1", "", {}, "sha512-glFIJDvLNDtJhT9qrMFWLPbvS+skxgt4L0K8Ei2YtnhPysAJnsI7nyxSJxKj4ADeKX0OLjC4ntRkwpLOoS3rwA=="], + "router/path-to-regexp": ["path-to-regexp@8.4.2", "", {}, "sha512-qRcuIdP69NPm4qbACK+aDogI5CBDMi1jKe0ry5rSQJz8JVLsC7jV8XpiJjGRLLol3N+R5ihGYcrPLTno6pAdBA=="], "rxjs/tslib": ["tslib@2.8.1", "", {}, "sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w=="], @@ -5760,6 +5813,14 @@ "@codecast/web/@platform/evals/happy-dom": ["happy-dom@20.11.1", "", { "dependencies": { "@types/node": ">=20.0.0", "@types/whatwg-mimetype": "^3.0.2", "@types/ws": "^8.18.1", "buffer-image-size": "^0.6.4", "entities": "^7.0.1", "whatwg-mimetype": "^3.0.0", "ws": "^8.21.0" } }, "sha512-XSt8tMzbW9ymE7687xztkO1ckR7qJNQ3LywY9vlYGhGi3zXrGBHuUo2Cl1ztZaICW+1eAGdkLbj6iwVqDT33kg=="], + "@codecast/web/@vitejs/plugin-react/@rolldown/pluginutils": ["@rolldown/pluginutils@1.1.1", "", {}, "sha512-glFIJDvLNDtJhT9qrMFWLPbvS+skxgt4L0K8Ei2YtnhPysAJnsI7nyxSJxKj4ADeKX0OLjC4ntRkwpLOoS3rwA=="], + + "@codecast/web/vite/lightningcss": ["lightningcss@1.33.0", "", { "dependencies": { "detect-libc": "^2.0.3" }, "optionalDependencies": { "lightningcss-android-arm64": "1.33.0", "lightningcss-darwin-arm64": "1.33.0", "lightningcss-darwin-x64": "1.33.0", "lightningcss-freebsd-x64": "1.33.0", "lightningcss-linux-arm-gnueabihf": "1.33.0", "lightningcss-linux-arm64-gnu": "1.33.0", "lightningcss-linux-arm64-musl": "1.33.0", "lightningcss-linux-x64-gnu": "1.33.0", "lightningcss-linux-x64-musl": "1.33.0", "lightningcss-win32-arm64-msvc": "1.33.0", "lightningcss-win32-x64-msvc": "1.33.0" } }, "sha512-WkUDrojuJs0xkgGf2udWxa3yGBRxPtxUkB79i6aCZLRgc7PM8fZe9TosfPDcvEpQZbuFASnHYmRLBLUbmLOIIA=="], + + "@codecast/web/vite/picomatch": ["picomatch@4.0.7", "", {}, "sha512-qcJu88Q2IWqJsDD529JKMdwGm/dvInW4HvQnRwiH9JtihJvzGOscDtHE3x1pBKeUOTysQ8kVmLnJ2kJu7yhcGA=="], + + "@codecast/web/vite/tinyglobby": ["tinyglobby@0.2.17", "", { "dependencies": { "fdir": "^6.5.0", "picomatch": "^4.0.4" } }, "sha512-wXR/dYpcqKmfWpEdZjiKJOwCNFndD0DMnrW/cYjVGttEkBfVgcLFHoNrlj47mjOVic9yyNu65alsgF4NQyTa2g=="], + "@electron/rebuild/ora/cli-cursor": ["cli-cursor@3.1.0", "", { "dependencies": { "restore-cursor": "^3.1.0" } }, "sha512-I/zHAwsKf9FqGoXM4WWRACob9+SNukZTd94DWF57E4toouRulbCxcUh6RKUEOQlYTHJnzkPMySvPNaaSLNfLZw=="], "@electron/rebuild/ora/log-symbols": ["log-symbols@4.1.0", "", { "dependencies": { "chalk": "^4.1.0", "is-unicode-supported": "^0.1.0" } }, "sha512-8XPvpAA8uyhfteu8pIvQxpJZ7SYYdpUivZpGy6sFsBuKRY/7rQGavedeB8aK+Zkyq6upMFVL/9AW6vOYzfRyLg=="], @@ -6838,6 +6899,30 @@ "@codecast/web/@platform/evals/happy-dom/@types/node": ["@types/node@24.13.4", "", { "dependencies": { "undici-types": "~7.18.0" } }, "sha512-YJ7EqCstVTzIr0fMr7qul/977en+pQHrfmuKIo6Zr9i75Be21dr3MovcfvGtyvi2HAUrRerWps5sMO9I7WaxDw=="], + "@codecast/web/vite/lightningcss/lightningcss-android-arm64": ["lightningcss-android-arm64@1.33.0", "", { "os": "android", "cpu": "arm64" }, "sha512-gEpRTalKdosp4Bb8qWtc2iOgE5SeIHlpS1up9bFq2wAyYhl1UdTObYiHe98zEM9SQvSoqQZ1IQD0JNpg3Ml5pg=="], + + "@codecast/web/vite/lightningcss/lightningcss-darwin-arm64": ["lightningcss-darwin-arm64@1.33.0", "", { "os": "darwin", "cpu": "arm64" }, "sha512-Sciaz8eenNTKn9b3t7+xr0ipTp9YxKQY4npwQ3mrRuL0BAVHBLyZxofhaKBAVtzmtRZ/zTyo0/to4B1uWG/Djg=="], + + "@codecast/web/vite/lightningcss/lightningcss-darwin-x64": ["lightningcss-darwin-x64@1.33.0", "", { "os": "darwin", "cpu": "x64" }, "sha512-Z5UPAxzrjlWNNyGy6i65cJzzvgJ5D3T6wMvs+gWpY9d7qRhANrxqAp6LhxIgZhWEw18RfJTGcRxjuLIBr+m8XQ=="], + + "@codecast/web/vite/lightningcss/lightningcss-freebsd-x64": ["lightningcss-freebsd-x64@1.33.0", "", { "os": "freebsd", "cpu": "x64" }, "sha512-QQM/Ti/hQajJwCY+RiWuCZ9sdtI/XQk7nDK5vC8kkdwixezOlDgvDx7+RT+QjK6FcFT4MpsuoBnHIo/O3StRRg=="], + + "@codecast/web/vite/lightningcss/lightningcss-linux-arm-gnueabihf": ["lightningcss-linux-arm-gnueabihf@1.33.0", "", { "os": "linux", "cpu": "arm" }, "sha512-N7FVBe6iS24MlM6R/4RBTxGhQheZGs7tiQ9U32UtF75NzP5Q7xWPRqLBCKxlRQRk3rY1jCIPLzx7WzOhuUIRLQ=="], + + "@codecast/web/vite/lightningcss/lightningcss-linux-arm64-gnu": ["lightningcss-linux-arm64-gnu@1.33.0", "", { "os": "linux", "cpu": "arm64", "libc": "glibc" }, "sha512-j2v/itmy4HlNxlc6voKXYgBqNi0Ng2LShg4z7GufpEgs05P+2suBVyi9I6YHq5uoVFx9ETin3eCEhLVyXGQnKg=="], + + "@codecast/web/vite/lightningcss/lightningcss-linux-arm64-musl": ["lightningcss-linux-arm64-musl@1.33.0", "", { "os": "linux", "cpu": "arm64", "libc": "musl" }, "sha512-yiO5ROMuYQgXbC60yjZU5CYSFZGKXL0HFATXt9mHJn1+zW55oCtMI9NfcVhYLMFDL7gV7oBPon/EmMMGg2OvtQ=="], + + "@codecast/web/vite/lightningcss/lightningcss-linux-x64-gnu": ["lightningcss-linux-x64-gnu@1.33.0", "", { "os": "linux", "cpu": "x64", "libc": "glibc" }, "sha512-ar+Ju7LmcN0Jo4FpL4hpFybwNG9/3A/Br5KW2n2jyODg3MEZXaDYADdemoNS+BDNfMgKvylJLj4S5tyRActuAg=="], + + "@codecast/web/vite/lightningcss/lightningcss-linux-x64-musl": ["lightningcss-linux-x64-musl@1.33.0", "", { "os": "linux", "cpu": "x64", "libc": "musl" }, "sha512-RYiYbkokw0trfKqqzfF55lginwEPrD3OJDfTuJzFs1MK6iFnDenaz1fqLLtX4ITG3OktJQXOeTaw1awrBAlZPw=="], + + "@codecast/web/vite/lightningcss/lightningcss-win32-arm64-msvc": ["lightningcss-win32-arm64-msvc@1.33.0", "", { "os": "win32", "cpu": "arm64" }, "sha512-1K+MPfLSFVpphzpdbfkhlWk6wBrTObBzS2T6db10PNOZgR9GoVsAWzwNyuhUYYbTp23j+4RrncfujZ4uAzXvwA=="], + + "@codecast/web/vite/lightningcss/lightningcss-win32-x64-msvc": ["lightningcss-win32-x64-msvc@1.33.0", "", { "os": "win32", "cpu": "x64" }, "sha512-OlEICDx/Xl0FqSp4bry8zFnCvGpig3Gl4gCquvYwHuqJKEC1+n9NgDniFvqHGmMv1ZkqDJrDqKKSykTDX+ehuA=="], + + "@codecast/web/vite/tinyglobby/picomatch": ["picomatch@4.0.4", "", {}, "sha512-QP88BAKvMam/3NxH6vj2o21R6MjxZUAd6nlwAS/pnGvN9IVLocLHxGYIzFhg6fUQ+5th6P4dv4eW9jX3DSIj7A=="], + "@electron/rebuild/ora/cli-cursor/restore-cursor": ["restore-cursor@3.1.0", "", { "dependencies": { "onetime": "^5.1.0", "signal-exit": "^3.0.2" } }, "sha512-l+sSefzHpj5qimhFSE5a8nufZYAM3sBSVMAPtYkmC+4EH2anSGaEMXSD0izRQbu9nfyQ9y5JrVmp7E8oZrUjvA=="], "@electron/rebuild/tar/minizlib/minipass": ["minipass@3.3.6", "", { "dependencies": { "yallist": "^4.0.0" } }, "sha512-DxiNidxSEK+tHG6zOIklvNOwm3hvCrbUrdtzY74U6HKTJxvIDfOUL5W5P2Ghd3DTkhhKPYGqeNUIh5qcM4YBfw=="], diff --git a/docs/architecture/agent-comms.md b/docs/architecture/agent-comms.md index 0f97ccce5c..28209e6980 100644 --- a/docs/architecture/agent-comms.md +++ b/docs/architecture/agent-comms.md @@ -50,7 +50,7 @@ Live huddle transcripts reach fed sessions through `transcripts.deliverRoutes`. `packages/evals/org-comms/monitor.py` reruns the measurement: 1. Exports from prod. -2. Places each sender against its recipient. A session's lead is its parent, else the session that spawned it (`spawned_by_conversation_id`: a plain `cast spawn`, or a Line run handing a station its brief), and the recipient's own row settles its lead even when that session is outside the export. Codecast's own notices (a reporting line moved, a send still queued) are counted apart and left out of both the huddle and the agent numbers. A workflow node's session records no parent and no short id, so its lead is the session that ran the workflow (`workflow_runs.spawner_conversation_id`) and its short id is its id's first 7 characters. A delivered row names its sender in full (`from_conversation_id`), which settles the sender exactly; only when that session is outside the export does a short id shared by several sessions resolve to the one closest to the recipient's line. Sessions older than the export are looked up by id, and role anchors come from each team's org listing. +2. Places each sender against its recipient. A session's lead is its parent, else the session that spawned it (`spawned_by_conversation_id`: a plain `cast spawn`, or a Line run handing a station its brief), and the recipient's own row settles its lead even when that session is outside the export. Codecast's own notices (a reporting line moved, a send still queued) are counted apart and left out of both the huddle and the agent numbers. A workflow node's session records no parent and no short id, so its lead is the session that ran the workflow (`workflow_runs.spawner_conversation_id`) and its short id is its id's first 7 characters. A delivered row names its sender in full (`from_conversation_id`), which settles the sender exactly; only when that session is outside the export does a short id shared by several sessions resolve to the one closest to the recipient's line. One export holds only the newest 100,000 sessions (about two weeks by late November), so every export is merged into `$CODECAST_EVALS_HOME/org-comms/lineage.jsonl`, which keeps each session's row once seen. Sessions in neither are looked up by id, and role anchors come from each team's org listing. A session looked up by id has no lead on record, so a pair whose line runs into one is unplaced, never a peer. 3. Reads a random sample inside the recipients' transcripts, drawn only from sessions the person owns: a message they sent into a teammate's session is counted and never opened. A huddle chunk is unnamed talk only when its header says nobody named the agent; a voice handoff, a chat line and the attach briefing are asks or one-offs. 4. Labels the sample through `prompt-dry-run.ts`. 5. Writes `report.json` and `report.md` under `$CODECAST_EVALS_HOME/org-comms/runs//`, set against `baseline.json` (the founding study) and every earlier run. @@ -66,7 +66,7 @@ Every run uses a saved account profile (`--account`), so a machine login switch | Metric | Baseline | Means trouble when | |---|---|---| | Unnamed huddle chunks a week | about 255 | it does not fall after AC3 | -| Unnamed chunks inside the delivery gap | 92% (2026-10-13, before the fix) | it is not near zero: something delivers around the gap. The monitor reads the gap from `transcripts.ts` | +| Unnamed chunks inside the delivery gap | 92% (2026-10-13, before the fix) | it is not near zero: something delivers around the gap. The monitor reads the gap from `convex/lib/sessionDelivery.ts` | | Huddle noise | 73% (27 to 33% on Nov 3 at the 1 minute gap) | it stays high: the gap is too short | | Agent-to-agent noise | 7% | it rises: chatter is coming back | | Could have been read, not urgent, changed nothing | 22% | it rises: the "write it down" half is not holding | @@ -196,3 +196,15 @@ First week under the policy and the huddle gap (700 messages, 109 agent to agent - **Guidance split:** 72 senders saw the guidance, 2 did not and 43 are unknown, so there is still no comparison. - **Next run:** relayed machine comments once ct-100734 ships (count `` relays by sender kind); idle with asked-for results left out, which should fall back toward 6% with them; exact repeats. +### 2026-12-01 + +5,605 messages over Nov 24 to Dec 1 (9,172 the week before), 119 agent to agent cases and 1 huddle case read. + +- **Peer share read 26.7% (4.5%). It was the monitor. Fixed.** The conversation export now reaches back only to Nov 16, so the sharded engine release area (jx70wn8, jx7ac8v, jx7fc5y and the RC workers they spawned before Nov 16) fell out of it. The by-id lookup set every such session's parent to none, so its own workers' reports, about 1,300 messages, were counted as peers, and the area read as a new hub (jx70wn8, 530 messages from 72 senders). The monitor now keeps a lineage cache that every export feeds, and a pair whose line reaches a session with no lead on record is unplaced. Peer share is 3.4%, and 1,380 messages (25%) are unplaced, nearly all in that area. They should fall as the cache fills; sessions that predate Nov 16 stay unplaced. Hub share with own workers' reports left out read 42.1%, and most of it is the same area. +- **Agent noise rose to 8.4% (10 of 119; 3.4% last week, not separated). Seven of the ten are one Line notice. Fixed in the runner.** When a Line run returns to the session that presented a decision, the runner sends it "The run is back at this station, with you. Your brief as it stands now:" and the whole station brief again, about 250 lines. The reason it came back (the founder answered, the pull request could not be opened, the change is on main, arm the deploy check) is the `$sent_back` line in the middle of that brief. Recipients and the labeller read the message as the same brief re-sent: it is 7 of the 10 noise cases and 7 of the 9 idle ones, and 30 of the 54 exact repeats (the identical copies are retries that failed the same way, such as two GitHub 502s). `presenterReturnBody` (`packages/cli/src/workflow/runner.ts`) now leads with "What brought it back: …", with a check in `presenterReturn.test.ts`. It reaches the Line hosts with the next CLI release. +- **The rest of the table:** idle with asked-for results left out 8.4% (10.3%), changed recipient 70%, out-of-line direction followed 75% (18 of 24). The 24 are flows sending review or CI results back to the session that ran them, landing and deploy asks to the Release Captain, a lead assigning work, and rulings inside the RC area. There is no peer steering and no wording change. Huddle: 68 unnamed chunks, 1 of them (1.5%) inside the gap, 0 of 1 read was noise. +- **Machine notices as the founder's words (ct-100734) are gone.** It shipped in CLI v1.1.273, and the Line hosts updated on Nov 25. Relayed task comments fell from 295 to 35. Machine notices signed as Ashot fell from 7 in the 22 hours before the hosts updated to 2 in the six days after. +- **DM cap:** no agent reached 30 lines in a DM. Ten runs, across 9 DMs and 8 sessions, reached the 5-root limit, which in a DM counts every top-level line, so it binds first. In 7 of them no person had ever written in the DM. In the other 3 the person's last line was 12, 20 and 164 hours before, so none was within the hour. +- **Saw-guidance split:** no injection record carries `org`. The CLI change that writes it is still uncommitted in a worktree on the Linux cloud host, with the question to Ashot already asked by the Agent Comms lead. +- **Exact repeats into the same session: 54 (75).** Line runs sent 32 and flow stations 21 (the role-routine count was a misfile, since Line run sessions carry a role id); one sender was unidentified. The top three texts: "The run is back at this station" (30, above), "The change this session sent to main came back" (17 across 8 tasks) and "CI and an independent reviewer read this session's change" (4). +- **Next run:** whether noise and idle fall once the CLI release carrying the re-hand change reaches the Line hosts; unplaced messages as the lineage cache fills; the RC area's hub once it is placed. diff --git a/docs/line/principles.md b/docs/line/principles.md index bbd71bbd50..68c9dcca9e 100644 --- a/docs/line/principles.md +++ b/docs/line/principles.md @@ -14,7 +14,7 @@ Server data a surface renders lives in the store, and the surface reads the stor Why: copies drift the moment two feeders or two readers disagree about which one is current, and each drift then needs its own reconciler. A surface that waits on the network when the answer is already local feels slow in a product built to feel instant. -Evidence: 17 corrections across 17 sessions [PR-code-1]: codecast/6faa44cb, codecast/jx74z5d, codecast/c26c9845, codecast/jx75vha, vello/d4dab4d0, codecast/b795b31f, codecast/2f965f0d, codecast/ca8c862a, codecast/116ee3ec, codecast/62a49be8, codecast/7d29c234, codecast/733dcc00, codecast/f631eb0e, codecast/a59be96d, codecast/f923f784, codecast/ce8e5c04, codecast/65510658. Recorded in CLAUDE.md (Store: Local-first is the law). +Evidence: 20 corrections across 20 sessions [PR-code-1]: codecast/6faa44cb, codecast/jx74z5d, codecast/c26c9845, codecast/jx75vha, vello/d4dab4d0, codecast/b795b31f, codecast/2f965f0d, codecast/ca8c862a, codecast/116ee3ec, codecast/62a49be8, codecast/7d29c234, codecast/733dcc00, codecast/f631eb0e, codecast/a59be96d, codecast/f923f784, codecast/ce8e5c04, codecast/65510658, codecast/bbb99905, codecast/9b78f630, codecast/073f2233. Recorded in CLAUDE.md (Store: Local-first is the law). ### CC-store-2 What a person does shows at once and is never lost @@ -40,7 +40,7 @@ When a result keeps needing manual intervention or a workaround, change the syst Why: manual one-offs, silent spinners and fragile daemons push ongoing work and support back onto the owner. -Evidence: 55 corrections across 48 sessions [PR-code-2]: codecast/446fdf0b, codecast/64995d35, codecast/9bb93b3f, codecast/fa0d609c, codecast/a13c6b2d, codecast/bc05fcae, codecast/906a0808, codecast/c760787a, codecast/1861a847, codecast/738de269, codecast/6d66a45e, codecast/0f33215d, codecast/204dc98c, codecast/c8c6771d, codecast/616fbff1, codecast/jx7162g, codecast/jx79098, codecast/jx7e9av, codecast/b7e8002b, codecast/jx73zke, codecast/c3f8856c, codecast/91cd1654, union-mobile-outreach/281e2ac7, bookmark/67e9d943, aurora/fc51b6ab, codecast/e6d9c003, codecast/0c1345c3, codecast/c35bef55, codecast/6fee4a65, codecast/ad386d76, codecast/ca17cd9c, codecast/a52e0a86, codecast/bb01e8f8, codecast/27e92264, codecast/d1c54572, codecast/8c983e64, codecast/262eb4b2, codecast/2de89e01, codecast/184842c5, codecast/ace992a7, codecast/90b055ca, codecast/75ad7b70, codecast/8c5048dc, codecast/c9d6048e, codecast/fb8238be, codecast/fc1d4250, codecast/f0a880ee, codecast/7b16546f. +Evidence: 56 corrections across 49 sessions [PR-code-2]: codecast/446fdf0b, codecast/64995d35, codecast/9bb93b3f, codecast/fa0d609c, codecast/a13c6b2d, codecast/bc05fcae, codecast/906a0808, codecast/c760787a, codecast/1861a847, codecast/738de269, codecast/6d66a45e, codecast/0f33215d, codecast/204dc98c, codecast/c8c6771d, codecast/616fbff1, codecast/jx7162g, codecast/jx79098, codecast/jx7e9av, codecast/b7e8002b, codecast/jx73zke, codecast/c3f8856c, codecast/91cd1654, union-mobile-outreach/281e2ac7, bookmark/67e9d943, aurora/fc51b6ab, codecast/e6d9c003, codecast/0c1345c3, codecast/c35bef55, codecast/6fee4a65, codecast/ad386d76, codecast/ca17cd9c, codecast/a52e0a86, codecast/bb01e8f8, codecast/27e92264, codecast/d1c54572, codecast/8c983e64, codecast/262eb4b2, codecast/2de89e01, codecast/184842c5, codecast/ace992a7, codecast/90b055ca, codecast/75ad7b70, codecast/8c5048dc, codecast/c9d6048e, codecast/fb8238be, codecast/fc1d4250, codecast/f0a880ee, codecast/7b16546f, codecast/9f10f68d. ### CC-code-2 Cut load at its source @@ -48,7 +48,7 @@ Many sessions share one machine, so work that contends for it is shared or batch Why: a copy of the same work per session put the machine into swap and stalled everything on it, and gates that ration duplicated work keep the waste while adding a new way to fail. -Evidence: 3 corrections across 3 sessions: codecast/6d66a45e, codecast/1adfe699, codecast/1b910ce2. Recorded in CLAUDE.md (Typechecking; Store: One window syncs; Reading state in components). +Evidence: 4 corrections across 4 sessions: codecast/6d66a45e, codecast/1adfe699, codecast/1b910ce2, codecast/2488bb2c. Recorded in CLAUDE.md (Typechecking; Store: One window syncs; Reading state in components). ## Shipping @@ -66,7 +66,7 @@ Work happens in the main checkout, with no branch, pull request or worktree unle Why: mandatory overhead on every task and inherited gates slowed the owner's main-branch workflow and buried the board in noise. -Evidence: 11 corrections across 8 sessions: codecast/b8189b1a, codecast/e277f266, codecast/30f7f14e, codecast/af185144, codecast/26a56b6e, codecast/jx7b0e1, codecast/jx780bb, codecast/5ae87b50. Recorded in CLAUDE.md (Working directory; Git history). +Evidence: 14 corrections across 11 sessions: codecast/b8189b1a, codecast/e277f266, codecast/30f7f14e, codecast/af185144, codecast/26a56b6e, codecast/jx7b0e1, codecast/jx780bb, codecast/5ae87b50, codecast/c99d7064, codecast/bcbabf5f, codecast/054090d4. Recorded in CLAUDE.md (Working directory; Git history). ### CC-ship-3 Finish the work instead of filing it @@ -84,7 +84,7 @@ Before changing or rebuilding something, list everything the current version doe Why: redesigns silently dropped features the owner relied on, and a broken tool that used to work is a release blocker. -Evidence: 15 corrections across 12 sessions [PR-verify-2]: codecast/c26c9845, codecast/4b84ce1d, codecast/jx7evm9, codecast/91cd1654, codecast/a9c89211, codecast/0f83ee96, codecast/1ee27c51, codecast/378a9c20, codecast/fb8e21ef, codecast/c6f40e40, codecast/3f51d2f8, codecast/fa8d6b6a. +Evidence: 18 corrections across 15 sessions [PR-verify-2]: codecast/c26c9845, codecast/4b84ce1d, codecast/jx7evm9, codecast/91cd1654, codecast/a9c89211, codecast/0f83ee96, codecast/1ee27c51, codecast/378a9c20, codecast/fb8e21ef, codecast/c6f40e40, codecast/3f51d2f8, codecast/fa8d6b6a, codecast/581cec6f, codecast/b6184991, codecast/a46aab69. ### CC-verify-2 A prompt change is proven on frozen moments @@ -100,7 +100,7 @@ A green `cast check` or a passing test shows that code runs, not that the featur Why: the owner caught done claims that rested on scores and typechecks while the real outcome was absent. -Evidence [PR-verify-2]: codecast/e2738e6f, codecast/790a2342, codecast/6daad809, codecast/0d9ef32a, codecast/888615d7. +Evidence [PR-verify-2]: codecast/e2738e6f, codecast/790a2342, codecast/6daad809, codecast/0d9ef32a, codecast/888615d7, codecast/755cd934, codecast/581cec6f, codecast/a8b245ca, codecast/725d13c6, codecast/d705a0c6, codecast/ebce6af8, codecast/0e3c08b1, codecast/b75f8546, codecast/67aaee4b, codecast/82008f00, codecast/7865e28e. ## Design @@ -110,7 +110,7 @@ Interactions never leave the user guessing or surprise them. Every action gets i Why: hidden actions, jumping layouts, silent states and unexpected view switches made features feel broken even when they worked. -Evidence: 54 corrections across 44 sessions: codecast/5cd65a63, codecast/8a5da82a, codecast/356f3371, codecast/2622f9a4, codecast/f388ef97, codecast/d78076a5, codecast/7603dece, codecast/bae26244, codecast/357dc99a, codecast/d0e1b2a5, codecast/d1b0172a, codecast/fcfb7767, codecast/6b76b81e, codecast/57e10167, codecast/3d3a114d, codecast/ba3755d7, codecast/23b202ab, codecast/26856fb1, codecast/377c6024, codecast/9924c5e6, codecast/03d88c38, codecast/2912b750, union-mobile/96cc4996, union-mobile-outreach/afd41522, codecast/904f00f7, codecast/81cae024, codecast/9e5d1eb5, codecast/665f4c2a, codecast/ca4d8feb, codecast/edddcb88, codecast/8d8ff33a, codecast/0cc88547, codecast/422f463a, codecast/f241b445, codecast/ff004dc3, codecast/3353b41a, codecast/6b3bfe46, codecast/4a6c2b32, codecast/64bc358e, codecast/87dd1a90, codecast/51985f9d, codecast/03778d17, codecast/30ec3f89, codecast/efba3465. +Evidence: 58 corrections across 48 sessions: codecast/5cd65a63, codecast/8a5da82a, codecast/356f3371, codecast/2622f9a4, codecast/f388ef97, codecast/d78076a5, codecast/7603dece, codecast/bae26244, codecast/357dc99a, codecast/d0e1b2a5, codecast/d1b0172a, codecast/fcfb7767, codecast/6b76b81e, codecast/57e10167, codecast/3d3a114d, codecast/ba3755d7, codecast/23b202ab, codecast/26856fb1, codecast/377c6024, codecast/9924c5e6, codecast/03d88c38, codecast/2912b750, union-mobile/96cc4996, union-mobile-outreach/afd41522, codecast/904f00f7, codecast/81cae024, codecast/9e5d1eb5, codecast/665f4c2a, codecast/ca4d8feb, codecast/edddcb88, codecast/8d8ff33a, codecast/0cc88547, codecast/422f463a, codecast/f241b445, codecast/ff004dc3, codecast/3353b41a, codecast/6b3bfe46, codecast/4a6c2b32, codecast/64bc358e, codecast/87dd1a90, codecast/51985f9d, codecast/03778d17, codecast/30ec3f89, codecast/efba3465, codecast/4d298911, codecast/3e224db6, codecast/563b5f06, codecast/0e3c08b1. ### CC-design-2 One scroller, content first @@ -134,7 +134,7 @@ When a person acts on something from one surface (replies from a decision card, Why: an action that makes its item vanish, leaves the old selection in place or strands the person in another view reads as broken, and they stop trusting that acting from a card or alert lands anywhere useful. -Evidence [CC-design-1, CC-store-1]: 7 corrections across 7 sessions: codecast/55c400b3, codecast/7d29c234, codecast/76fe128d, codecast/39df5298, codecast/8e5223fc, codecast/8561dae2, codecast/c96a9c00. +Evidence [CC-design-1, CC-store-1]: 9 corrections across 9 sessions: codecast/55c400b3, codecast/7d29c234, codecast/76fe128d, codecast/39df5298, codecast/8e5223fc, codecast/8561dae2, codecast/c96a9c00, codecast/1f3d41ae, codecast/88643666. ## Product @@ -152,7 +152,7 @@ Every message and notification goes to exactly the audience it was addressed to, Why: a message that lands in the wrong room, arrives twice, names the wrong author or arrives silently makes people miss what matters, and then stop trusting the channel at all. An alert that never clears, or rings for work that was never theirs, teaches them to ignore every alert. -Evidence: 30 corrections across 26 sessions: codecast/0f1ec09f, codecast/10f5a1df, codecast/148dc33b, codecast/44076792, codecast/6079b35f, codecast/8644250c, codecast/3dd04819, codecast/6f46e420, codecast/f53fa6df, codecast/3bf087ae, codecast/2e154d8a, codecast/1a972efd, codecast/24470faa, codecast/f9fc999c, codecast/09594a71, codecast/63452593, codecast/bd06ec0e, codecast/57c83dab, codecast/c8381c08, codecast/9547fac0, codecast/eb4f2e4c, codecast/2e72a830, codecast/ae1cca4f, codecast/7da2df3f, codecast/657bcf6b, codecast/792a92da. +Evidence: 32 corrections across 28 sessions: codecast/0f1ec09f, codecast/10f5a1df, codecast/148dc33b, codecast/44076792, codecast/6079b35f, codecast/8644250c, codecast/3dd04819, codecast/6f46e420, codecast/f53fa6df, codecast/3bf087ae, codecast/2e154d8a, codecast/1a972efd, codecast/24470faa, codecast/f9fc999c, codecast/09594a71, codecast/63452593, codecast/bd06ec0e, codecast/57c83dab, codecast/c8381c08, codecast/9547fac0, codecast/eb4f2e4c, codecast/2e72a830, codecast/ae1cca4f, codecast/7da2df3f, codecast/657bcf6b, codecast/792a92da, codecast/c8e270fa, codecast/5e81ccfb. ## Agents @@ -162,7 +162,7 @@ Keep the human's attention for what only they can do. Work an agent delegates or Why: every row in the needs-input queue costs attention, and inbox noise and needless wakes buried the few asks that mattered and wasted tokens. -Evidence: 44 corrections across 35 sessions: codecast/75340f90, codecast/eb7cdbed, codecast/ac950a1e, codecast/2622f9a4, codecast/b8189b1a, codecast/fb8e21ef, codecast/jx7csbd, codecast/jx76e8h, codecast/jx7bs90, codecast/jx7as3d, codecast/700edf11, codecast/jx7er8q, codecast/7064c786, codecast/c397f70d, codecast/ab9f99a3, codecast/jx72nyf, codecast/jx7ey9r, union-mobile/bb47b784, -Users-ashot-src/c71b7cc8, -Users-ashot-src/421e971d, union-mobile-outreach-backend/d98a708c, codecast/10c015f6, codecast/378a9c20, codecast/88b135ad, codecast/32ae8b13, codecast/0f3d4676, codecast/7bf7bf94, codecast/f596c8b0, codecast/e6536ab5, codecast/4a7919d2, codecast/abe1ff02, codecast/c97da9d2, codecast/66f03e62, codecast/35ee3cae, codecast/1ff45808. +Evidence: 46 corrections across 37 sessions: codecast/75340f90, codecast/eb7cdbed, codecast/ac950a1e, codecast/2622f9a4, codecast/b8189b1a, codecast/fb8e21ef, codecast/jx7csbd, codecast/jx76e8h, codecast/jx7bs90, codecast/jx7as3d, codecast/700edf11, codecast/jx7er8q, codecast/7064c786, codecast/c397f70d, codecast/ab9f99a3, codecast/jx72nyf, codecast/jx7ey9r, union-mobile/bb47b784, -Users-ashot-src/c71b7cc8, -Users-ashot-src/421e971d, union-mobile-outreach-backend/d98a708c, codecast/10c015f6, codecast/378a9c20, codecast/88b135ad, codecast/32ae8b13, codecast/0f3d4676, codecast/7bf7bf94, codecast/f596c8b0, codecast/e6536ab5, codecast/4a7919d2, codecast/abe1ff02, codecast/c97da9d2, codecast/66f03e62, codecast/35ee3cae, codecast/1ff45808, codecast/d39fd226, codecast/5366d46b. ### CC-agents-2 A decision card carries its own context @@ -170,7 +170,7 @@ Before a direction that is costly to undo (a schema, a protocol, a migration), t Why: cards with bare ids and buried asks could not be decided without opening the session, which defeats the queue, and directions nobody examined wasted the build. -Evidence [PR-agents-3]: codecast/894d8984, codecast/a5d62c59, codecast/30f7f14e, codecast/fb8e21ef, codecast/jx7fk24, codecast/7f143785, codecast/717f2b8e, codecast/378a9c20, codecast/45e09d37, codecast/aded396f, codecast/d4517ec3, codecast/84ba71e9, codecast/13a8a115, codecast/4ef5e6aa, codecast/cc3323ac. +Evidence [PR-agents-3]: codecast/894d8984, codecast/a5d62c59, codecast/30f7f14e, codecast/fb8e21ef, codecast/jx7fk24, codecast/7f143785, codecast/717f2b8e, codecast/378a9c20, codecast/45e09d37, codecast/aded396f, codecast/d4517ec3, codecast/84ba71e9, codecast/13a8a115, codecast/4ef5e6aa, codecast/cc3323ac, codecast/34712397, codecast/2f3dc8ff, codecast/ff821044, codecast/34f45474. ### CC-agents-3 Strongest model decides, briefed in full @@ -211,3 +211,11 @@ An agent with something a person in front of it needs says it without waiting to Why: agents that stayed silent or described instead of showing left the people they were meant to help without the answer that was one message away. Evidence: 4 corrections across 4 sessions: codecast/b986aae9, codecast/fb8e21ef, codecast/f3a3d81e, codecast/98f0e645. The same ask about huddle agents a week earlier is ct-70894. + +### CC-agents-8 An explanation names the session behind it + +When an agent explains why something looks or behaves the way it does, or what changed it, it names the session that made the change and the message or decision where that was settled, linked by short id, after tracing it through `cast blame`, the commit's session trailer or `cast search`. A cause given without its source leaves the person unable to read the reasoning, ask that session, or judge whether the change was meant. + +Why: people kept following an agent's account of a change with a request to find the session that made it, which the agent could have traced itself. + +Evidence: 9 corrections across 9 sessions: codecast/98a27e2c, codecast/b6184991, codecast/d2c99128, codecast/83744b5e, codecast/0862a687, codecast/872256e7, codecast/10f22bde, codecast/341235d4, codecast/1128c72e. diff --git a/docs/principles.md b/docs/principles.md index b99fc89db6..6704f316bf 100644 --- a/docs/principles.md +++ b/docs/principles.md @@ -16,7 +16,7 @@ Ship the whole requested scope as part of the product, not a slice beside it. A Why: Work was repeatedly delivered as partial slices, CLI-only capability, or standalone bolt-ons the owner could not use. -Evidence: 40 corrections across 33 sessions (`complete-and-integrated`): codecast/417df694, union-mobile/58f81b04, -Users-ashot/b22e7a56, mail/4a53ff52, codecast/290127df, codecast/902a9235, codecast/53dfd240, codecast/74f46999, codecast/27ac54c7, union-mobile/939092bf, union-mobile-outreach/6f18639e, -Users-ashot/0869f8ac, codecast/a4c2b17f, union-mobile-outreach/509b4b48, union-mobile-outreach/b8501299, bookmark/67e9d943, codecast/619d3d49, aurora/fc51b6ab, eaiden/512528df, mail/66bc2f86, mail/b76543a3, codecast/ac884a88, codecast/378a9c20, codecast/86dc1449, codecast/fb8e21ef, union-mobile/dba303fb, codecast/1763f6a6, codecast/af02f09f, codecast/a9c5405f, codecast/f364cad2, codecast/fa8d6b6a, codecast/c760787a, codecast/b383d83d. +Evidence: 44 corrections across 37 sessions (`complete-and-integrated`): codecast/417df694, union-mobile/58f81b04, -Users-ashot/b22e7a56, mail/4a53ff52, codecast/290127df, codecast/902a9235, codecast/53dfd240, codecast/74f46999, codecast/27ac54c7, union-mobile/939092bf, union-mobile-outreach/6f18639e, -Users-ashot/0869f8ac, codecast/a4c2b17f, union-mobile-outreach/509b4b48, union-mobile-outreach/b8501299, bookmark/67e9d943, codecast/619d3d49, aurora/fc51b6ab, eaiden/512528df, mail/66bc2f86, mail/b76543a3, codecast/ac884a88, codecast/378a9c20, codecast/86dc1449, codecast/fb8e21ef, union-mobile/dba303fb, codecast/1763f6a6, codecast/af02f09f, codecast/a9c5405f, codecast/f364cad2, codecast/fa8d6b6a, codecast/c760787a, codecast/b383d83d, codecast/3c78992f, codecast/9b407478, codecast/72eae20f, codecast/40133e08. ### PR-product-2 Simple, reliable core first @@ -32,7 +32,7 @@ Changes and automation do not harm live work or real people. Before acting on ru Why: Harm to live work, a user's screen or another person cannot be undone by a later fix. -Evidence: 11 corrections across 10 sessions (`never-harm-live-work-or-people`): codecast/52d95fcf, codecast/81fa353e, codecast/19bfa707, codecast/e7b2cf97, codecast/1582c431, codecast/6faa44cb, union-mobile-outreach/f558620d, codecast/71261eae, union-mobile/ca918189, codecast/1584e547. +Evidence: 12 corrections across 11 sessions (`never-harm-live-work-or-people`): codecast/52d95fcf, codecast/81fa353e, codecast/19bfa707, codecast/e7b2cf97, codecast/1582c431, codecast/6faa44cb, union-mobile-outreach/f558620d, codecast/71261eae, union-mobile/ca918189, codecast/1584e547, codecast/e27b2302. ### PR-product-6 Concepts mean what they say @@ -40,7 +40,7 @@ Every user-facing concept does what its name plainly says. Defaults come from wh Why: Users trust the UI only while its words match what it does. -Evidence: 11 corrections across 10 sessions (`concepts-mean-what-they-say`): codecast/8e292690, codecast/de3cfba6, codecast/81ef8363, union-mobile/a1803f62, codecast/jx7csbd, union-mobile/jx7b88a, codecast/ba2c563d, codecast/17183246, codecast/ca73e19c, codecast/4aa40ccc. +Evidence: 14 corrections across 13 sessions (`concepts-mean-what-they-say`): codecast/8e292690, codecast/de3cfba6, codecast/81ef8363, union-mobile/a1803f62, codecast/jx7csbd, union-mobile/jx7b88a, codecast/ba2c563d, codecast/17183246, codecast/ca73e19c, codecast/4aa40ccc, codecast/81c07635, codecast/67aaee4b, codecast/725d13c6. ### PR-product-7 Choices show their consequences @@ -66,7 +66,7 @@ Before building, find the system that already does the job and extend it. Every Why: Parallel paths drift apart, and each copy fails in its own way. -Evidence: 47 corrections across 33 sessions (`one-mechanism-one-codepath`): union-mobile/bb91c041, union-mobile/2a20d3fe, -Users-ashot/b22e7a56, union-mobile/939092bf, union-mobile/0890df87, codecast/ed999385, codecast/a5b1a2fc, union-mobile-outreach/6f18639e, union-mobile-outreach/85b15576, codecast/a3dd2256, union-mobile/a9e7343d, platform/70c3cbc8, codecast/b8189b1a, union-mobile/bcfdb6e9, codecast/044a5a51, codecast/7dbfa844, codecast/jx71mm7, codecast/jx79ech, union-mobile/7551c3e8, codecast/5996141c, codecast/jx7ab41, codecast/fb8e21ef, codecast/jx7csbd, codecast/4b84ce1d, union-mobile/jx7a7ch, codecast/29e4db36, union-mobile-outreach/b82f0a83, codecast/0ac05029, codecast/2cda322f, codecast/jx7f403, codecast/c2a5c2a0, codecast/4b9b70cd, union-mobile/adfb7975. +Evidence: 49 corrections across 35 sessions (`one-mechanism-one-codepath`): union-mobile/bb91c041, union-mobile/2a20d3fe, -Users-ashot/b22e7a56, union-mobile/939092bf, union-mobile/0890df87, codecast/ed999385, codecast/a5b1a2fc, union-mobile-outreach/6f18639e, union-mobile-outreach/85b15576, codecast/a3dd2256, union-mobile/a9e7343d, platform/70c3cbc8, codecast/b8189b1a, union-mobile/bcfdb6e9, codecast/044a5a51, codecast/7dbfa844, codecast/jx71mm7, codecast/jx79ech, union-mobile/7551c3e8, codecast/5996141c, codecast/jx7ab41, codecast/fb8e21ef, codecast/jx7csbd, codecast/4b84ce1d, union-mobile/jx7a7ch, codecast/29e4db36, union-mobile-outreach/b82f0a83, codecast/0ac05029, codecast/2cda322f, codecast/jx7f403, codecast/c2a5c2a0, codecast/4b9b70cd, union-mobile/adfb7975, codecast/0e3c08b1, codecast/5366d46b. ### PR-code-2 Fix the cause so it cannot recur @@ -74,7 +74,7 @@ When something breaks, trace it to the mechanism that produced it and change tha Why: Surface patches and one-off repairs let the same failures return, and the owner repeatedly found agents building on top of something fundamentally broken. -Evidence: 44 corrections across 33 sessions (`fix-the-cause-so-it-cannot-recur`): union-mobile-outreach/281e2ac7, codecast/bd3a20e0, codecast/eac20021, codecast/71261eae, codecast/714707a5, union-mobile/dcb2cd5b, union-mobile-outreach-backend/d98a708c, union-mobile/0890df87, codecast/a5b1a2fc, -Users-ashot/b22e7a56, union-mobile-outreach/4ae73c82, union-mobile/a1803f62, -Users-ashot--codecast/b6168064, codecast/jx77ps4, codecast/jx729jd, codecast/jx7ex0x, codecast/81fa353e, codecast/9f5f5126, codecast/6c146c5e, codecast/6d66a45e, union-mobile/jx7b88a, codecast/jx7b4ff, union-mobile/ef6841cf, union-mobile/jx763br, union-mobile/6d5f7455, codecast/39d41cbf, codecast/53fedb97, union-mobile-outreach/4723bdce, codecast/fb2f80ed, codecast/7f5fcb2f, codecast/b83ab0ac, codecast/ca8c862a, codecast/57c83dab. +Evidence: 48 corrections across 37 sessions (`fix-the-cause-so-it-cannot-recur`): union-mobile-outreach/281e2ac7, codecast/bd3a20e0, codecast/eac20021, codecast/71261eae, codecast/714707a5, union-mobile/dcb2cd5b, union-mobile-outreach-backend/d98a708c, union-mobile/0890df87, codecast/a5b1a2fc, -Users-ashot/b22e7a56, union-mobile-outreach/4ae73c82, union-mobile/a1803f62, -Users-ashot--codecast/b6168064, codecast/jx77ps4, codecast/jx729jd, codecast/jx7ex0x, codecast/81fa353e, codecast/9f5f5126, codecast/6c146c5e, codecast/6d66a45e, union-mobile/jx7b88a, codecast/jx7b4ff, union-mobile/ef6841cf, union-mobile/jx763br, union-mobile/6d5f7455, codecast/39d41cbf, codecast/53fedb97, union-mobile-outreach/4723bdce, codecast/fb2f80ed, codecast/7f5fcb2f, codecast/b83ab0ac, codecast/ca8c862a, codecast/57c83dab, codecast/adb23c0f, codecast/ece115a5, codecast/45cd5fe4, codecast/af254ad9. ### PR-code-4 Fix the class, not the instance @@ -82,7 +82,7 @@ Treat a reported defect as one example of a class. Fix it at the shared source, Why: Fixing only the instance shown leaves its siblings broken and makes the human file each one by hand. -Evidence: 27 corrections across 24 sessions (`fix-the-class-not-the-instance`): codecast/eacfd299, codecast/de0bf5b1, codecast/699d5248, codecast/jx76124, union-mobile/jx7016r, codecast/cfdabd0a, codecast/619d3d49, codecast/b06ea6c5, codecast/872d70ac, union-mobile/bcfdb6e9, union-mobile/b41bf2b5, codecast/b2ada11b, codecast/59ea2ca6, codecast/4d9e2fbb, codecast/9e413736, codecast/ba632362, union-mobile/cd59730c, union-mobile/d989885e, union-mobile/ad50cd72, codecast/2d3f2d0c, codecast/88c21616, codecast/af514643, codecast/a2d38abe, codecast/1cca31e3. +Evidence: 30 corrections across 27 sessions (`fix-the-class-not-the-instance`): codecast/eacfd299, codecast/de0bf5b1, codecast/699d5248, codecast/jx76124, union-mobile/jx7016r, codecast/cfdabd0a, codecast/619d3d49, codecast/b06ea6c5, codecast/872d70ac, union-mobile/bcfdb6e9, union-mobile/b41bf2b5, codecast/b2ada11b, codecast/59ea2ca6, codecast/4d9e2fbb, codecast/9e413736, codecast/ba632362, union-mobile/cd59730c, union-mobile/d989885e, union-mobile/ad50cd72, codecast/2d3f2d0c, codecast/88c21616, codecast/af514643, codecast/a2d38abe, codecast/1cca31e3, codecast/928e7286, codecast/aab23e52, codecast/0697af66. ### PR-code-5 Prove before you spread @@ -100,7 +100,7 @@ A surface leads with the essence of what is happening for the person who uses it Why: Operator pages repeatedly came back both overloaded and uninformative, and patching them did not fix the underlying model. -Evidence: 118 corrections across 76 sessions (`essence-first-surfaces`): codecast/084db220, codecast/3bf087ae, codecast/4dfba4c5, codecast/d86935cc, codecast/743fc3d3, codecast/f3ccd01f, codecast/74bc85f4, codecast/ca4e3cf0, union-mobile-outreach/281e2ac7, union-mobile/3a9a43dd, mail/f697df4e, mail/4521d6f2, mail/27c9bbb2, family/9d308f48, codecast/466dbf0a, codecast/2a0909a7, codecast/916135f7, union-mobile/52e3266a, union-mobile/jx7b88a, codecast/fb8e21ef, codecast/jx7csbd, codecast/c26c9845, codecast/db2088f5, union-mobile-outreach/ed62e218, codecast/jx76jc2, codecast/be5f2068, codecast/13238939, codecast/4a0f40fd, codecast/56715870, codecast/jx75bq6, codecast/2a449dd0, codecast/a268e4ac, codecast/3c40c83d, codecast/jx78q70, codecast/378a9c20, codecast/6339c66e, codecast/77ece653, codecast/e778aee1, codecast/3844653f, codecast/41b9595f, codecast/92f1d545, codecast/9e5d1eb5, union-mobile/4a73357f, union-mobile/f011de88, codecast/8bd42f9e, codecast/47f7522a, codecast/ad3ac412, codecast/72de81b7, codecast/9788b781, codecast/4dc8fd16, codecast/4a374fd3, union-mobile/57e89dff, union-mobile/659522a5, union-mobile/32707c9f, union-mobile/ed84a8ea, codecast/f923f784, codecast/3e2ac30c, codecast/6fc5ee8d, codecast/5531c22b, codecast/2d750c70, codecast/578bea92, codecast/aaab50ee, codecast/a2b51951, codecast/6e38bbc1, codecast/9c1cc1ad, codecast/76401644, codecast/729f4763, codecast/d1b4a6f9, codecast/1e521acd, codecast/7b9f3b80, codecast/ccf0865b, union-mobile/a35ae69a, union-mobile/5344cdc6, union-mobile/b36ced0c, union-mobile/58b49708, union-mobile/1bb34b8d. +Evidence: 124 corrections across 82 sessions (`essence-first-surfaces`): codecast/084db220, codecast/3bf087ae, codecast/4dfba4c5, codecast/d86935cc, codecast/743fc3d3, codecast/f3ccd01f, codecast/74bc85f4, codecast/ca4e3cf0, union-mobile-outreach/281e2ac7, union-mobile/3a9a43dd, mail/f697df4e, mail/4521d6f2, mail/27c9bbb2, family/9d308f48, codecast/466dbf0a, codecast/2a0909a7, codecast/916135f7, union-mobile/52e3266a, union-mobile/jx7b88a, codecast/fb8e21ef, codecast/jx7csbd, codecast/c26c9845, codecast/db2088f5, union-mobile-outreach/ed62e218, codecast/jx76jc2, codecast/be5f2068, codecast/13238939, codecast/4a0f40fd, codecast/56715870, codecast/jx75bq6, codecast/2a449dd0, codecast/a268e4ac, codecast/3c40c83d, codecast/jx78q70, codecast/378a9c20, codecast/6339c66e, codecast/77ece653, codecast/e778aee1, codecast/3844653f, codecast/41b9595f, codecast/92f1d545, codecast/9e5d1eb5, union-mobile/4a73357f, union-mobile/f011de88, codecast/8bd42f9e, codecast/47f7522a, codecast/ad3ac412, codecast/72de81b7, codecast/9788b781, codecast/4dc8fd16, codecast/4a374fd3, union-mobile/57e89dff, union-mobile/659522a5, union-mobile/32707c9f, union-mobile/ed84a8ea, codecast/f923f784, codecast/3e2ac30c, codecast/6fc5ee8d, codecast/5531c22b, codecast/2d750c70, codecast/578bea92, codecast/aaab50ee, codecast/a2b51951, codecast/6e38bbc1, codecast/9c1cc1ad, codecast/76401644, codecast/729f4763, codecast/d1b4a6f9, codecast/1e521acd, codecast/7b9f3b80, codecast/ccf0865b, union-mobile/a35ae69a, union-mobile/5344cdc6, union-mobile/b36ced0c, union-mobile/58b49708, union-mobile/1bb34b8d, codecast/394efc3c, codecast/666a275e, codecast/b6184991, codecast/bb8560f7, codecast/9b407478, codecast/34d8946e. ### PR-design-2 Restrained and distinctive @@ -108,7 +108,7 @@ Aim for visuals that are restrained and distinctive at once. Work inside the exi Why: Output swung between plain defaults and busy over-decoration; clutter, loud accents and familiar AI design tells read as unconsidered. -Evidence: 72 corrections across 50 sessions (`distinctive-restrained-visuals`): codecast/3287828e, codecast/f3a3d81e, codecast/dad146a7, codecast/6f46e420, codecast/a2d64891, union-mobile/a0949a3e, -Users-ashot/b22e7a56, family/52130ad8, family/037d4ff6, codecast/8407196b, codecast/0f33215d, union-mobile/0859d2b3, union-mobile/96cc4996, -Users-ashot/0869f8ac, codecast/479a0529, codecast/357dc99a, family/9d308f48, codecast/8c9aae26, codecast/jx78q70, codecast/jx7evm9, codecast/377c6024, union-mobile/2621cefb, union-mobile/99aaba5b, union-mobile/7868a451, codecast/51208eea, codecast/0da5df14, codecast/c26c9845, codecast/f9b2d254, codecast/c1273b38, codecast/be5f2068, codecast/b2ada11b, codecast/c8f6942d, codecast/jx7acve, codecast/jx7dmqa, family/jx7523m, union-fundraising/jx79x1p, codecast/jx7av6x, codecast/1701d953, codecast/2f05058c, codecast/0cc88547, codecast/b2c6cf8e, codecast/0c56796e, codecast/2c03068a, codecast/227a2b9f, codecast/04126458, codecast/d8f57b98, codecast/36b17150, codecast/31a9caa4, codecast/fef9c730, codecast/4b5bb104. +Evidence: 76 corrections across 54 sessions (`distinctive-restrained-visuals`): codecast/3287828e, codecast/f3a3d81e, codecast/dad146a7, codecast/6f46e420, codecast/a2d64891, union-mobile/a0949a3e, -Users-ashot/b22e7a56, family/52130ad8, family/037d4ff6, codecast/8407196b, codecast/0f33215d, union-mobile/0859d2b3, union-mobile/96cc4996, -Users-ashot/0869f8ac, codecast/479a0529, codecast/357dc99a, family/9d308f48, codecast/8c9aae26, codecast/jx78q70, codecast/jx7evm9, codecast/377c6024, union-mobile/2621cefb, union-mobile/99aaba5b, union-mobile/7868a451, codecast/51208eea, codecast/0da5df14, codecast/c26c9845, codecast/f9b2d254, codecast/c1273b38, codecast/be5f2068, codecast/b2ada11b, codecast/c8f6942d, codecast/jx7acve, codecast/jx7dmqa, family/jx7523m, union-fundraising/jx79x1p, codecast/jx7av6x, codecast/1701d953, codecast/2f05058c, codecast/0cc88547, codecast/b2c6cf8e, codecast/0c56796e, codecast/2c03068a, codecast/227a2b9f, codecast/04126458, codecast/d8f57b98, codecast/36b17150, codecast/31a9caa4, codecast/fef9c730, codecast/4b5bb104, codecast/afe4d413, codecast/933fcba1, codecast/79bb9e0b, union-mobile/8fc9ad07. ### PR-design-4 Same object, same rendering @@ -116,7 +116,7 @@ Each object has one canonical page and one rendering, and every reference to it, Why: When the same thing renders differently, or a reference leads nowhere, people read one object as several and cannot find their way through the product. -Evidence: 37 corrections across 32 sessions (`same-object-same-rendering`): union-mobile-outreach/281e2ac7, union-mobile-outreach/b8501299, union-mobile/a9e7343d, aurora/34768c39, codecast/a893dea2, family/9d308f48, codecast/fb8e21ef, codecast/jx7csbd, union-mobile/7551c3e8, codecast/58d03e78, codecast/5de96742, codecast/9a39ebc7, codecast/jx72em9, codecast/jx72r3w, codecast/c26c9845, codecast/4b84ce1d, codecast/ba4a0a63, codecast/aff10c45, codecast/04eb1d60, codecast/1b40c9be, codecast/6a686d2d, codecast/83e944ba, codecast/3c4957e8, codecast/dc462484, codecast/378a9c20, codecast/6339c66e, codecast/cd317d61, codecast/74bc85f4, codecast/2d161162, codecast/12de1eda, codecast/1ff45808, codecast/87aad2b6. +Evidence: 41 corrections across 36 sessions (`same-object-same-rendering`): union-mobile-outreach/281e2ac7, union-mobile-outreach/b8501299, union-mobile/a9e7343d, aurora/34768c39, codecast/a893dea2, family/9d308f48, codecast/fb8e21ef, codecast/jx7csbd, union-mobile/7551c3e8, codecast/58d03e78, codecast/5de96742, codecast/9a39ebc7, codecast/jx72em9, codecast/jx72r3w, codecast/c26c9845, codecast/4b84ce1d, codecast/ba4a0a63, codecast/aff10c45, codecast/04eb1d60, codecast/1b40c9be, codecast/6a686d2d, codecast/83e944ba, codecast/3c4957e8, codecast/dc462484, codecast/378a9c20, codecast/6339c66e, codecast/cd317d61, codecast/74bc85f4, codecast/2d161162, codecast/12de1eda, codecast/1ff45808, codecast/87aad2b6, codecast/85ac3963, codecast/d2c99128, codecast/0e3c08b1, codecast/8748ad15. ### PR-design-6 Design for the real audience @@ -134,7 +134,7 @@ Every label, status, button and generated sentence a user reads makes sense on f Why: Invented terms, ambiguous buttons and salesy copy made the owner ask what things meant, read as machine-written, and got rewritten line by line. -Evidence: 33 corrections across 21 sessions (`self-explanatory-copy`): union-mobile-outreach/281e2ac7, codecast/2a990522, family/9d308f48, aurora/34768c39, family/52130ad8, family/037d4ff6, union-mobile/96cc4996, codecast/a893dea2, union-fundraising/jx79x1p, personal/jx736q0, union-fundraising/jx7bs72, union-mobile/jx77af7, union-mobile/6d5f7455, codecast/378a9c20, codecast/03c2900a, codecast/978de996, codecast/247dc32a, codecast/a81029a3, codecast/c0607c95, codecast/560dc0cb, codecast/c98e3ad3. +Evidence: 38 corrections across 26 sessions (`self-explanatory-copy`): union-mobile-outreach/281e2ac7, codecast/2a990522, family/9d308f48, aurora/34768c39, family/52130ad8, family/037d4ff6, union-mobile/96cc4996, codecast/a893dea2, union-fundraising/jx79x1p, personal/jx736q0, union-fundraising/jx7bs72, union-mobile/jx77af7, union-mobile/6d5f7455, codecast/378a9c20, codecast/03c2900a, codecast/978de996, codecast/247dc32a, codecast/a81029a3, codecast/c0607c95, codecast/560dc0cb, codecast/c98e3ad3, codecast/f51d12c0, codecast/29ee95d7, codecast/45204244, codecast/933fcba1, codecast/8748ad15. ## Process @@ -144,7 +144,7 @@ When work first feels finished, treat that as the start of the final mile. Hunt Why: The owner repeatedly had to demand more iteration because work was returned at its first acceptable version. -Evidence: 67 corrections across 51 sessions (`final-mile-polish-rounds`): codecast/417df694, codecast/74745baf, codecast/7e53831c, codecast/9788b781, codecast/a2d64891, codecast/d9e1ce6c, codecast/3287828e, union-mobile/5190efa5, codecast/790a2342, -Users-ashot/3d89f116, -Users-ashot/b22e7a56, codecast/5cd65a63, union-mobile-outreach/b8501299, mail/4a53ff52, codecast/902a9235, union-mobile/3a9a43dd, codecast/d0e1b2a5, codecast/8b86a4df, union-mobile/0859d2b3, codecast/a893dea2, codecast/27ac54c7, union-mobile/96cc4996, family/52130ad8, mail/27c9bbb2, union-mobile-outreach/281e2ac7, codecast/a2f48cf2, codecast/fb8e21ef, codecast/51edf9a8, codecast/c26c9845, union-mobile/2621cefb, union-mobile/99aaba5b, union-mobile-outreach/79d8465e, aurora/fc51b6ab, family/0ba3e541, codecast/872d70ac, codecast/jx7csbd, union-mobile/jx7fchg, codecast/1f6146fa, codecast/d0c39b7b, codecast/jx7cv0h, codecast/jx7dqvy, codecast/jx7crht, codecast/jx7266j, codecast/jx7djk3, codecast/378a9c20, codecast/891bb838, union-mobile/4a73357f, codecast/cc71d1ce, codecast/f9f785f3, union-mobile/cfe55c25, union-mobile/a27b507f. +Evidence: 72 corrections across 56 sessions (`final-mile-polish-rounds`): codecast/417df694, codecast/74745baf, codecast/7e53831c, codecast/9788b781, codecast/a2d64891, codecast/d9e1ce6c, codecast/3287828e, union-mobile/5190efa5, codecast/790a2342, -Users-ashot/3d89f116, -Users-ashot/b22e7a56, codecast/5cd65a63, union-mobile-outreach/b8501299, mail/4a53ff52, codecast/902a9235, union-mobile/3a9a43dd, codecast/d0e1b2a5, codecast/8b86a4df, union-mobile/0859d2b3, codecast/a893dea2, codecast/27ac54c7, union-mobile/96cc4996, family/52130ad8, mail/27c9bbb2, union-mobile-outreach/281e2ac7, codecast/a2f48cf2, codecast/fb8e21ef, codecast/51edf9a8, codecast/c26c9845, union-mobile/2621cefb, union-mobile/99aaba5b, union-mobile-outreach/79d8465e, aurora/fc51b6ab, family/0ba3e541, codecast/872d70ac, codecast/jx7csbd, union-mobile/jx7fchg, codecast/1f6146fa, codecast/d0c39b7b, codecast/jx7cv0h, codecast/jx7dqvy, codecast/jx7crht, codecast/jx7266j, codecast/jx7djk3, codecast/378a9c20, codecast/891bb838, union-mobile/4a73357f, codecast/cc71d1ce, codecast/f9f785f3, union-mobile/cfe55c25, union-mobile/a27b507f, codecast/ff821044, codecast/997ace08, codecast/8dcc0979, codecast/a46aab69, union-mobile/7d94d167. ### PR-process-2 Own the outcome, not the task @@ -152,7 +152,7 @@ Own the outcome, not the task. Write the goal and how you will know it is met wh Why: Agents treated work as isolated fixes, handed steps back, or stalled at blockers, so the goal the owner cared about never moved. -Evidence: 90 corrections across 62 sessions (`own-the-outcome-doggedly`): codecast/22d4c672, codecast/da14f29f, codecast/9bb93b3f, codecast/fa0d609c, union-mobile/52cf2e6f, union-mobile/6e42ed88, union-mobile-outreach/281e2ac7, union-mobile-outreach/85b15576, -Users-ashot/3d89f116, union-mobile-outreach/65e45a18, codecast/53dfd240, codecast/a893dea2, union-mobile/cacbf3c8, codecast/a2f48cf2, codecast/083b007c, union-mobile-outreach/afd41522, aurora/34768c39, -Users-ashot/95306fa0, union-mobile/jx7b88a, codecast/fb8e21ef, aurora/fc51b6ab, mail/b76543a3, codecast/jx75d3z, codecast/jx7etp0, codecast/jx74a40, union-mobile/jx7d5py, family/9d308f48, codecast/a8f5994d, -Users-ashot/b22e7a56, union-mobile/bb47b784, family/0ba3e541, codecast/jx71gw6, codecast/jx74jnb, codecast/b3223646, codecast/9b95a994, codecast/23a8687c, union-mobile/22082440, union-mobile/d1e794f6, union-mobile/c211e734, union-mobile/jx763br, union-mobile/482fb63f, codecast/378a9c20, codecast/1f6146fa, union-mobile/7b19c84e, union-mobile/a27b507f, union-mobile/e6ec6225, codecast/9e2f99e8, union-mobile/6d5f7455, union-mobile/d0d158f7, union-mobile-outreach/6719f7ec, union-mobile/f0888985, union-mobile/58f81b04, union-mobile/c8f5e37e, union-mobile/5f592e09, union-mobile/a51029de, codecast/ea8bc485, codecast/37abd463, codecast/1baaa1fa, union-mobile/5f508a0d, union-mobile/b4358508, union-mobile/fd948930, union-mobile/52166d2b. +Evidence: 92 corrections across 64 sessions (`own-the-outcome-doggedly`): codecast/22d4c672, codecast/da14f29f, codecast/9bb93b3f, codecast/fa0d609c, union-mobile/52cf2e6f, union-mobile/6e42ed88, union-mobile-outreach/281e2ac7, union-mobile-outreach/85b15576, -Users-ashot/3d89f116, union-mobile-outreach/65e45a18, codecast/53dfd240, codecast/a893dea2, union-mobile/cacbf3c8, codecast/a2f48cf2, codecast/083b007c, union-mobile-outreach/afd41522, aurora/34768c39, -Users-ashot/95306fa0, union-mobile/jx7b88a, codecast/fb8e21ef, aurora/fc51b6ab, mail/b76543a3, codecast/jx75d3z, codecast/jx7etp0, codecast/jx74a40, union-mobile/jx7d5py, family/9d308f48, codecast/a8f5994d, -Users-ashot/b22e7a56, union-mobile/bb47b784, family/0ba3e541, codecast/jx71gw6, codecast/jx74jnb, codecast/b3223646, codecast/9b95a994, codecast/23a8687c, union-mobile/22082440, union-mobile/d1e794f6, union-mobile/c211e734, union-mobile/jx763br, union-mobile/482fb63f, codecast/378a9c20, codecast/1f6146fa, union-mobile/7b19c84e, union-mobile/a27b507f, union-mobile/e6ec6225, codecast/9e2f99e8, union-mobile/6d5f7455, union-mobile/d0d158f7, union-mobile-outreach/6719f7ec, union-mobile/f0888985, union-mobile/58f81b04, union-mobile/c8f5e37e, union-mobile/5f592e09, union-mobile/a51029de, codecast/ea8bc485, codecast/37abd463, codecast/1baaa1fa, union-mobile/5f508a0d, union-mobile/b4358508, union-mobile/fd948930, union-mobile/52166d2b, codecast/50491b27, codecast/6e34b53c. ### PR-process-3 Ground in current evidence @@ -160,7 +160,7 @@ Ground every proposal, build and claim in current evidence, not memory or assump Why: Agents proposed mechanisms that already existed, contradicted shipped work, trusted stale plans, or asserted false limits without checking. -Evidence: 35 corrections across 28 sessions (`ground-before-building`): union-mobile/a27b507f, union-mobile/6e42ed88, union-mobile/cf2e4589, platform/70c3cbc8, codecast/b8189b1a, union-mobile/0890df87, codecast/a0e831e8, -Users-ashot/b22e7a56, codecast/9a114468, union-mobile/cacbf3c8, codecast/790a2342, family/037d4ff6, family/0ba3e541, codecast/30f7f14e, codecast/5cd65a63, codecast/72e5cd0a, union-mobile-outreach/b8501299, codecast/fb8e21ef, codecast/jx7csbd, union-mobile/bcfdb6e9, family/101b6cc3, codecast/71261eae, union-mobile/jx7b88a, union-mobile-outreach/21872d19, codecast/a17b915d, codecast/6ed7379d, union-mobile/f5bcf84b, union-mobile/8ffa1d9c. +Evidence: 38 corrections across 31 sessions (`ground-before-building`): union-mobile/a27b507f, union-mobile/6e42ed88, union-mobile/cf2e4589, platform/70c3cbc8, codecast/b8189b1a, union-mobile/0890df87, codecast/a0e831e8, -Users-ashot/b22e7a56, codecast/9a114468, union-mobile/cacbf3c8, codecast/790a2342, family/037d4ff6, family/0ba3e541, codecast/30f7f14e, codecast/5cd65a63, codecast/72e5cd0a, union-mobile-outreach/b8501299, codecast/fb8e21ef, codecast/jx7csbd, union-mobile/bcfdb6e9, family/101b6cc3, codecast/71261eae, union-mobile/jx7b88a, union-mobile-outreach/21872d19, codecast/a17b915d, codecast/6ed7379d, union-mobile/f5bcf84b, union-mobile/8ffa1d9c, union-mobile/da2f3f57, union-mobile/432f8491, union-mobile/dfae498b. ### PR-process-4 Independent review @@ -264,4 +264,4 @@ Before starting build work, tell the human roughly how long it will take and whe Why: The human plans around your work and should not have to chase it. -Evidence: 4 corrections across 2 sessions (`set-expectations-up-front`): union-mobile/369be387, union-mobile/jx763br. +Evidence: 7 corrections across 5 sessions (`set-expectations-up-front`): union-mobile/369be387, union-mobile/jx763br, union-mobile/307a8e2c, union-mobile/ab7657d0, union-mobile/17e095d1. diff --git a/docs/proposals/personal-integrations.md b/docs/proposals/personal-integrations.md new file mode 100644 index 0000000000..6015769228 --- /dev/null +++ b/docs/proposals/personal-integrations.md @@ -0,0 +1,229 @@ +# Personal integrations: mail, iMessage, and codecast's own number + +Status: proposal, 2026-11-27. Nothing here is built yet except where marked. + +## The job + +A person runs dozens of agents. Today those agents reach the person's mail and +texts only through two CLIs on one laptop (`whisk`, `imsg`). That has three +consequences: + +- A session on a cloud host can't see either one. +- Waiting on a reply means a local poll loop. +- Nothing in codecast knows the data exists. + +The person, in turn, reaches their agents only through the app. Codecast has +no way to text them when an agent is blocked, and no way for them to text back. + +Three integrations close this: + +1. **Codecast's own number** (Linq iMessage line). The person texts codecast, + and codecast texts the person. The number is a front door to their agents + and a channel for asks that need them. +2. **The person's mail** (through Whisk). Every session can read and draft it, + on any machine. New mail is an event that wakes work. +3. **The person's own iMessage** (through their Mac). This works the same way + as mail, relayed by the daemon that already runs there. + +Calendar, contacts and voice follow once these are in place (phase 4). + +## What exists today + +| Piece | Where | State | +|---|---|---| +| Whisk app-token connect, sealed token, mail + calendar tools for the hosted assistant | `convex/whisk.ts`, `convex/lib/whisk.ts`, `platform/packages/assistant` | Built. Behind `WHISK_CONNECT_OPEN`. Only the hosted assistant uses it | +| Whisk Gmail engine: Pub/Sub push, sealed Google tokens, `gmail.modify` | `~/src/mail` | Production. Google verification is shared across Whisk and codecast (`lib/apps.ts:10`) | +| `whisk subscribe` | `~/src/platform/packages/cli-kit/src/subscribe.ts` | A local `cast trigger` with a precheck that polls every 5 min. Only runs on one machine | +| Linq adapter: chats, typing, tapbacks, media, contact card, groups, link-free opener, stranger handling, pairing codes | Averil `packages/server/src/gateway/adapters/linq.ts`, `gateway/inbound.ts`, `gateway/pairing.ts` | Production on Postgres/Hono. Not portable as code. The logic and quirks carry over | +| Linq HMAC verification and missed-webhook reconciler | Union `outreach/backend/src/middleware/webhookAuth.ts`, `jobs/reconcileLinqEvents.ts` | Production | +| iMessage core: chat.db reader, AppleScript send, tapbacks, scopes, unix-socket service | `~/src/imsg` (MIT, ours) | Production inside Averil.app | +| Mac relay: poll chat.db every 1 s, POST rows, SSE stream for sends | Averil `tools/imsg/src/bridge.ts` | Production. Relays the whole archive. Sends as the person with no approval by default | +| Signed macOS helper holding TCC grants | `packages/cli/src/computer/helperApp.ts` (`sh.codecast.computer`) | Built (Accessibility, Screen Recording) | +| Approval for consequential actions | `session_decisions` / `askCore`, `components/consequential` | Built | +| Inbound message channels | Slack only (`lib/slackHttp.ts`) | No SMS, iMessage or email channel | + +## Design + +### 1. Codecast's number + +**One line to start, on codecast's own Linq partner account.** Numbers are +assigned by a Linq rep and can't be bought through the API (`/v3/phone_numbers` +lists and updates; there is no purchase endpoint). Linq load-balances across +lines when the `from` field is left out. So when volume needs a second line, +we add it to the pool and nothing else changes. + +**The number belongs to the person, never to strangers.** Linq forbids cold +outreach and flags a line that opens around 50 new conversations a day. Codecast +never texts a number first. Every chat starts with the person texting in, after +they pair the number in the app. + +**Pairing.** In Settings > Phone, the person enters their number and texts the +6-digit code the screen shows to codecast's number. That proves the person +controls the phone and opens the chat inbound-first, which is the Linq rule. +The pairing is a new row on the `users` side: +`phone_links {user_id, handle (E.164), linq_chat_id, verified_at, opted_out_at}`. + +A text from a number with no pairing gets one fixed reply with a sign-in link, +and wakes nothing (Averil's `strangers.ts` behaviour). + +**What a text does.** + +- *Inbound.* The text becomes a user message in the person's **personal + anchor**, which is the standing session that answers for them. + - The anchor routes it through its general tools: it answers, sends to a + session (`cast send`), starts work, or answers an open decision. + - We don't build a text-specific router. The anchor already has the context + and tools. Per the prompt rules, it only needs to be told that the message + came by text and that replies go back by text. + - Replying to a codecast text is threaded with `reply_to`. If the text being + replied to was a decision card, the anchor gets the decision id with the + message. +- *Outbound.* A new delivery rail beside push in `notifications.ts` and + `pushRouter.ts`, for the kinds the person turns on. The default is + **decisions and blockers only**: a `cast decide` card, a session going + `blocked`, and a deploy that failed. The rail obeys the same rule as push: it + holds while the desktop is active. + - A decision text carries the question and the numbered options. Replying + "2" answers it. + - Anything longer than one screen becomes a link to a native screen. + - Links never go in the first message of a chat (Linq error 1005, the + Averil opener fix). +- *Compliance.* STOP/START/HELP are handled before the anchor sees anything. + Opt-out is recorded on `phone_links`. A reply ratio and a daily cap per line + are tracked against Linq's guidance (7k a day per line; slow down on + `NEEDS_ATTENTION`, pause on `DELIVERY_LIMITED`, both read from + `phone_number.status_updated`). + +**Plumbing (Convex).** + +- `POST /linq/webhook` in `http.ts`. It verifies HMAC-SHA256 over + `{timestamp}.{body}` from `X-Webhook-Signature` and `X-Webhook-Timestamp`, + and rejects anything older than 5 minutes. This follows the Union middleware. + Averil's secret-in-URL scheme isn't used. + - Events are deduped on the Linq message id into a `channel_messages` table. +- `channels/linq.ts` holds the adapter: send, typing, reactions, contact card, + attachments. It's ported from Averil as logic, not code. +- A reconciler cron runs every 10 min. It pages `listChats` and `listMessages` + since a cursor and replays anything the webhook missed (Union's + `reconcileLinqEvents`). +- Secrets: `LINQ_API_KEY`, `LINQ_WEBHOOK_SECRET` on prod Convex. The line's + number is a config row, not an env var, so a second line needs no deploy. + +**Group chats** (phase 4). The person adds codecast to a group with teammates. +Codecast answers there only when addressed, the way Averil does +(`linq.ts:535`). It's left out of v1. + +### 2. The person's mail, first class + +Whisk stays the engine. It holds the Google verification, the sealed Google +tokens and the Pub/Sub sync. Codecast never touches a Google token. + +- **Open the connect.** Flip `WHISK_CONNECT_OPEN` once the Google project's + user cap allows it. Settings > Integrations > Mail already exists + (`useLaneMail.ts`). +- **Every session gets mail, server-side.** Today only the hosted assistant + uses the Whisk token. + - `cast mail …`: a thin verb set (`ls`, `search`, `read`, `draft`, `send`, + `reply`, `archive`) served by `/cli/mail/*` routes. The routes call Whisk + with the person's sealed app token. + - The result: a session on a cloud host, or on someone else's machine the + person owns, works the same as one on the laptop. + - The `whisk` CLI keeps working. `cast mail` is the path that needs no local + login. +- **Mail is an event.** Whisk already gets Gmail push. + - Add one outbound webhook from Whisk to codecast, `POST /whisk/events`, + signed with the app secret. It fires for new incoming mail on connected + accounts. + - Codecast turns that into `cast trigger --on mail` (filters: `from:`, + `thread:`, `lane:`). `whisk subscribe` then becomes a server trigger with + no precheck poll. + - The local precheck path stays as a fallback for older clients. +- **Sending is the person's.** `cast mail send` and `reply` go through the + consequential confirm flow unless the person asked for that send in the same + thread. + - The agent states which message it's acting on. The decision card shows + the recipients and the body. + - Drafts need no confirm. + - This replaces today's prose rule ("make sure they asked"). + +### 3. The person's own iMessage + +- **The daemon is the relay.** It replaces Averil.app and the `imsg` binary + borrowed from inside it. + - `~/src/imsg` is ours (MIT) and already exports `./messages`, `./service` + and `./permissions`. It becomes a vendored `@platform/imsg` package. + - The Full Disk Access and Automation grants go on the existing signed helper + `sh.codecast.computer`. It already holds Accessibility and Screen Recording. + The helper runs `imsg serve` as its child, which inherits the grants, on + `~/.imsg/service.sock`. This is the same trick Averil uses. + - Setup is one more row on https://codecast.sh/setup/computer. + - *To verify first:* that a launchd-started helper keeps FDA across helper + updates (the code signature must stay stable). +- **Relay less than Averil does.** Nothing is mirrored to the server by + default. Reads are live calls from a session to the daemon on the person's + Mac: + - The session runs `cast imsg read `. + - The call is routed to the Mac, the same way `cast computer` remote calls + are routed (`remoteGrant.ts`). + - The result comes back. +- **Events without a mirror.** The daemon watches chat.db (1 s watermark, as + `bridge.ts` does). It posts only an event envelope (chat id, sender handle, + timestamp, no body) to `cast trigger --on imessage`, filtered by `from:` or + `chat:`. The woken session reads the body live. +- **Sending** goes through the same confirm as mail. Codecast's own Linq chat + with the person is excluded from the relay, so the two never echo. + +### 4. Privacy: who can see a session that read your texts + +This is the hard part. A tool result is part of the transcript, and transcripts +are visible to the team by default. Memory records a personal anchor running in +a team-shared repo whose decisions and transcript reached colleagues. Reading a +person's texts or mail inside a team-visible session would publish them. + +The proposed rule: + +- Personal tools (`cast mail`, `cast imsg`, inbound texts) run only in a + session that is private to the person who owns the data. +- A team-visible session that calls one is told to fork a private session for + that step. The general fork path does this; no new mechanism is needed. +- Ownership is checked against the data owner, not the caller. An agent that + works for Samvit can never read Ashot's mail. + +The rule applies per session through `patchConversationVisibility`, so linked +work items get the right workspace key. + +The alternative, redacting tool output in team views, is listed in the +decision card. It's weaker: summaries and later replies leak what the raw +output said. + +### 5. Phones + +The phone app gets native screens, per the UI rules. It never opens a web +page: + +- Settings > Phone (pair, unpair, which kinds text you). +- Mail and Messages rows in Integrations. +- A text-answered decision shows as answered in the decision queue. + +## Phases + +``` +P0 phone_links + channel_messages tables, privacy rule for personal tools +P1 Linq line: webhook + HMAC, pairing, inbound to anchor, decision/blocker texts, STOP, reconciler +P2 Mail: cast mail verbs server-side, Whisk -> codecast event webhook, --on mail triggers, send confirm +P3 iMessage: @platform/imsg, helper FDA grant, daemon live reads, --on imessage events, send confirm +P4 Calendar events as triggers, contacts lookup, Linq group chats, Linq voice (call codecast's number -> a call with your anchor) +``` + +P1 and P2 are independent and can run in parallel. P3 depends on the helper +grant check. P0 lands first, because every later phase obeys the privacy rule. + +## Outside dependencies + +- **A Linq line for codecast.** This needs a person to contact Linq, set up a + partner account (or add a line to an existing one), and agree pricing. The + Codecast workspace has no Linq key today. The only one in the vault is + Union's (`sec-272`). +- **Google user cap** for opening Whisk connect to the public (CASA). Already + tracked in `codecast-for-everyone.md`. +- **A Whisk change** (the event webhook) in `~/src/mail`. diff --git a/packages/cli/orchestration/skills/orchestrate/SKILL.md b/packages/cli/orchestration/skills/orchestrate/SKILL.md index 26cb219b39..d633c7cbb7 100644 --- a/packages/cli/orchestration/skills/orchestrate/SKILL.md +++ b/packages/cli/orchestration/skills/orchestrate/SKILL.md @@ -11,7 +11,7 @@ You are now acting as a **conductor** — your job is to drive a plan to complet 1. Read plan state 2. Identify ready tasks (unblocked, unclaimed) 3. Group into a wave of independent work -4. Spawn implementer agents (max 3-5 parallel, worktree-isolated) +4. Spawn implementer workers (max 3-5 parallel, each in its own `cast ws` worktree) 5. When workers complete, spawn reviewers for their output 6. Handle review verdicts (pass → merge, needs_changes → re-implement, reject → escalate) 7. If all tasks done → run integration verification + critic sweep @@ -71,17 +71,19 @@ they touch, from what you found while exploring. ## Spawning workers -For each ready task, spawn an implementer agent in an isolated worktree: +For each ready task, spawn an implementer as a worker under this session, in a worktree of its own named for the task: -``` -Agent( - name: "impl-", - subagent_type: "implementer", - isolation: "worktree", - prompt: "Implement task : \n\nPlan: \n" -) +```bash +cast spawn --subagent --as implementer --worktree impl- --no-merge-back -- - <<'EOF' +Implement task : + +Plan: + +EOF ``` +`--worktree` makes the tree with `cast ws`, under `.codecast/worktrees/impl-` on branch `codecast/impl-`, with the repo's env files copied, its install run and its own ports. Every implementer gets one, even in a wave of one: its change is unreviewed until a reviewer passes it, and the worktree is what keeps it out of this checkout until then. `--no-merge-back` holds the change there; you bring it in after the review passes. Never give a worker a tree from your harness's own worktree isolation or a raw `git worktree add`: those trees get no env files, install or ports, and codecast's worktree cleanup, `cast land` and merge-back do not see them. Each worker that settles wakes you with a message naming it; `cast sessions … --until` waits here instead. + Spawn up to 3-5 workers per wave. Prefer fewer workers touching independent file scopes over many workers risking conflicts. Pass each worker: @@ -104,12 +106,8 @@ cast task show **If the worker succeeded** (task marked done): - Spawn a reviewer agent to check the work: - ``` - Agent( - name: "review-", - subagent_type: "reviewer", - prompt: "Review task on branch codecast/. Plan: " - ) + ```bash + cast spawn --subagent --as reviewer -- "Review task in .codecast/worktrees/impl- (branch codecast/impl-). Plan: " ``` **If the worker is blocked** (BLOCKED marker): @@ -117,7 +115,7 @@ cast task show - Decide: can you unblock it (re-scope, split task, fix dependency)? Or escalate to the user? **If the worker failed silently** (no status update): -- Check if the worktree has changes: `git -C .codecast/worktrees/ diff --stat` +- Check if the worktree has changes: `git -C "$(cast ws path impl-)" status -sb` - If no changes, re-queue the task - If partial changes, review them and decide @@ -125,7 +123,7 @@ cast task show Read the reviewer's comment on the task: -- **PASS** → The task is done. Record it and check what's now unblocked. +- **PASS** → Bring the change into this checkout with `cast land diff "$(cast ws path impl-)" | git apply`, then `cast ws destroy impl-`. If it does not apply cleanly, send the implementer back to rebase its tree onto what this checkout now holds. Then record the task as done and check what's now unblocked. - **NEEDS_CHANGES** → Re-spawn the implementer with the review feedback. Max 2 review rounds, then escalate. - **REJECT** → Surface to the user with the rationale. Do not retry without human input. @@ -135,12 +133,8 @@ After all tasks in the plan are done: 1. Run the full test suite and type check 2. Spawn 2-3 critic agents in parallel to find issues: - ``` - Agent( - name: "critic-", - subagent_type: "critic", - prompt: "Critique the changes for plan . Focus on: " - ) + ```bash + cast spawn --subagent --as critic -- "Critique the changes for plan . Focus on: " ``` Give each critic a different focus: correctness/logic, security/edge-cases, UX/completeness. 3. If critics find critical/major issues, create fix tasks and run another wave. diff --git a/packages/cli/scripts/build-binaries.sh b/packages/cli/scripts/build-binaries.sh index e4cd802812..867f446560 100755 --- a/packages/cli/scripts/build-binaries.sh +++ b/packages/cli/scripts/build-binaries.sh @@ -69,7 +69,11 @@ for target in "${targets[@]}"; do outfile="$OUTPUT_DIR/codecast-$target" fi - bun scripts/build-with-native.ts src/main.ts --compile --target="bun-$target" --minify --sourcemap --outfile="$outfile" + # --no-compile-autoload-dotenv: a compiled bun binary otherwise loads the .env + # of whatever directory it runs in into process.env, and every gh, git and + # agent cast spawns inherits it. A repo's stale GITHUB_TOKEN made gh answer + # 401 inside a flow's merge step (ct-102613). + bun scripts/build-with-native.ts src/main.ts --compile --no-compile-autoload-dotenv --target="bun-$target" --minify --sourcemap --outfile="$outfile" echo " -> $outfile" done diff --git a/packages/cli/scripts/codecast-local b/packages/cli/scripts/codecast-local index f218f94445..0a2d61cb42 100755 --- a/packages/cli/scripts/codecast-local +++ b/packages/cli/scripts/codecast-local @@ -1,4 +1,5 @@ #!/usr/bin/env bash # Dev wrapper for codecast CLI - runs from source SCRIPT_DIR="$(cd "$(dirname "$(readlink -f "$0" || echo "$0")")" && pwd)" -exec bun run "$SCRIPT_DIR/../src/main.ts" "$@" +# --no-env-file: never load the .env of the directory cast runs in (ct-102613). +exec bun --no-env-file run "$SCRIPT_DIR/../src/main.ts" "$@" diff --git a/packages/cli/src/__fixtures__/install-golden/existing/check.md b/packages/cli/src/__fixtures__/install-golden/existing/check.md index c267ef7ee1..e08f88aa34 100644 --- a/packages/cli/src/__fixtures__/install-golden/existing/check.md +++ b/packages/cli/src/__fixtures__/install-golden/existing/check.md @@ -36,6 +36,6 @@ cast check web # one project by name, or any directory or tsconfig path cast check --fresh # restart a watcher that lost track, then ask ``` -If a pass is running or queued, wait on it rather than run your own `tsc`. A worktree holds a program of its own (gigabytes per project), so give worktrees only to the agents whose edits would collide. When a check is red with errors nobody wrote, suspect the `.codecast/check.toml` entry before the code. `cast guide check` covers that file. +If a pass is running or queued, wait on it rather than run your own `tsc`. A worktree holds a program of its own (gigabytes per project), so give worktrees only to the agents whose edits would collide, and make each with `cast ws acquire `, which puts it under `.codecast/worktrees/` with its env files, ports and install and removes it with `cast ws destroy `; never a raw `git worktree add` at a path of your own. When a check is red with errors nobody wrote, suspect the `.codecast/check.toml` entry before the code. `cast guide check` covers that file. diff --git a/packages/cli/src/__fixtures__/install-golden/existing/decide.md b/packages/cli/src/__fixtures__/install-golden/existing/decide.md index 05a39d684f..b9b58ade15 100644 --- a/packages/cli/src/__fixtures__/install-golden/existing/decide.md +++ b/packages/cli/src/__fixtures__/install-golden/existing/decide.md @@ -42,10 +42,10 @@ What you would pick and why, then what the choice turns on. EOF ``` -**The card is the whole message, written for someone who was not here.** The person answering knows the product and its people but did not follow this session: they read the card once, in their queue or on their phone, with nothing else open, and answer without opening the session. Name things the way they would. The names this work coined, its shorthand, and ids or references only the session explains (a task, a trigger, a script, "the rule from earlier") mean nothing to them, and neither does a pointer back to something said earlier in the session, their own words included: say what the thing is instead. The question is the choice as they would put it to themselves. Each option says what happens to the product or the people it reaches, then `::` and the fact that sizes it. The context opens on what you would pick and why, then gives only what the choice turns on: the finding that forces it, what cuts against your pick, and what you do meanwhile. It reads in a minute, under 150 words; how you got there and the supporting detail go in `--report report.html`. Every number and claim on it is one the session established; an estimate says so. Before posting, read the card as that person: whatever they would have to ask you about, rewrite. After posting, don't repeat the options. +**The card is the whole message, written for someone who was not here.** The person answering knows the product and its people but did not follow this session: they read the card once, in their queue or on their phone, with nothing else open, and answer without opening the session. Their queue holds every product and team they run: say which this is. Name things the way they would. The names this work coined, its shorthand, and ids or references only the session explains (a task, a trigger, a script, "the rule from earlier") mean nothing to them, and neither does a pointer back to something said earlier in the session, their own words included: say what the thing is instead. The question is the choice as they would put it to themselves. Each option says what happens to the product or the people it reaches, then `::` and the fact that sizes it. Asked to approve something concrete (words going out, a design, a list), they judge the thing itself, on the card or as its page (`--report` takes a file or a published url), never a description of it. The context opens on what you would pick and why, then gives only what the choice turns on: the finding that forces it, what cuts against your pick, and what you do meanwhile. It reads in a minute, under 150 words; how you got there and the supporting detail go in `--report report.html`. Every number and claim on it is one the session established; an estimate says so. Before posting, read the card as that person: whatever they would have to ask you about, rewrite. After posting, don't repeat the options. -**A step only the person may take** (a grant, a spend, a pairing, an approval) is a permission ask, never a command to type: `cast decide "?" --run "cast …"` runs it as theirs on Yes (`--on laptop` from a cloud host). A refusal that posted an approval card has asked already: end your turn. +**Whatever you need from a person reaches them as a card they answer in this conversation, never a command to run or type.** A value only they hold (an email, a date, a name): `cast decide "" --line "