48 lines
2.3 KiB
Markdown
48 lines
2.3 KiB
Markdown
---
|
|
id: LSN-0007
|
|
ticket: studio-docs-import
|
|
title: Pack wizard shell legacy lesson
|
|
created: 2026-03-26
|
|
tags:
|
|
- studio
|
|
- legacy-import
|
|
- pack-wizard
|
|
- packer-boundary
|
|
---
|
|
|
|
## Context
|
|
|
|
Legacy import from `docs/studio/learn/pack-wizard-shell.md`.
|
|
|
|
This lesson keeps the first-wave Studio rule for the `Pack` wizard as a shell over packer-owned operations, aligned with `docs/studio/specs/4. Assets Workspace Specification.md` and packer integration docs.
|
|
|
|
## Key Decisions
|
|
|
|
### Pack should be a Studio-owned wizard shell over packer-owned operations
|
|
|
|
**What:** The `Pack` flow should be a phase-based wizard with `Summary`, `Validation`, `Packing`, and `Result`, where Studio owns presentation and state binding while packer owns build-set summary, validation, execution, progress, and result semantics.
|
|
**Why:** A plausible-looking Studio modal can quietly reimplement packer semantics or hide operational phases. The wizard should expose those phases without pretending Studio owns build execution.
|
|
**Trade-offs:** The wizard structure is more explicit than one opaque modal state, but it keeps operational ownership honest and makes blocked, failed, and successful outcomes easier to reason about.
|
|
|
|
## Patterns and Algorithms
|
|
|
|
- Treat `Pack` as a workspace-level action over the current build set, not a selected-asset action.
|
|
- Ask packer for the build-set summary instead of recomputing it locally from navigator state.
|
|
- Use a separate validation phase that runs only on `registered + included in build`.
|
|
- Reflect packer-owned progress honestly and keep the first wave non-cancelable if packer does not support cancel.
|
|
- Make `assets.pa` the primary runtime artifact in the result summary; companion artifacts remain supporting detail.
|
|
|
|
## Pitfalls
|
|
|
|
- Treating pack summary as a local Studio recomputation.
|
|
- Using one opaque modal state instead of explicit operational phases.
|
|
- Letting unrelated assets influence wizard validation.
|
|
- Exposing fake cancel behavior unsupported by packer.
|
|
- Making companion artifacts dominate the main result summary.
|
|
|
|
## Takeaways
|
|
|
|
- The important lasting rule is ownership: Studio shells the flow, packer owns the semantics.
|
|
- Explicit phases are a didactic and operational feature, not decorative UI ceremony.
|
|
- Legacy source attribution: `docs/studio/learn/pack-wizard-shell.md`.
|