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
gettz on Python 3 fails with TypeError when passed bytes #927
Comments
To be clear, a The problem is more that the raised error is unhelpful and should consider raising the |
@labrys Thanks for the report, sorry for the delay in responding. I agree with the proposed solution. For anyone who is interested in implementing this - please benchmark your solution for the non-failing condition. I am not sure having a nice error message for this is worth a significant performance hit when someone is properly passing |
@pganssle A try-except-raise should have little to no effect for valid values, but definitely no harm in profiling it :) |
Given the following code on Python 3.7:
A
TypeError
is raised:The text was updated successfully, but these errors were encountered: