|
| 1 | +# Pre-launch TODOs |
| 2 | + |
| 3 | +This list is deliberately launch-oriented rather than a feature roadmap. |
| 4 | + |
| 5 | +## P0 — complete before users can share repositories |
| 6 | + |
| 7 | +- [X] Make `push` and `pull` reject divergent history and check the CAS result. |
| 8 | + They currently copy objects and then move the destination branch without |
| 9 | + proving that the destination head is an ancestor; they also report success |
| 10 | + when `compare_and_set_branch_ref` returns `False`. CAS prevents a race, not |
| 11 | + a destructive non-fast-forward update. Add two-client divergence and |
| 12 | + concurrent-update tests for both directions. |
| 13 | +- [x] Add a release gate that runs: non-integration tests, real S3 integration, |
| 14 | + an isolated install of the built wheel, CLI smoke tests, and a clean-tree |
| 15 | + check. Implemented in `.github/workflows/ci.yml`: |
| 16 | + `test-and-build` (non-integration tests + build + clean-tree + artifact upload), |
| 17 | + `s3-integration` (real S3 against MiniStack), |
| 18 | + `isolated-install-smoke` (wheel install in fresh venv + CLI smoke), |
| 19 | + and `release-gate` (unified gate depending on all three). |
| 20 | + The `release-gate` job can be set as the single required status check |
| 21 | + in branch-protection rules. |
| 22 | +- [x] Decide and document the durability contract for `--identity meta`. |
| 23 | + Source URIs can change after a metadata-only import; label such revisions as |
| 24 | + unverifiable until `verify`, warn in CLI output, and document the required |
| 25 | + source-retention policy. |
| 26 | + Implemented: |
| 27 | + - `ManifestEntry.is_verified` property distinguishes blob-backed from |
| 28 | + metadata-only entries. |
| 29 | + - CLI warns to stderr on `add --identity meta`, `commit` with meta config, |
| 30 | + and `verify` when unverifiable entries remain. |
| 31 | + - Durability contract and source-retention policy documented in README |
| 32 | + under "Identity Modes → Durability contract for --identity meta". |
| 33 | +- [x] Publish operator runbooks for S3 IAM, encryption, bucket versioning, |
| 34 | + lifecycle/retention, backups, lock recovery, and incident recovery. Add a |
| 35 | + supported lock inspection/cleanup command before relying on shared S3 repos. |
| 36 | + Implemented: |
| 37 | + - `docs/operator-runbook.md` covers IAM policy, SSE-S3/KMS encryption, |
| 38 | + bucket versioning, lifecycle rules, backup/restore strategies, lock |
| 39 | + recovery procedures, and five incident recovery scenarios. |
| 40 | + - `fluxel lock list` and `fluxel lock cleanup` CLI commands with `--json`, |
| 41 | + `--force`, and `--repo` flags. |
| 42 | + - `S3RepositoryStore.list_branch_locks()`, `.branch_lock_info()`, and |
| 43 | + `.force_release_branch_lock()` plus `FluxelRepository.list_locks()`, |
| 44 | + `.lock_info()`, `.force_release_lock()`, and `.lock_timeout_seconds`. |
| 45 | + |
| 46 | +## P1 — strongly recommended for the first public release |
| 47 | + |
| 48 | +- [ ] Make the configured type-check gate useful. `uv run pyrefly check` |
| 49 | + currently reports 89 errors (including exported names, protocol typing, and |
| 50 | + filesystem return types), while the config keys emit warnings. Either fix the |
| 51 | + errors or scope/configure the check deliberately, then add it to CI. |
| 52 | +- [ ] Update the README's MVP status: it says remote sync CLI is not wired, |
| 53 | + but `push`, `pull`, and `fetch` now exist. Document their safety semantics, |
| 54 | + supported remotes, and recovery workflow. |
| 55 | +- [ ] Replace whole-object sync copies with streamed transfers. The current |
| 56 | + sync helper reads each complete blob into memory and writes a temporary file, |
| 57 | + which makes large-object sync memory- and disk-heavy. |
| 58 | +- [ ] Change fsspec dataset resolution to fail for an unknown dataset instead |
| 59 | + of falling back to the current directory. A typo can otherwise read from an |
| 60 | + unintended local repository. |
| 61 | +- [ ] Test the supported-version matrix: Python 3.11 and 3.12, current fsspec, |
| 62 | + AWS S3, and the configured S3-compatible endpoint. Include interrupted |
| 63 | + transfer, stale-lock, access-denied, and corrupted-object scenarios. |
| 64 | +- [ ] Add privacy/security release checks: dependency/vulnerability scan, |
| 65 | + license review of runtime dependencies, documentation on secrets/credential |
| 66 | + handling, and a statement of telemetry behavior. |
| 67 | + |
| 68 | +## P2 — early operational follow-ups |
| 69 | + |
| 70 | +- [ ] Add remote configuration (`remote add`) and clone; requiring a full S3 |
| 71 | + URI on every sync is error-prone. |
| 72 | +- [ ] Add garbage collection with a dry-run and retention policy for unreachable |
| 73 | + blobs/manifests. |
| 74 | +- [ ] Add machine-readable release notes, versioning/migration policy, and a |
| 75 | + reproducible PyPI publishing workflow. |
| 76 | + |
| 77 | + |
| 78 | +---- |
| 79 | + |
| 80 | +Architecture? |
| 81 | + |
| 82 | + CLI / fsspec |
| 83 | + ↓ |
| 84 | + Application use cases |
| 85 | + (commit, add, verify, sync, restore, merge) |
| 86 | + ↓ |
| 87 | + Domain |
| 88 | + (commits, manifests, paths, identity, commit graph, errors) |
| 89 | + ↓ |
| 90 | + Ports |
| 91 | + (RepositoryStore, ClientState, Workspace, BlobTransfer) |
| 92 | + ↓ |
| 93 | + Adapters |
| 94 | + (local filesystem, S3, fsspec, CLI formatting) |
| 95 | + |
| 96 | +**Concretely:** |
| 97 | +* Keep ManifestEntry, path validation, hashing rules, commit graph ancestry, and domain errors pure—no Path, boto3, or CLI imports. |
| 98 | +* Make RepositoryStore the shared-object port, ClientState the local mutable-state port, and add a streaming BlobTransfer port. |
| 99 | +* Move each command into a small use case with explicit input/result objects: CommitUseCase, SyncUseCase, RestoreUseCase, etc. |
| 100 | +* Make ref updates go through one operation such as advance_ref(expected_head, new_head). The application layer must prove fast-forward ancestry and must treat a failed CAS as a conflict. |
| 101 | +* Keep immutable-object publication separate from the final ref update: upload blobs → manifest → commit → CAS branch ref. |
| 102 | +* Add one contract-test suite that every RepositoryStore implementation must pass; run it against local storage and S3-compatible storage. |
| 103 | +* Keep fsspec as a thin read adapter, not part of repository business logic. |
0 commit comments