Skip to content

fix(engine): reconnect Runner parent SOPs after child retry - #1438

Open
SirLpc wants to merge 1 commit into
Tencent:mainfrom
SirLpc:fix/runner-sop-child-retry
Open

SirLpc wants to merge 1 commit into
Tencent:mainfrom
SirLpc:fix/runner-sop-child-retry

Conversation

@SirLpc

@SirLpc SirLpc commented Nov 26, 2026 •

Copy link
Copy Markdown

What changed

Retrying a failed child SOP on a pinned Runner could leave its parent run failed. Reconnect validation looked for an agent on the parent SOP node, which has no agent of its own.

After checking that the pinned Runner exists and is online, skip executor-provider lookup for the parent SOP node. The child still validates its executable nodes. The regression test verifies that the parent resumes and keeps the original child run ID.

This addresses the Runner reconnect case described in #1282.

Scope

  • Platform core / API / runner

Compatibility

Existing Runner bindings, run state, and protocols are used. No migration is required.

Validation

  • Confirmed on upstream main that the new regression test fails with the parent still in failed before the fix and passes with the fix.
  • go test ./internal/engine -run '^(TestSOP|TestRunnerCallbacksPathsBindingsAndReconnect)' -count=1 -timeout=120s passed.
  • bash scripts/build-chatbot.sh passed, including 534 tests.
  • go vet ./..., python3 scripts/check-public.py, bash scripts/scan-secrets.sh, and git diff --check passed.
  • go test -p=2 ./... -count=1 -timeout=180s hit browser test timeouts, including TestEnsureRunBrowserRestoresReclaimedWorkspaceWithStaleRun and TestBrowserStreamPushesFramesAndRunsCommands. The engine test timed out during Docker image setup on both the patched and unmodified upstream implementation.
  • The public browser acceptance suite was not run locally.

Safety

  • I did not include credentials, internal endpoints, production data, or organization-specific infrastructure.
  • I preserved user files and unrelated changes.

@Robert0622

Copy link
Copy Markdown
Collaborator

Code Review: ISSUES FOUND ⚠️

Reviewed changes: When checking whether a Runner run can reconnect, a sop node no longer goes through the agent/provider lookup (which was failing with "agent 不存在" for child LOOPs, preventing parent reconnection). The logic fix is correct and the added test is solid.

Issue found:

P2 — Merge conflict with main:
The PR does not merge cleanly into main. internal/engine/sop_node_test.go conflicts with the SOP-to-LOOP rename in #1286. Please rebase onto current main to resolve the conflict before merging.

loopforge-pr-review:fad600b29824a65df9283105aaa095b04097f780

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.

3 participants