Skip to content

Fixes - #155

Merged
Denis-Averin merged 5 commits into
mainfrom
fixes
Aug 21, 2026
Merged

Fixes#155
Denis-Averin merged 5 commits into
mainfrom
fixes

Conversation

@Denis-Averin

Copy link
Copy Markdown
Contributor

No description provided.

The script was a one-off helper for porting SDK examples between
languages. It was never wired into any generate script or workflow and
required an openai package that the repo never declared.
Run mypy in strict mode over everything except submodules, which are
generated SDKs checked in their own repos, and annotate the scripts that
were still untyped so the target passes.

Switch black to --extend-exclude, since --exclude replaces its default
exclude list and would make it walk the new .mypy_cache directory.
Match changelog headers on whole lines. "## 4.26.4" is a substring of
both "## 4.26.4+1" and "## 4.26.41", so a patch release or a
double-digit month silently suppressed the next entry, leaving a Dart
package version with no matching CHANGELOG entry.

Validate year, month and patch in argparse and check every file the
release touches exists before the first write. "new-version.py 26 13"
used to rewrite two configs and then die on ValueError, leaving the
remaining seven SDKs on the old version.

Update the Swift changelog alongside the Dart one. It had already
fallen a release behind the Swift config.
The C# and Java splitters exited 0 having split nothing when the
copyright banner regex found no matches, so a changed banner would ship
un-split API files and surface much later as a compile error.

Raise instead, and replace the equivalent assert in the PHP splitter so
python -O cannot strip it.
@Denis-Averin
Denis-Averin requested a review from a team as a code owner August 20, 2026 08:35
The config paths, the release file list and the nine set_*_version
functions repeated the same nine SDKs four times over. Adding an SDK
meant touching all four.

Collapse them into one SDKS tuple. The config is always
codegen/config-<name>.json and the changelog, where there is one, is
always submodules/<name>/CHANGELOG.md, so the name derives both, and the
version format defaults to the plain YY.M.P that seven of the nine use.
Adding an SDK is now one line.
@Denis-Averin
Denis-Averin merged commit 3ee5ae5 into main Aug 21, 2026
3 checks passed
@Denis-Averin
Denis-Averin deleted the fixes branch August 21, 2026 13:37
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.

2 participants