docs: limit the snapshot codec to the daemon among use cases
- commit
- df9a5fb68f7c573edd88759e660a671e9acd258f
- author
- brice · · 2026-10-08 09:31 UTC
- committer
- brice · · 2026-10-08 09:31 UTC
- parent
- 12157ae
- signature
- GPG Verified
CD88F9E564E0102646FB6077A1A07C7C7C3E349D· arch-gpg Verified for the committer email
2 files · +2 -2
M AGENTS.md +1 -1
| @@ -31,7 +31,7 @@ go test ./internal/adapters/ipc ./internal/usecase/daemon -run '^$' -bench=. -be | |||
| 31 | 31 | The exhaustive production matrix and separate test-import policy are enforced by `boundary_test.go`; package ownership is documented in `docs/architecture.md`. | |
| 32 | 32 | ||
| 33 | 33 | - `pkg/` is reusable and never imports `internal/`. | |
| 34 | - | - Production use cases import only `internal/ports`, semantic `internal/protocol` packages, `internal/domain`, `internal/snapshotcodec`, and approved sibling use cases. | |
| 34 | + | - Production use cases import only `internal/ports`, semantic `internal/protocol` packages, `internal/domain`, `internal/snapshotcodec` (daemon only), and approved sibling use cases. | |
| 35 | 35 | - Production use cases never import `internal/protocol/wire`, concrete adapters, `internal/app`, `internal/persist`, or `internal/platform`. | |
| 36 | 36 | - `internal/ports` owns application seams, not codecs, raw frames, environment policy, or worker implementations. | |
| 37 | 37 | ||
| @@ -31,7 +31,7 @@ go test ./internal/adapters/ipc ./internal/usecase/daemon -run '^$' -bench=. -be | |||||
| 31 | The exhaustive production matrix and separate test-import policy are enforced by `boundary_test.go`; package ownership is documented in `docs/architecture.md`. | 31 | The exhaustive production matrix and separate test-import policy are enforced by `boundary_test.go`; package ownership is documented in `docs/architecture.md`. | ||
| 32 | 32 | ||||
| 33 | - `pkg/` is reusable and never imports `internal/`. | 33 | - `pkg/` is reusable and never imports `internal/`. | ||
| 34 | - | - Production use cases import only `internal/ports`, semantic `internal/protocol` packages, `internal/domain`, `internal/snapshotcodec`, and approved sibling use cases. | 34 | + | - Production use cases import only `internal/ports`, semantic `internal/protocol` packages, `internal/domain`, `internal/snapshotcodec` (daemon only), and approved sibling use cases. |
| 35 | - Production use cases never import `internal/protocol/wire`, concrete adapters, `internal/app`, `internal/persist`, or `internal/platform`. | 35 | - Production use cases never import `internal/protocol/wire`, concrete adapters, `internal/app`, `internal/persist`, or `internal/platform`. | ||
| 36 | - `internal/ports` owns application seams, not codecs, raw frames, environment policy, or worker implementations. | 36 | - `internal/ports` owns application seams, not codecs, raw frames, environment policy, or worker implementations. | ||
| 37 | 37 | ||||
M docs/architecture.md +1 -1
| @@ -60,7 +60,7 @@ main → app → usecase → ports | |||
| 60 | 60 | carriage adapters | |
| 61 | 61 | ``` | |
| 62 | 62 | ||
| 63 | - | `internal/app` may import every layer to compose the process. Adapters depend inward on ports, protocol, and domain. `internal/snapshotcodec` owns the durable snapshot format (session codec, manifests, objects, preflight); it depends only on domain and ports, and both the daemon use case and the snapshot adapter consume it. Production dependency rules and the separate test-import policy are executable in `boundary_test.go`. | |
| 63 | + | `internal/app` may import every layer to compose the process. Adapters depend inward on ports, protocol, and domain. `internal/snapshotcodec` owns the durable snapshot format (session codec, manifests, objects, preflight); it depends only on domain and ports, and only the daemon use case and the snapshot adapter consume it. Production dependency rules and the separate test-import policy are executable in `boundary_test.go`. | |
| 64 | 64 | ||
| 65 | 65 | ## UI observation and control | |
| 66 | 66 | ||
| @@ -60,7 +60,7 @@ main → app → usecase → ports | |||||
| 60 | carriage adapters | 60 | carriage adapters | ||
| 61 | ``` | 61 | ``` | ||
| 62 | 62 | ||||
| 63 | - | `internal/app` may import every layer to compose the process. Adapters depend inward on ports, protocol, and domain. `internal/snapshotcodec` owns the durable snapshot format (session codec, manifests, objects, preflight); it depends only on domain and ports, and both the daemon use case and the snapshot adapter consume it. Production dependency rules and the separate test-import policy are executable in `boundary_test.go`. | 63 | + | `internal/app` may import every layer to compose the process. Adapters depend inward on ports, protocol, and domain. `internal/snapshotcodec` owns the durable snapshot format (session codec, manifests, objects, preflight); it depends only on domain and ports, and only the daemon use case and the snapshot adapter consume it. Production dependency rules and the separate test-import policy are executable in `boundary_test.go`. |
| 64 | 64 | ||||
| 65 | ## UI observation and control | 65 | ## UI observation and control | ||
| 66 | 66 | ||||