Skip to content

docs: record declined Effect Schema wire-contract convention - #286

Merged
ScriptedAlchemy merged 1 commit into
mainfrom
wave/effect-schema-eval
Sep 2, 2026
Merged

ScriptedAlchemy merged 1 commit into
mainfrom
wave/effect-schema-eval

Conversation

@ScriptedAlchemy

Copy link
Copy Markdown
Owner

Summary

  • Evaluate Effect v4 Schema (with Schema.toType / Schema.toEncoded projections) for the wire-contract seams against [email protected]; decision = not adopted this RC cycle.
  • Add an Effect Schema wire contracts (Schema projections) section to docs/effect-conventions.md with the concrete reasons (near-identity projections over JSON-plain DTOs, parse-option-only exact-key strictness vs z.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-node precedent (docs: record declined Effect platform services convention #271).
  • Add a declined row for the Schema projections surface to the module adoptions table and cross-reference it from the error-mapping section.

Test plan

  • pnpm lint (docs-only change; no changeset)

@changeset-bot

changeset-bot Bot commented Sep 2, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: 6a9521c

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@ScriptedAlchemy
ScriptedAlchemy merged commit d6b5386 into main Sep 2, 2026
4 checks passed
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 2, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-09-02T06:09:18.634381Z 6a9521c PR opened
ℹ️ 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" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 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".

Comment on lines +244 to +247
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`

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge 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 👍 / 👎.

Copy link
Copy Markdown
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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.

@ScriptedAlchemy
ScriptedAlchemy deleted the wave/effect-schema-eval branch September 3, 2026 05:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant