-
Notifications
You must be signed in to change notification settings - Fork 66
Add decision records (ADRs) with template and 0001 on package versioning #1108
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,19 @@ | ||
| # NNNN: Short decision title | ||
|
|
||
| - **Status:** accepted <!-- accepted | superseded by [NNNN](./NNNN-slug.md) --> | ||
| - **Date:** YYYY-MM-DD | ||
|
|
||
| ## Context | ||
|
|
||
| What question or situation forced the decision. A few sentences on the relevant | ||
| system state and constraints, with links to code or docs. | ||
|
|
||
| ## Decision | ||
|
|
||
| What was decided, in one or two sentences. Decisions **not** to build something | ||
| count and should be recorded. | ||
|
|
||
| ## Consequences | ||
|
|
||
| What follows: what stays simple, what gets harder, and what would trigger | ||
| revisiting. When a preferred future shape is known, name it. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,49 @@ | ||
| # 0001: No user-facing package versioning or import pins | ||
|
|
||
| - **Status:** accepted | ||
| - **Date:** 2026-07-31 | ||
|
|
||
| ## Context | ||
|
|
||
| Every saved package is a real git repo on Cloudflare Artifacts with full commit | ||
| history, publish notes (readable via `repo_show_publish_note`), and a clonable | ||
| remote (`package_get_git_remote`). Runtime surfaces — `packages.invoke`, | ||
| package-owned jobs, apps, services, and webhooks — always resolve the package's | ||
| current `entity_sources.published_commit`, and published bundles for non-current | ||
| commits are pruned after 30 days. Static cross-package imports | ||
| (`kody:@scope/pkg/export`) snapshot the dependency's published commit at the | ||
| dependent's publish time and refresh only when the dependent republishes; the | ||
| platform never auto-republishes dependents. | ||
|
|
||
| The question: should packages get product-level versioning (semver releases, a | ||
| versions UI, runnable old versions), and should cross-package imports support an | ||
| explicit version/tag/commit pin? | ||
|
|
||
| ## Decision | ||
|
|
||
| No to both. History, diffing, and rollback are served by the package's git repo. | ||
| Cross-package imports keep the implicit "snapshot at publish, refresh on | ||
| republish" contract, with no pin syntax in specifiers or | ||
| `package.json#kody.dependencies`. | ||
|
|
||
| Rationale: the consumer of a personal package is almost always its own author, | ||
| so there is no downstream consumer needing a semver stability contract; the one | ||
| cross-user surface (community forks) already pins by commit | ||
| (`community_listings.pinned_commit`, `community_forks.origin_commit`); and | ||
| pinned old versions would escape fleet package codemods, which keep published | ||
| trees healthy precisely because platform APIs evolve. | ||
|
|
||
| ## Consequences | ||
|
|
||
| - Runtime resolution stays single-pointer (current published commit), and | ||
| published-bundle retention stays at 30 days for non-current commits. | ||
| - Users who want stability can tag commits in their package repo (labels for | ||
| humans, never read by the platform), hold off republishing a dependent until | ||
| ready, or fork a dependency into a frozen copy under another name. | ||
| - Surfacing what already exists — a publish-history view backed by `git log` | ||
| plus publish notes, or a one-click "revert to this publish" — remains open and | ||
| cheap; it is UX over existing plumbing, not a versioning system. | ||
| - If real demand for import pins appears, the preferred shape is commit-SHA pins | ||
| declared in `package.json#kody.dependencies` (not new specifier grammar), | ||
| resolved by rebuilding from Artifacts at that commit, with a staleness warning | ||
| in repo checks. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,22 @@ | ||
| # Decision records | ||
|
|
||
| Short architecture decision records (ADRs) for choices that shape the platform, | ||
| including decisions **not** to build something. Check here before proposing a | ||
| change that may already have been decided. | ||
|
|
||
| Decision records are point-in-time documents, so they are exempt from | ||
| `npm run docs:check-temporal`; everything else in `docs/` describes current | ||
| behavior (see [documentation principles](../documentation.md)). | ||
|
|
||
| ## Adding a record | ||
|
|
||
| 1. Copy [`0000-template.md`](./0000-template.md) to the next number with a short | ||
| kebab-case slug (for example `0002-some-decision.md`). | ||
| 2. Keep it to roughly half a page: context, decision, consequences. | ||
| 3. When a later record changes a decision, mark the old one `superseded by NNNN` | ||
| rather than editing or deleting it. | ||
| 4. Add the record to the list below. | ||
|
|
||
| ## Records | ||
|
|
||
| - [0001 — No user-facing package versioning or import pins](./0001-no-package-versioning.md) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.