Skip to content

feat(workspace): add lifecycle controller - #53

Merged
decode2 merged 1 commit into
masterfrom
feat/workspace-commands
Jul 19, 2026
Merged

feat(workspace): add lifecycle controller#53
decode2 merged 1 commit into
masterfrom
feat/workspace-commands

Conversation

@decode2

@decode2 decode2 commented Jul 19, 2026

Copy link
Copy Markdown
Owner

Linked issue

Closes #52

  • The linked issue has the status:approved label.

Pull request type

Select exactly one option and apply the matching type:* label.

  • Bug fix (type:bug)
  • New feature (type:feature)
  • Documentation (type:docs)
  • Refactor (type:refactor)
  • Maintenance or tooling (type:chore)
  • Breaking change (type:breaking-change)

Summary

  • Adds the platform-neutral workspace lifecycle controller for SDD task 4.2a, coordinating create, select, update, close, restart, and recovery through an injected session port.
  • Persists start/close intent so retries remain failure-idempotent across controller reconstruction, while exposing stable code/message/platform/retryable error contracts.
  • Uses a maintainer-approved size:exception for 1,062 additions across exactly four files; PR11a is a focused split from task 4.2, with Tauri/UI wiring deferred to task 4.2b.

Changes

Area or file Change
crates/splice-core/src/workspace_lifecycle.rs Adds typed identities, lifecycle/error contracts, injected port, controller operations, durable retry intent, and recovery reconciliation.
crates/splice-core/tests/workspace_lifecycle.rs Covers identity isolation, idempotency, rollback, reconstruction, persistence/session failures, structured errors, and recovery continuation.
crates/splice-core/src/workspace.rs Persists lifecycle tab/closing-session intent and exposes profile listing for recovery.
crates/splice-core/src/lib.rs Exports the lifecycle module.

Test plan

  • Ran focused checks: cargo test -p splice-core --test workspace_lifecycle (16 passed; 0 failed).
  • Ran full core tests: cargo test -p splice-core (30 passed; 0 failed, including 16 lifecycle, 9 store, and 5 unit tests).
  • Ran quality checks: cargo fmt --all -- --check and cargo clippy -p splice-core --all-targets -- -D warnings (passed).
  • Verified Windows compilation: cargo test -p splice-core --target x86_64-pc-windows-gnu --no-run (passed).
  • Exercised failure semantics through the injected runtime harness: close/start/store failures, rollback failure, reconstructed retries, convergent close errors, and multi-profile recovery all pass.
  • SDD verification passed with warnings. The unchanged Linux desktop differential baseline remains 23/24 because the Windows-only command returns UnsupportedPlatform; this PR does not touch Tauri or UI code.

Chained pull request context

  • Delivery strategy: stacked PRs to master
  • Chain position: PR11a of 17; the task 4.2 split is acknowledged.
  • Previous PR: feat(workspace): add local profile persistence #51 (workspace profile persistence, merged)
  • Next PR: task 4.2b, Tauri command registration/controller wiring (planned)
  • Review this PR first: lifecycle state transitions, durable failure intent, structured error mapping, and integration tests.
  • Intentionally out of scope: Tauri commands, desktop UI, remote synchronization/orchestration, packaging, and docs.
#51 workspace profiles (merged)
  |
  +-- PR11a lifecycle controller (this PR) [current]
        |
        +-- task 4.2b Tauri/controller wiring (next)

Review budget: 1,062 additions / 0 deletions across four files. The accepted size:exception keeps implementation and exhaustive failure-semantics tests in one rollback-safe work unit; splitting tests from behavior would reduce review integrity.

Rollback boundary: revert commit 4c3b487. This removes the lifecycle module/tests and reverts only its exports plus lifecycle persistence/listing fields; no Tauri/UI behavior or unrelated workspace persistence is removed.

Contributor checklist

  • I searched for duplicate issues and pull requests before starting.
  • I linked an approved issue using Closes, Fixes, or Resolves.
  • I selected exactly one pull request type and applied exactly one matching type:* label.
  • I completed every relevant template field and included reproducible test evidence.
  • Documentation is not required because this is an internal core slice with no user-facing command or UI; task 4.2b owns integration-facing updates.
  • My commits follow Conventional Commits.
  • My commits contain no AI attribution, including Co-Authored-By trailers.

@decode2 decode2 added the type:feature Adds or improves functionality label Jul 19, 2026
@decode2
decode2 merged commit 907bb8b into master Jul 19, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

type:feature Adds or improves functionality

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(workspace): add lifecycle controller

1 participant