Skip to content

feat: regenerate client from latest OpenAPI spec - #294

Closed
Acconut wants to merge 1 commit into
mainfrom
mariuskleidl/cha-5310-update-backend-sdks
Closed

Acconut wants to merge 1 commit into
mainfrom
mariuskleidl/cha-5310-update-backend-sdks

Conversation

@Acconut

@Acconut Acconut commented Sep 23, 2026

Copy link
Copy Markdown
Contributor

Ticket

Summary

Regenerates the client from the current chat OpenAPI spec (make openapi off chat master). Adds poll auto-translation i18n fields (chat CHA-5308, GetStream/chat#17029):

  • PollResponseData.name_i18n / description_i18n
  • PollOptionResponseData.text_i18n
  • PollVoteResponseData.answer_text_i18n

Server-owned, read-only fields (same Optional[Dict[str, str]] shape/convention as the existing message-level i18n) — no request types changed.

The regen also picked up other spec drift accumulated since this SDK's last regeneration (feeds/video/moderation additions) — unrelated to the poll feature, just normal catch-up.

Note on style

The generator always emits List[...]/Dict[...] (from typing); a handful of poll-adjacent fields in the previously-committed file used modern lowercase list[...]/dict[...] instead (pre-existing inconsistency, not something this PR introduces intentionally — the generator itself has no option for the modern style, so regenerating reverted those specific spots back to the file's dominant convention).

Toolchain gotcha hit while regenerating

generate.sh's uv run ruff check/format calls aren't frozen. On a uv install that can't parse this lockfile's timestamp-cutoff field, that silently re-resolves and grabs newer package versions instead of erroring — I hit ruff 0.15.5 → 0.16.8, which reformats the entire generated tree into a much noisier diff. Ran this regeneration with UV_FROZEN=1 to stay on the pinned lock; might be worth baking that into generate.sh so it can't happen again.

Test plan

  • UV_FROZEN=1 make lint
  • UV_FROZEN=1 make typecheck
  • UV_FROZEN=1 make test (476 passed, 1 skipped)
  • make test-video / integration suite (needs live API credentials, not run locally)

Picks up poll auto-translation i18n fields (name_i18n/description_i18n
on Poll, text_i18n on PollOption, answer_text_i18n on PollVote), plus
other API additions accumulated since the last regeneration.

Toolchain note: generate.sh's `uv run ruff ...` calls aren't frozen,
so on an environment whose uv can't parse this lock's timestamp-cutoff
field, uv silently re-resolves and picks up newer package versions
(hit this locally: ruff 0.15.5 -> 0.16.8, which reformats the whole
generated tree). Ran this regeneration with UV_FROZEN=1 to keep the
pinned toolchain; worth adding to generate.sh itself.
@coderabbitai

coderabbitai Bot commented Sep 23, 2026

Copy link
Copy Markdown

Important

Draft PR not reviewed

Draft PRs are not automatically reviewed by default.

  • Trigger a manual review

To automatically review draft PRs, update your CodeRabbit configuration:

reviews:
  auto_review:
    drafts: true

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@Acconut

Acconut commented Sep 23, 2026

Copy link
Copy Markdown
Contributor Author

Closing — reconsidering approach for backend SDK updates.

@Acconut Acconut closed this Sep 23, 2026
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