Repository navigation
docs: fix Python 2 leftovers in docstrings - #182
Merged
Merged
Conversation
- auth.py: replace py2-style 'print (...)' output line with a py3 print() call showing the expected authorization URL - objects.py (Walker): use '...' continuation and print() in doctest examples instead of py2 'print' statement syntax No code behavior change.
This was referenced Oct 27, 2026
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.
Summary
Removes two Python 2 leftovers that would break under any py3 doctest runner and read oddly in the rendered docs:
flickr_api/auth.pymodule docstring:print ('http://…')(a py2 print-statement artifact, note the stray spacing) replaced with>>> print(a.get_authorization_url('write'))plus its expected URL output.flickr_api/objects.pyWalkerdocstring:>>> print photo.titlepy2 syntax in the example loops replaced with... print(photo.title).No code behavior change; docstrings only.
Test Plan
uv run pytest: 291 passed locallyAutomated prep by Hermes maintainer.