-
Notifications
You must be signed in to change notification settings - Fork 126
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
Resource.get_attributes
: incorrect documentation
#452
Comments
@ANogin good catch. Are you planning on making a PR that fixes this? |
Not even sure whether the right thing is to fix the documentation or the code (I would guess documentation because the code change is likely to be very disruptive, and presumably there are plenty of cases where the caller knows the result is not None and having to every tell mypy that is annoying - of course there are also cases where the unexpected unhandled exception could things to break in harder to understand ways). P.S. BTW, only after submitting the issue I realized that the code listing's "reference in new issue" context menu for a line bypasses the usual issue template... Not sure whether it is possible+desired to create a separate template for that. |
@ANogin, yes, I'd recommend that you:
|
ofrak/ofrak_core/ofrak/resource.py
Lines 948 to 959 in 01996cf
Documentation specifies returning
None
when resource is not found, but the actual implementation is to raise an exception.The text was updated successfully, but these errors were encountered: