Closed feltech closed 2 months ago
Use more appropriate and consistent exception strategy, making use of exception hierarchy migration/redesign in OpenAssetIO/OpenAssetIO#997.
This needs to be backwards compatible with a14
a14
In Python:
get
raise TypeError
set
In C++:
throw std::runtime_error
Should C++ and/or Python exceptions use the newly added exceptions? Do we need new ones?
I'd be tempted to punt all this, at least til after the beta.
What
Use more appropriate and consistent exception strategy, making use of exception hierarchy migration/redesign in OpenAssetIO/OpenAssetIO#997.
This needs to be backwards compatible with
a14
Why
In Python:
get
raise TypeError
if an unexpected type is stored in the variantset
raise TypeError
if the wrong type is passedIn C++:
get
throw std::runtime_error
if an unexpected type is stored in the variantset
the type system prevents the wrong type being passed.Should C++ and/or Python exceptions use the newly added exceptions? Do we need new ones?
I'd be tempted to punt all this, at least til after the beta.