Skip to content

Desktop: allow one replay launch at a time - #3848

Merged
ashhart merged 2 commits into
ashhart:mainfrom
AIflow-Labs:codex/fix-3845-replay-launch
Nov 20, 2026
Merged

ashhart merged 2 commits into
ashhart:mainfrom
AIflow-Labs:codex/fix-3845-replay-launch

Conversation

@AIFlowML

@AIFlowML AIFlowML commented Nov 18, 2026 •

Copy link
Copy Markdown
Contributor

What this changes

Allow one Desktop replay launch at a time. A second click before the first launch finishes cannot create another task. The Replay button shows the pending state, becomes available after a failure, and a late result from the previous panel cannot close a reopened one.

  • Issue: Fixes Desktop Replay as new task can launch the same bundle twice #3845
  • Stacked on: main at ac9c1fe362e9c17a92f26e7d3e9ab59197063ffb
  • atc overlap --json: ATC found no local worktree conflicts and could not finish its PR scan. The paginated file audit at 2026-11-18T16:08:53Z checked both paths and rename origins across 483 open heads with no overlaps. This head test-merges with main and the 48 open contributor heads.

Checks on this head

  • Head commit: cb522ee9e9104966da0f746b873e48479a2c980b
  • Lean checker: 221 inherited findings on base and head, zero new. python3 tools/pr_check.py --base upstream/main reported zero errors and warnings.
  • Focused regression: The same two click handlers create two synthetic task records and send two launch calls on main. The candidate creates one and disables Replay while admission is pending. The fixture uses the production renderer store with fake IPC and checks retry after both setup and admission failures, and late success after a close and reopen.
  • Desktop on M5 Max, Node 22.23.3: npm run typecheck, npm run build, and npm run verify:mobile passed. npm test passed all 891 files in the local integration tree 91cecd192b5a49d2b010a9893a154b1aab8676fc. Standalone passed 861 of 862 files with the inherited Git assertion in sandbox-git-control.test.ts.
  • Native host: The unchanged native tree at this base passed 12,241 tests with 105 skips and zero unexpected golden differences under zig build test test-golden -Dcpu=apple_m1 on M5 Max with Zig 0.17.0. The inherited macOS memcpy link guard is tracked by macOS native binary links internal memcpy after the device profile reader landed #3760 and addressed by Restore libSystem memcpy when reading device profiles #3761. zig fmt --check build.zig zig and git diff --check passed.
  • CI: The original Desktop and pytest failures predate this contribution. See the current-main check below.
  • CI follow-up: The Desktop rerun passed. The pytest rerun checked historical merge 8efc7c7a8da4ff48788ed5113fe70f13604ed304, whose base predates Use a deterministic clock in the benchmark TTFT test #3783. I reproduced its TTFT assertion failure by injecting a send-clock value of 1.0002 into that checkout. The same injected clock passes on the unchanged PR head merged with current main dffe424859c47bab40ce09bfdf91d07eabff23b2 (local merge 235229726da570ca6bfbbc712e8e30977deb3239), which includes Use a deterministic clock in the benchmark TTFT test #3783. The full benchmark module passed 31 tests and 18 subtests there.
  • Not run: Manual Electron launch on Windows or Linux, or live model execution. The renderer regression uses an inert prompt and simulates admission.

Current-main integration check

Tested local merge 1a2e343e922caf326382298c6e19972631536c45 on upstream 144964f8dcee8e569c1570f8cbc33305d4d48ea8 with the five open AIFlowML heads. The original macOS Desktop and Python jobs failed in the guest output-limit and benchmark TTFT tests. #3698 and #3783 are included in the tested base. Their previously failing paths passed locally. All 893 Desktop test files passed in the combined tree, along with typecheck, mobile verification and build. The affected benchmark module passed 31 tests and 18 subtests.

Receipt

N/A. This change gates concurrent launches from the Desktop Replay control and does not reach inference.

Checklist

  • The title, head and receipts agree.
  • The same regression fails on main and passes on this head.
  • Comments and docstrings are one line.
  • Public identity and privacy checks passed.

Igor Lessio - AIFLOW LABS

@ashhart

ashhart commented Nov 18, 2026

Copy link
Copy Markdown
Owner

Hi @AIFlowML, thanks for the reproduction.

A synchronous guard now admits one launch per click burst, the Replay button shows the pending state and re-enables after a failure, and a result from a panel that was closed and reopened no longer closes the new one. The regression covers rapid clicks, retry after both failure points and the late success. The change stays in the Desktop replay panel and applies to current main.

The red desktop job is the guest output-limit check hitting macOS's EPERM, which #3698 fixes; pytest is the benchmark TTFT test #3783 fixes. Neither comes from this change. No changes needed from our side.

  • Synthena

@ashhart
ashhart force-pushed the codex/fix-3845-replay-launch branch from cb522ee to e0ea806 Compare November 20, 2026 12:53
@ashhart
ashhart merged commit 79504af into ashhart:main Nov 20, 2026
9 of 16 checks passed
@ashhart

ashhart commented Nov 20, 2026

Copy link
Copy Markdown
Owner

Thank you @AIFlowML. This is merged into main with your commits under your own name, so you're listed as a TensorFold contributor. It ships in the next release, credited to you in the changelog and the release notes.

ashhart added a commit to AIflow-Labs/TensorFold that referenced this pull request Nov 20, 2026
ashhart added a commit that referenced this pull request Nov 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Desktop Replay as new task can launch the same bundle twice

2 participants