Skip to content

feat(harness): resume the exact saved Assistant runtime [SAP-3292] - #1014

Closed
ynadge wants to merge 1 commit into
assistant-continuation-nativefrom
assistant-native-resume
Closed

ynadge wants to merge 1 commit into
assistant-continuation-nativefrom
assistant-native-resume

Conversation

@ynadge

@ynadge ynadge commented Sep 14, 2026 •

Copy link
Copy Markdown
Contributor

Primary change type

  • Feature

Problem and motivation

Reopening a saved Assistant must preserve its Studio/native identity and original context, while safely reconciling lost Resume responses. Restored work must stay paused; existing live work must keep its admission state.

Summary and scope

Add same-ID Resume to the shared lifecycle operation slot. Validate the exact saved binding and private durable operation proof, preflight through an injected read-only consumer, then retain/promote the exact runtime. Keep live tokens and enabled execution; restore paused after restart. Hold publication ownership through actual durable commit/rollback/unlock so ongoing execution never sees a half-updated lease. End aborts the runtime immediately.

Related work

Related issue: https://linear.app/sapiom/issue/SAP-3292

Depends on #1012. Native stack target: main. The native-history consumer and public routes follow.

Validation

Resume, Resume-store, nativeHistory, lifecycle, End, host and OpenCode router suites — 188 passed
Full Harness server and web TypeScript — passed
Scoped ESLint and git diff --check — passed

Tests and documentation

Twenty Resume cases cover same live token/admission, exact binding, lost-ACK/restart, cleanup uncertainty, concurrent operation exclusion, End at all async boundaries, and durable commit cancellation/overlap with existing execution. Updated assistant-history.md. Increment:683 changed lines including tests/docs/changeset; pr:size is absent.

Compatibility and release impact

  • Breaking or externally visible changes: additive explicit Resume lifecycle operation; never creates a fallback native association or starts Terminal.
  • Changeset: added for @sapiom/harness.
  • Fix-forward: preserve exact runtime, durable operation identity and lifecycle revision while correcting admission or retry behavior.

Security

  • No secrets, credentials, private data, or unsanitized logs included.
  • No suspected vulnerability disclosed publicly.

AI assistance

  • AI assistance used: Codex implemented Resume and race tests; root reviewed the durable publication barrier and required a direct commit await before final validation.

Checklist

  • CONTRIBUTING.md read; maintainer-authorized issue work.
  • One focused increment, tests, relevant checks, documentation, and release impact addressed above.
  • I can explain and maintain the submitted changes.

Devin Review

@coderabbitai

coderabbitai Bot commented Sep 14, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Advanced

Run ID: fd4f6d0f-993e-4fc6-8ba4-4f3fff2a8727

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@devin-ai-integration devin-ai-integration Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Devin Review: No Issues Found

Devin Review analyzed this PR and found no bugs or issues to report.

Devin Review

@ynadge ynadge closed this Sep 15, 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.

1 participant