You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
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.
As a sanity check, look at usage of Resource.get_attributes in the ofrak repository. If any usage assumes it can return None, we will want to update them (I think this is mainly for clarity for the future)
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: