fix: remove description field from lean payload#1956
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
🚅 Deployed to the anticapture-pr-1956 environment in anticapture-infra
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 18aef3474e
ℹ️ About Codex in GitHub
Codex has been enabled to automatically 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 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| description: z.string().optional().openapi({ | ||
| description: "Proposal body. Omitted when the request sets `lean=true`.", | ||
| }), |
There was a problem hiding this comment.
Regenerate downstream contracts for lean responses
After making description optional/omitted for lean=true, the committed downstream contract snapshots still describe it as required: apps/gateful/openapi/gateful.json:1121 lists description in required, and apps/api-gateway/schema.graphql:1620 has description: String!. Those files are consumed by SDK/GraphQL generation (packages/anticapture-client/kubb.config.ts:31, packages/graphql-client/codegen.ts:5), so clients generated from this commit will still require a field that the API now omits for lean proposal calls.
Useful? React with 👍 / 👎.
The onchain proposals contract now omits `description` when `lean=true`, making it optional in the generated client. Guard the description tab against the undefined case. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: d56279a0e8
ℹ️ About Codex in GitHub
Codex has been enabled to automatically 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 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| --- | ||
| "@anticapture/api": patch | ||
| "@anticapture/gateful": patch | ||
| "@anticapture/api-gateway": patch |
There was a problem hiding this comment.
Regenerate the gateway schema before publishing
Fresh evidence in the current commit is that the REST OpenAPI snapshot was updated, but this changeset still publishes @anticapture/api-gateway while apps/api-gateway/schema.graphql:1620 continues to declare OnchainProposal.description: String!. When GraphQL callers pass lean: true, the upstream API now omits that field, so GraphQL will treat the missing non-null value as an execution error/null parent instead of returning the lean proposal payload.
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 9e8af0fe31
ℹ️ About Codex in GitHub
Codex has been enabled to automatically 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 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| "@anticapture/api": patch | ||
| "@anticapture/gateful": patch | ||
| "@anticapture/api-gateway": patch |
There was a problem hiding this comment.
Bump the generated REST client package
Because this changeset updates the Gateful OpenAPI contract for /proposals but only bumps @anticapture/gateful, external consumers of @anticapture/client will not get a new published SDK with the variant union and lean responses that omit description. The client package is generated from apps/gateful/openapi/gateful.json during its codegen/build task and does not depend on @anticapture/gateful, so Changesets will not publish it unless it is listed here as well.
Useful? React with 👍 / 👎.
No description provided.