chore(examples): update messages_stream.py shebang from rye to uv#1519
Open
lucky-verma wants to merge 1 commit intoanthropics:nextfrom
Open
chore(examples): update messages_stream.py shebang from rye to uv#1519lucky-verma wants to merge 1 commit intoanthropics:nextfrom
lucky-verma wants to merge 1 commit intoanthropics:nextfrom
Conversation
The project migrated from rye to uv (CONTRIBUTING.md), and most examples already use the uv shebang. messages_stream.py was the last leftover with the rye shebang. Companion to anthropics#1497 (poetry to uv) which covered four other older examples. No requirements-rye.lock exists in the repo, so running this example with ./examples/messages_stream.py would fail unless rye happens to be installed globally.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Updates the shebang line in
examples/messages_stream.pyfrom#!/usr/bin/env -S rye run pythonto#!/usr/bin/env -S uv run python.Why
The project migrated from rye to uv (documented in
CONTRIBUTING.md), and newer examples likeagents.py,agents_comprehensive.py, andagents_with_files.pyalready use the uv shebang.messages_stream.pywas the only remaining example still using the rye shebang.This is a companion fix to #1497, which converted four other older examples from
poetrytouv. Norequirements-rye.lockexists in the repo anymore, so running this example with./examples/messages_stream.pywould fail unless a user happened to have rye installed globally.Verification
ruff check examples/messages_stream.py→ All checks passed!ruff format --check examples/messages_stream.py→ 1 file already formattedpython -c "import ast; ast.parse(open('examples/messages_stream.py').read())"→ OK