-
Notifications
You must be signed in to change notification settings - Fork 193
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
str/bytes problems #172
Comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
While writing type stubs for ExifRead (python/typeshed#9403), I've come across a few inconsistencies/bugs that are probably related to the str/bytes changes from Python 2 to Python 3.
ord_
is only ever called with abytes
argument, but checks for astr
and returns abytes
argument unchanged:exif-py/exifread/utils.py
Lines 9 to 12 in 51d5c5a
I believe this method is mostly obsolete and could be replaced by straight calls to
ord()
.special_mode()
in tags/makernote/olympus.py is (I think) passed abytes
string and returns a regularstr
. But in the case where the passed in string is empty, it will just return it unchanged (i.e. it will returnbytes
instead ofstr
), possibly raise aTypeError
:exif-py/exifread/tags/makernote/olympus.py
Lines 5 to 26 in 51d5c5a
The text was updated successfully, but these errors were encountered: