@@ -400,8 +400,12 @@ private void publishArtifact(Ambiance ambiance, StepElementParameters stepParame
400400 OptionalSweepingOutput optionalSweepingOutput = executionSweepingOutputResolver .resolveOptional (
401401 ambiance , RefObjectUtils .getSweepingOutputRefObject (artifactOutputVariableKey ));
402402 if (!optionalSweepingOutput .isFound ()) {
403- executionSweepingOutputResolver .consume (ambiance , artifactOutputVariableKey ,
404- StepArtifactSweepingOutput .builder ().stepArtifacts (stepArtifacts ).build (), StepOutcomeGroup .STAGE .name ());
403+ try {
404+ executionSweepingOutputResolver .consume (ambiance , artifactOutputVariableKey ,
405+ StepArtifactSweepingOutput .builder ().stepArtifacts (stepArtifacts ).build (), StepOutcomeGroup .STAGE .name ());
406+ } catch (Exception e ) {
407+ log .error ("Error while consuming artifact sweeping output" , e );
408+ }
405409 }
406410
407411 // we found a bug CI-7115 due to which we had to change the outcome identifier from artifact_+stepId to
@@ -410,8 +414,12 @@ private void publishArtifact(Ambiance ambiance, StepElementParameters stepParame
410414 optionalSweepingOutput = executionSweepingOutputResolver .resolveOptional (
411415 ambiance , RefObjectUtils .getSweepingOutputRefObject ("artifact_" + stepIdentifier ));
412416 if (!optionalSweepingOutput .isFound ()) {
413- executionSweepingOutputResolver .consume (ambiance , "artifact_" + stepIdentifier ,
414- StepArtifactSweepingOutput .builder ().stepArtifacts (stepArtifacts ).build (), StepOutcomeGroup .STAGE .name ());
417+ try {
418+ executionSweepingOutputResolver .consume (ambiance , "artifact_" + stepIdentifier ,
419+ StepArtifactSweepingOutput .builder ().stepArtifacts (stepArtifacts ).build (), StepOutcomeGroup .STAGE .name ());
420+ } catch (Exception e ) {
421+ log .error ("Error while consuming artifact sweeping output" , e );
422+ }
415423 }
416424
417425 String uniqueStepIdentifier = getUniqueStepIdentifier (ambiance , stepIdentifier );
0 commit comments