-
Notifications
You must be signed in to change notification settings - Fork 0
release: 4.1.0 #62
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
release: 4.1.0 #62
Conversation
6c2b6c5 to
a594c75
Compare
85e4dfe to
1322c80
Compare
2bb4c49 to
7e69125
Compare
7cdfb0a to
ca310cd
Compare
fix(client): mark some request bodies as optional
3bdb00f to
3ad7f25
Compare
1be6ce9 to
97b7254
Compare
35a4088 to
bc25b84
Compare
ef0d130 to
08062c4
Compare
9257acd to
b41543a
Compare
df1d708 to
69a44e3
Compare
cf36bae to
bba1424
Compare
e0b03f0 to
3d90dff
Compare
84a0625 to
db19786
Compare
359644d to
21a20b3
Compare
873e0de to
9ef228a
Compare
9ef228a to
e4ed00c
Compare
e4ed00c to
a72636d
Compare
a72636d to
b7b5b98
Compare
b7b5b98 to
f7c66f3
Compare
| if metadata is not None and len(metadata) > 0: | ||
| meta: tuple[Any, ...] = tuple(metadata) | ||
| elif is_annotated_type(type_): | ||
| meta = get_args(type_)[1:] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Bug: Annotated types not unwrapped when metadata provided directly
The construct_type function has a bug where Annotated types are not unwrapped when metadata is provided directly. The comment says "unwrap Annotated[T, ...] -> T" but when the first branch is taken (metadata non-empty), type_ remains wrapped as Annotated[T, ...]. This causes get_origin(type_) to return Annotated, which doesn't match any type handlers (list, dict, BaseModel, etc.), so nested types like Annotated[list[MyModel], PropertyInfo(...)] won't have their items properly constructed. The elif is_annotated_type(type_) branch that unwraps the type is skipped when metadata is provided.
Additional Locations (1)
f7c66f3 to
f0262a9
Compare
f0262a9 to
3524f04
Compare
3524f04 to
9bd1046
Compare
9bd1046 to
f263f8c
Compare
f263f8c to
5cddd6f
Compare
5cddd6f to
590d7c8
Compare
590d7c8 to
07aac58
Compare
07aac58 to
d01a3f6
Compare
Automated Release PR
4.1.0 (2026-01-14)
Full Changelog: v4.0.0...v4.1.0
Features
NotGivenfor body (#67) (3ad7f25)X-Stainless-Read-Timeoutheader (#63) (a594c75)Bug Fixes
model_dumpandmodel_dump_jsonfor Pydantic v1 (898ca7b)Chores
httpx-aiohttpversion to 0.1.9 (7aeb4c8)--fixargument to lint script (0b1e68e)pyproject.tomlfile (f87b268)get_platformtest (ef07d85)Documentation
This pull request is managed by Stainless's GitHub App.
The semver version number is based on included commit messages. Alternatively, you can manually set the version number in the title of this pull request.
For a better experience, it is recommended to use either rebase-merge or squash-merge when merging this pull request.
🔗 Stainless website
📚 Read the docs
🙋 Reach out for help or questions
Note
Release 4.1.0
DefaultAioHttpClient(optionalaiohttpextra) and binary request streaming; newfollow_redirectsoption; emitX-Stainless-Read-Timeout; improved file uploads and header handling; non-recursive retry logicSequenceNotStr,omit/not_given, and pagination support for JSON bodies0.44.0; refine branch filtersDockerfile/devcontainer.json, add Node featurepyproject.toml; removemypy.ini; update lockfiles and scripts (lint/test/bootstrap, upload-artifact)CHANGELOG.mdadded for 4.1.0; API docs tweaks (api.mdresponse types)Written by Cursor Bugbot for commit d01a3f6. This will update automatically on new commits. Configure here.