Skip to content

Conversation

@jonathan343
Copy link
Contributor

@jonathan343 jonathan343 commented Oct 20, 2025

Important

This PR is reliant on the packages in smithy-lang/smithy-python#580 being released to PyPI.

Summary

This PR creates v0.1.1 of aws-sdk-bedrock-runtime and aws-sdk-python using the latest Smithy Python code generator, core packages, and bedrock runtime service model.

Why patch and not minor version bump?
Removing the serialize.py and deserialize.py modules is technically breaking, however, these modules aren't used by any client code starting in v0.1.0. These modules should have been cleaned up but were missed in the previous release. There is no valid reason for users to be importing these modules directly. Additionally, I searched through GitHub and found 0 matches for aws_sdk_bedrock_runtime.serialize and aws_sdk_bedrock_runtime.deserialize. Keeping this a patch bump reduces the friction for customers adopting this change since most will receive the update automatically.

Testing

(aws-sdk-bedrock-runtime) $ uv pip install dist/aws_sdk_bedrock_runtime-0.1.1-py3-none-any.whl pyaudio rx --find-links ~/dev/GitHub/smithy-python/dist         
Resolved 11 packages in 16ms
Installed 11 packages in 1.19s
 + aws-sdk-bedrock-runtime==0.1.1 (from file:///Users/gytndd/dev/GitHub/aws-sdk-python/clients/aws-sdk-bedrock-runtime/dist/aws_sdk_bedrock_runtime-0.1.1-py3-none-any.whl)
 + aws-sdk-signers==0.1.0
 + awscrt==0.28.2
 + ijson==3.4.0.post0
 + pyaudio==0.2.14
 + rx==3.2.0
 + smithy-aws-core==0.1.1
 + smithy-aws-event-stream==0.1.0
 + smithy-core==0.1.0
 + smithy-http==0.2.0
 + smithy-json==0.1.0

This installs the smithy-aws-core==0.1.1 and smithy-http==0.2.0 from smithy-lang/smithy-python#580.


By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@jonathan343 jonathan343 changed the base branch from develop to main October 20, 2025 20:10
@jonathan343 jonathan343 changed the base branch from main to develop October 21, 2025 14:49
@jonathan343 jonathan343 marked this pull request as ready for review October 21, 2025 14:55
@jonathan343 jonathan343 requested a review from a team as a code owner October 21, 2025 14:55
## v0.1.1

### API Changes
* New stop reason (`MODEL_CONTEXT_WINDOW_EXCEEDED`) for Converse and ConverseStream.
Copy link
Contributor

Choose a reason for hiding this comment

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

nit; we won't be getting these kinds of updates from the normal model releases. We should consider if we want to keep this to using the "official" service team release notes rather than writing our own.

Copy link
Contributor Author

@jonathan343 jonathan343 Oct 21, 2025

Choose a reason for hiding this comment

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

The "official" service team release note is New stop reason for Converse and ConverseStream. I added the MODEL_CONTEXT_WINDOW_EXCEEDED part to provide clarity. I'll update to use the exact service note though

Reference: https://github.com/boto/botocore/blob/develop/CHANGELOG.rst#L252

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Addressed in d0f4286

* **Updated**: `smithy_http[awscrt]` from `~=0.1.0` to `~=0.2.0`.

### Breaking
- Removed unused `serialize.py` and `deserialize.py` modules.
Copy link
Contributor

Choose a reason for hiding this comment

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

Were these being surfaced publicly through an __all__ or interceptors? I don't actually recall but curious about the scope of this call out.

Copy link
Contributor Author

@jonathan343 jonathan343 Oct 21, 2025

Choose a reason for hiding this comment

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

No, the modules exist in v0.1.0 but aren't used by anything. I mainly called it out since someone could technically be doing import aws_sdk_bedrock_runtime.serialize or import aws_sdk_bedrock_runtime.deserialize. The probability of that though is near 0. I have some context in the PR summary about this.

Copy link
Contributor

Choose a reason for hiding this comment

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

Yeah that's fine. I'm asking at a higher level about our public contract with this. It's implying we may have been expecting someone to do this.

We handle these cases in boto3 because we have a very fuzzy contract. We don't want to carry that forward in this product. It should be extremely clear what is a public interface and then we treat everything else as private.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Oh I see, I think you saying these should have originally been _serialize.py and _deserialize.py so it's clear to customers these are internal only and shouldn't be used directly. I agree

@jonathan343 jonathan343 merged commit 2016aa5 into develop Oct 21, 2025
2 checks passed
@jonathan343 jonathan343 deleted the next-release branch October 21, 2025 20:12
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