@farmslot/protocol 0.74.0 → 0.74.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +19 -9
- package/README.md +9 -0
- package/dist/client-cache/cache.d.ts +4 -0
- package/dist/client-cache/cache.d.ts.map +1 -0
- package/dist/client-cache/cache.js +1102 -0
- package/dist/client-cache/cache.js.map +1 -0
- package/dist/client-cache/collector-admission.d.ts +29 -0
- package/dist/client-cache/collector-admission.d.ts.map +1 -0
- package/dist/client-cache/collector-admission.js +183 -0
- package/dist/client-cache/collector-admission.js.map +1 -0
- package/dist/client-cache/command-method.d.ts +5 -0
- package/dist/client-cache/command-method.d.ts.map +1 -0
- package/dist/client-cache/command-method.js +2 -0
- package/dist/client-cache/command-method.js.map +1 -0
- package/dist/client-cache/conformance.d.ts +36 -0
- package/dist/client-cache/conformance.d.ts.map +1 -0
- package/dist/client-cache/conformance.js +578 -0
- package/dist/client-cache/conformance.js.map +1 -0
- package/dist/client-cache/content.d.ts +29 -0
- package/dist/client-cache/content.d.ts.map +1 -0
- package/dist/client-cache/content.js +101 -0
- package/dist/client-cache/content.js.map +1 -0
- package/dist/client-cache/d07-domains.d.ts +17 -0
- package/dist/client-cache/d07-domains.d.ts.map +1 -0
- package/dist/client-cache/d07-domains.js +111 -0
- package/dist/client-cache/d07-domains.js.map +1 -0
- package/dist/client-cache/diff-apply.d.ts +29 -0
- package/dist/client-cache/diff-apply.d.ts.map +1 -0
- package/dist/client-cache/diff-apply.js +206 -0
- package/dist/client-cache/diff-apply.js.map +1 -0
- package/dist/client-cache/index.d.ts +14 -10
- package/dist/client-cache/index.d.ts.map +1 -1
- package/dist/client-cache/index.js +14 -1
- package/dist/client-cache/index.js.map +1 -1
- package/dist/client-cache/keys.d.ts +126 -0
- package/dist/client-cache/keys.d.ts.map +1 -0
- package/dist/client-cache/keys.js +25 -0
- package/dist/client-cache/keys.js.map +1 -0
- package/dist/client-cache/native-history.d.ts +64 -0
- package/dist/client-cache/native-history.d.ts.map +1 -0
- package/dist/client-cache/native-history.js +285 -0
- package/dist/client-cache/native-history.js.map +1 -0
- package/dist/client-cache/prefetch.d.ts +50 -0
- package/dist/client-cache/prefetch.d.ts.map +1 -0
- package/dist/client-cache/prefetch.js +507 -0
- package/dist/client-cache/prefetch.js.map +1 -0
- package/dist/client-cache/registry.d.ts +1365 -0
- package/dist/client-cache/registry.d.ts.map +1 -0
- package/dist/client-cache/registry.js +1038 -0
- package/dist/client-cache/registry.js.map +1 -0
- package/dist/client-cache/run-list-versions.d.ts +70 -0
- package/dist/client-cache/run-list-versions.d.ts.map +1 -0
- package/dist/client-cache/run-list-versions.js +309 -0
- package/dist/client-cache/run-list-versions.js.map +1 -0
- package/dist/client-cache/store.d.ts +128 -0
- package/dist/client-cache/store.d.ts.map +1 -0
- package/dist/client-cache/store.js +190 -0
- package/dist/client-cache/store.js.map +1 -0
- package/dist/client-cache/transport.d.ts +27 -0
- package/dist/client-cache/transport.d.ts.map +1 -0
- package/dist/client-cache/transport.js +56 -0
- package/dist/client-cache/transport.js.map +1 -0
- package/dist/client-cache/types.d.ts +116 -0
- package/dist/client-cache/types.d.ts.map +1 -0
- package/dist/client-cache/types.js +2 -0
- package/dist/client-cache/types.js.map +1 -0
- package/dist/client-cache/upstream-retention.d.ts +6 -0
- package/dist/client-cache/upstream-retention.d.ts.map +1 -0
- package/dist/client-cache/upstream-retention.js +28 -0
- package/dist/client-cache/upstream-retention.js.map +1 -0
- package/dist/client-cache/workspace-retention.d.ts +7 -0
- package/dist/client-cache/workspace-retention.d.ts.map +1 -0
- package/dist/client-cache/workspace-retention.js +46 -0
- package/dist/client-cache/workspace-retention.js.map +1 -0
- package/dist/contracts/provider-accounts.d.ts +31 -0
- package/dist/contracts/provider-accounts.d.ts.map +1 -1
- package/dist/contracts/provider-accounts.js +209 -1
- package/dist/contracts/provider-accounts.js.map +1 -1
- package/dist/contracts/run-bundles.d.ts.map +1 -1
- package/dist/contracts/run-bundles.js +2 -0
- package/dist/contracts/run-bundles.js.map +1 -1
- package/dist/contracts/runs.d.ts +2 -0
- package/dist/contracts/runs.d.ts.map +1 -1
- package/dist/contracts/runs.js.map +1 -1
- package/dist/index.d.ts +4 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +4 -1
- package/dist/index.js.map +1 -1
- package/dist/person-session-client.d.ts +4 -1
- package/dist/person-session-client.d.ts.map +1 -1
- package/dist/person-session-client.js.map +1 -1
- package/dist/rpc/auth.d.ts +17 -0
- package/dist/rpc/auth.d.ts.map +1 -1
- package/dist/rpc/auth.js.map +1 -1
- package/dist/rpc/config.d.ts +2 -0
- package/dist/rpc/config.d.ts.map +1 -1
- package/dist/rpc/config.js.map +1 -1
- package/dist/rpc/fs.d.ts +110 -4
- package/dist/rpc/fs.d.ts.map +1 -1
- package/dist/rpc/fs.js +7 -1
- package/dist/rpc/fs.js.map +1 -1
- package/dist/rpc/gateway.d.ts +3 -0
- package/dist/rpc/gateway.d.ts.map +1 -1
- package/dist/rpc/git.d.ts +42 -0
- package/dist/rpc/git.d.ts.map +1 -1
- package/dist/rpc/index.d.ts +1 -0
- package/dist/rpc/index.d.ts.map +1 -1
- package/dist/rpc/index.js +1 -0
- package/dist/rpc/index.js.map +1 -1
- package/dist/rpc/native-session.d.ts +2 -0
- package/dist/rpc/native-session.d.ts.map +1 -1
- package/dist/rpc/native-session.js.map +1 -1
- package/dist/rpc/nodes.d.ts +2 -0
- package/dist/rpc/nodes.d.ts.map +1 -1
- package/dist/rpc/nodes.js.map +1 -1
- package/dist/rpc/pr-observations.d.ts +22 -0
- package/dist/rpc/pr-observations.d.ts.map +1 -0
- package/dist/rpc/pr-observations.js +104 -0
- package/dist/rpc/pr-observations.js.map +1 -0
- package/dist/rpc/pr.d.ts +9 -0
- package/dist/rpc/pr.d.ts.map +1 -1
- package/dist/rpc/pr.js +1 -1
- package/dist/rpc/pr.js.map +1 -1
- package/dist/rpc/principal.d.ts +2 -0
- package/dist/rpc/principal.d.ts.map +1 -1
- package/dist/rpc/registry.d.ts +1 -0
- package/dist/rpc/registry.d.ts.map +1 -1
- package/dist/rpc/registry.js +2 -0
- package/dist/rpc/registry.js.map +1 -1
- package/dist/rpc/resource-observers.d.ts +32 -0
- package/dist/rpc/resource-observers.d.ts.map +1 -0
- package/dist/rpc/resource-observers.js +2 -0
- package/dist/rpc/resource-observers.js.map +1 -0
- package/dist/rpc/run.d.ts +23 -0
- package/dist/rpc/run.d.ts.map +1 -1
- package/dist/rpc/run.js.map +1 -1
- package/dist/rpc/runner-models.d.ts +15 -0
- package/dist/rpc/runner-models.d.ts.map +1 -1
- package/dist/rpc/runner-models.js +91 -0
- package/dist/rpc/runner-models.js.map +1 -1
- package/dist/runs/review-diff-identity.d.ts +15 -0
- package/dist/runs/review-diff-identity.d.ts.map +1 -0
- package/dist/runs/review-diff-identity.js +47 -0
- package/dist/runs/review-diff-identity.js.map +1 -0
- package/dist/runs/run-list-filter.d.ts +33 -0
- package/dist/runs/run-list-filter.d.ts.map +1 -0
- package/dist/runs/run-list-filter.js +116 -0
- package/dist/runs/run-list-filter.js.map +1 -0
- package/dist/runs/run-list-observation.d.ts +5 -0
- package/dist/runs/run-list-observation.d.ts.map +1 -0
- package/dist/runs/run-list-observation.js +36 -0
- package/dist/runs/run-list-observation.js.map +1 -0
- package/dist/runs/run-list-view.d.ts +6 -2
- package/dist/runs/run-list-view.d.ts.map +1 -1
- package/dist/runs/run-list-view.js +10 -4
- package/dist/runs/run-list-view.js.map +1 -1
- package/dist/slots/cancelled-run-slot.d.ts +2 -1
- package/dist/slots/cancelled-run-slot.d.ts.map +1 -1
- package/dist/sources/client.d.ts +10 -1
- package/dist/sources/client.d.ts.map +1 -1
- package/dist/sources/client.js +23 -4
- package/dist/sources/client.js.map +1 -1
- package/dist/sources/controller.d.ts +13 -14
- package/dist/sources/controller.d.ts.map +1 -1
- package/dist/sources/controller.js +87 -82
- package/dist/sources/controller.js.map +1 -1
- package/dist/sources/status-view.d.ts +2 -0
- package/dist/sources/status-view.d.ts.map +1 -1
- package/dist/sources/status-view.js +13 -0
- package/dist/sources/status-view.js.map +1 -1
- package/dist/transport/events.d.ts +1 -4
- package/dist/transport/events.d.ts.map +1 -1
- package/dist/transport/events.js +1 -0
- package/dist/transport/events.js.map +1 -1
- package/dist/transport/frames.d.ts +6 -0
- package/dist/transport/frames.d.ts.map +1 -1
- package/dist/transport/frames.js.map +1 -1
- package/dist/transport/observations.d.ts +24 -0
- package/dist/transport/observations.d.ts.map +1 -0
- package/dist/transport/observations.js +2 -0
- package/dist/transport/observations.js.map +1 -0
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +1 -1
- package/dist/sources/changes.d.ts +0 -37
- package/dist/sources/changes.d.ts.map +0 -1
- package/dist/sources/changes.js +0 -79
- package/dist/sources/changes.js.map +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -4,23 +4,33 @@ All notable changes to `@farmslot/protocol` are tracked here.
|
|
|
4
4
|
|
|
5
5
|
## Unreleased
|
|
6
6
|
|
|
7
|
-
-
|
|
7
|
+
- Active-development baseline; add user-facing changes here before release or package publication.
|
|
8
8
|
|
|
9
|
+
## 0.74.1 - 2026-10-29
|
|
10
|
+
|
|
11
|
+
- Add run list version lists (Version lists rules 1-6). `run.list` takes `versions` and `ids` and returns `versions`, with `RunListVersion`. On gateways with `capabilities.resourceChanges.versionLists`, the cache answers every run.list view from one shared collection: a runs change is one versions read, and only changed and missing ids are read, in pages. Rows are stored with `ResourceStore.getRows` and `mergeRows`, full bodies active runs first, then newest, up to the run list's bound. `runListPage`, `matchesRunList`, `sortRunList`, `runListLimit` and `RunListProjection` share the gateway's filters, a `limit` of `RUN_LIST_UNLIMITED` lists every matching run, `selectRunList` accepts projections, and `GatewayResourceCache.runListProjections` lists every live run's projection.
|
|
12
|
+
- Add conditional file edits (ADR-009 Amendment 1). `fs.read` returns `hash`, the SHA-256 of the raw bytes, on hosts that support them. `fs.write`, `fs.rename` and `fs.delete` take `expectedHash` and `runId`, and a failed precondition returns `FS_CONFLICT` with `FsConflictDetails`. `capabilities.conditionalFileWrites`, `NodeInfo.conditionalWrites` and `FS_PRECONDITION_UNSUPPORTED` mark support.
|
|
13
|
+
- Review gate payloads carry `artifactBundle`, and `decisionArtifactBundleRef` reads it. Add `activeRunDiffQuery` and `activeRunDiffBase` (stack target, then the project default branch, then main); the prefetcher takes a `defaultBranch` option. A prefetch refresh of an opened snapshot keeps it opened and evicts as a prefetch write. Sign-out skips observer withdrawal when the socket is already closed.
|
|
14
|
+
- `GatewayResourceCache.retry` accepts an abort signal; an aborted retry sends nothing and writes no result. An authorization refusal settles its callers before the eviction is written, so prefetch stops before another read leaves the cache.
|
|
15
|
+
- Add content by identity to the resource store and cache (verified diffs, git blobs and artifacts, size caps, one byte budget shared with workspace snapshots, fetch-time write tokens and aliases) and `createContentPrefetcher`, which prefetches pending gates and active runs with an exact unified-diff applier. Observed `git.diff` accepts `includeUntracked`.
|
|
16
|
+
- Export the review-diff identity functions (`reviewDiffHash`, `verifiedReviewDiffHash`, `reviewSnapshotIdentityText`) for clients and the gateway, and add `GitShowResult.id`, batched `git.show` types, `GitDiffParams.includeUntracked` and `GitDiffResult.mergeBaseSha`/`headSha`.
|
|
17
|
+
- Persist only approved gateway-status update fields with fixed error text, and accept explicit local or unsupported answers from upstream collectors without inventing a source time.
|
|
18
|
+
- Register PR detail, slot PR, review-thread, runner-seat and runner model catalog reads as upstream collectors and runner visible models as an owner-scoped observation, with pure normalizers, sanitized stored-data projections and `observation` on their results.
|
|
19
|
+
- Add `CommandMethod` and `PersonSessionMethod`. `releaseCancelledRunSlot` and cache-backed source clients take command-only transports; those source clients read status only from the shared cache.
|
|
20
|
+
- Advertise passive PR list and GitHub account observations; observer identities refuse forced checks and persist only verified account fields.
|
|
21
|
+
- Add shared upstream collector admission, source observation age/error metadata and an aggregate offline retention limit, with mixed-version refusal instead of client polling.
|
|
22
|
+
- Register memory-only PR automation, assessment, analytics and shared copilot observations with canonical selectors and scoped change dependencies.
|
|
23
|
+
- Allow combined findings approval and evidence attestation when every review reason explicitly permits accepting findings.
|
|
9
24
|
- Share one navigation-only current-view link model across Companion and Command Center, with explicit HTTPS deployment bindings and unavailable reasons.
|
|
10
|
-
|
|
11
25
|
- Expose slot workspace publication, ownership and recovery identity with shared eligibility for guarded fleet release and update.
|
|
12
|
-
|
|
13
26
|
- Expose current CI-watch progress and total deadlines so clients use the monitor’s configured windows.
|
|
14
|
-
|
|
15
27
|
- Expose checklist timing in task progress and per-step worker durations in monthly analytics.
|
|
16
|
-
|
|
28
|
+
- Add experimental verified node observation admission for shared, nonpersisted worker inventory reads, with mixed-version refusal and structured producer failures.
|
|
17
29
|
- Share source-first, deduplicated run reference links between Command Center and Companion; show shared total and current-step elapsed time on the existing metadata line.
|
|
18
|
-
|
|
19
30
|
- Add shared linked-ticket lookup and operator ticket metadata on runs without changing frozen task inputs.
|
|
20
|
-
|
|
21
31
|
- Register source-linked PR-completion criteria without replacing original obligations, and bind readiness to acceptance and proof-contract revisions.
|
|
22
|
-
|
|
23
|
-
-
|
|
32
|
+
- Add the opt-in node file-watch observation contract for explicit deletion and read failures, retaining the existing content-event shape for coordinated node and gateway upgrades.
|
|
33
|
+
- Add the experimental ADR-071 resource query cache and store seam, persisted Sources/run/decision/fleet/node/capability/progress observations with shared retention bounds, bounded native history with mobile-compatible cancellation and reader-private native keys, revision stamps, change event, and principal-generation capability contract for coordinated client and gateway releases. Accepted observations remain saved when a connection pauses or a view closes. Automatic refetches respect declared family publish intervals even across slow replies; deferred reads retire with their observers and connection. Saved facts hydrate through offline reconnect attempts, while authority changes fence pending storage reads. Fleet observations share one 2 MB query and leave force-refresh commands outside the cache. Read errors survive disconnects, and saved-data refreshes retain the last failure until a successful replacement arrives. A source change during a failed read schedules one replacement read; authority and not-found refusals remain final. Register bounded backlog, roadmap, work-graph, dispatch-queue and project collections with canonical planning/configuration keys. Project configuration persists within one aggregate 2 MiB bound; previews and registration metadata stay in memory, and commands stay outside cached queries.
|
|
24
34
|
|
|
25
35
|
## 0.74.0 - 2026-10-28
|
|
26
36
|
|
package/README.md
CHANGED
|
@@ -7,6 +7,14 @@ This package is intentionally small at runtime: it exports protocol constants,
|
|
|
7
7
|
TypeScript types, and validation helpers. It does **not** execute recipes, talk
|
|
8
8
|
to browsers/devices, or contain project-specific actions.
|
|
9
9
|
|
|
10
|
+
The experimental `@farmslot/protocol/client-cache` is the portable ADR-071 client
|
|
11
|
+
controller shared by Command Center and Companion. It owns query identities,
|
|
12
|
+
freshness and the `ResourceStore` seam; socket and storage adapters remain with
|
|
13
|
+
their platform owners. It requires gateway builds advertising
|
|
14
|
+
`capabilities.resourceChanges.version: 1`. Older published gateway builds are
|
|
15
|
+
reported as unsupported, without panel polling. Protocol, gateway and client
|
|
16
|
+
builds containing this unreleased contract must be released together.
|
|
17
|
+
|
|
10
18
|
## Canonical documents
|
|
11
19
|
|
|
12
20
|
The npm package is a consumable API surface. The source-of-truth architecture is
|
|
@@ -51,6 +59,7 @@ import {
|
|
|
51
59
|
| --------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------- |
|
|
52
60
|
| `@farmslot/protocol` | Root import for common recipe validators, constants, shared contracts, RPC names, and transport helpers. |
|
|
53
61
|
| `@farmslot/protocol/contracts` | Shared domain data contracts. |
|
|
62
|
+
| `@farmslot/protocol/client-cache` | Experimental shared resource cache, memory store and portable store conformance contract. |
|
|
54
63
|
| `@farmslot/protocol/contracts/runs` | Run, run-family, evidence, and publication contracts. |
|
|
55
64
|
| `@farmslot/protocol/contracts/slots` | Slot and slot-adjacent contracts. |
|
|
56
65
|
| `@farmslot/protocol/rpc` | Gateway RPC method registry and typed method maps. |
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import type { GatewayResourceCache, GatewayResourceCacheOptions } from './types.js';
|
|
2
|
+
/** Experimental ADR-071 controller. It opens no sockets and never accepts a command. */
|
|
3
|
+
export declare function createGatewayResourceCache(options: GatewayResourceCacheOptions): GatewayResourceCache;
|
|
4
|
+
//# sourceMappingURL=cache.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cache.d.ts","sourceRoot":"","sources":["../../src/client-cache/cache.ts"],"names":[],"mappings":"AAoCA,OAAO,KAAK,EACV,oBAAoB,EACpB,2BAA2B,EAS5B,MAAM,YAAY,CAAC;AAuFpB,wFAAwF;AACxF,wBAAgB,0BAA0B,CACxC,OAAO,EAAE,2BAA2B,GACnC,oBAAoB,CAsnCtB"}
|