When compose is not done yet, the BaseHandler raises ODCSComposeNotReady
exception. This is supposed to be catched by the start_to_build_images,
which pauses the rebuild until the ODCS compose is ready.
The issue is that fail_artifact_build_on_handler_exception decorator
also catches this ODCSComposeNotReady exception and marks the ArtifactBuild
as FAILED. This is wrong, because ODCSComposeNotReady exception is expected
and should not mark the build as FAILED.
This commit fixes it by introducing the whitelist kwarg in the fail_artifact_build_on_handler_exception decorator and whitelists
the ODCSComposeNotReady exception, so it does not move the build
to FAILED state, but instead just re-raises the exception so it
can be handled in start_to_build_images.
When compose is not done yet, the BaseHandler raises ODCSComposeNotReady
exception. This is supposed to be catched by the
start_to_build_images,which pauses the rebuild until the ODCS compose is ready.
The issue is that
fail_artifact_build_on_handler_exceptiondecoratoralso catches this ODCSComposeNotReady exception and marks the ArtifactBuild
as FAILED. This is wrong, because ODCSComposeNotReady exception is expected
and should not mark the build as FAILED.
This commit fixes it by introducing the
whitelistkwarg in thefail_artifact_build_on_handler_exceptiondecorator and whiteliststhe
ODCSComposeNotReadyexception, so it does not move the buildto FAILED state, but instead just re-raises the exception so it
can be handled in
start_to_build_images.