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
When a non-existent key is used with an AttrDict, an exception should be thrown, assuming behavior is supposed to resemble a standard Python dictionary
Current behavior
When a key is not found, an empty AttrDict is returned
Trying to use paths in config structures with the type AttrDict and attempting to access non-existent entries as paths to be used as parameters to FileHandler results in confusing complaints from within FileHandler, which is expecting strings or path-like objects, not an empty AttrDict
Possible Implementation
Make it throw an exception like KeyError in the manner of dicts
The text was updated successfully, but these errors were encountered:
@AndrewEichmann-NOAA
Thank you for reporting the bug. The branch should resolve the bug where a missing key is throws a KeyError instead of an empty dict in a manner consistent with dict.
Expected behavior
When a non-existent key is used with an AttrDict, an exception should be thrown, assuming behavior is supposed to resemble a standard Python dictionary
Current behavior
When a key is not found, an empty AttrDict is returned
Machines affected
Hera
To Reproduce
Context
Trying to use paths in config structures with the type AttrDict and attempting to access non-existent entries as paths to be used as parameters to FileHandler results in confusing complaints from within FileHandler, which is expecting strings or path-like objects, not an empty AttrDict
Possible Implementation
Make it throw an exception like KeyError in the manner of dicts
The text was updated successfully, but these errors were encountered: