Repository navigation
docs: record declined Effect Schema wire-contract convention - #286
Conversation
|
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 6a9521c113
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| The projections currently have nothing to bridge. Every wire contract in | ||
| `packages/agent-bundle/src/contracts/*` is JSON-plain: timestamps are strings, | ||
| there are no `Date`, `bigint`, `Map`, `Set`, or transformations, and the | ||
| encoded and type sides are structurally identical. `toType` / `toEncoded` |
There was a problem hiding this comment.
Narrow the all-contracts claim to the audited DTOs
In the checked contract barrels, this claim is already contradicted: contracts/mcp-session.ts exposes McpSessionTraceEntry.occurredAt as Unix milliseconds in a number, while contracts/runtime.ts uses export type * and therefore exposes DevRuntimeAsset.body: Uint8Array. The latter is not JSON-plain at all. Since this section records the evidence future re-pin and Schema-adoption decisions should rely on, scope the statement to the JSON DTO routes actually audited or account explicitly for these nonmatching contracts.
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
Fixed in 3c2240169. The Schema section now scopes the JSON-plain claim to the audited JSON DTO routes and explicitly names the numeric McpSessionTraceEntry.occurredAt and binary DevRuntimeAsset.body exceptions.
Summary
Schema.toType/Schema.toEncodedprojections) for the wire-contract seams against[email protected]; decision = not adopted this RC cycle.docs/effect-conventions.mdwith the concrete reasons (near-identity projections over JSON-plain DTOs, parse-option-only exact-key strictness vsz.strictObject, +46.5 kB min / +14.6 kB gzip Workbench bundle delta while zod must stay for MCP SDK interop, AB-code diagnostics fit) and GA/divergent-contract revisit criteria — mirroring the@effect/platform-nodeprecedent (docs: record declined Effect platform services convention #271).Test plan
pnpm lint(docs-only change; no changeset)