@@ -977,6 +977,7 @@ def update_prod_environment_check(
977977 status : GithubCheckStatus ,
978978 conclusion : t .Optional [GithubCheckConclusion ] = None ,
979979 skip_reason : t .Optional [str ] = None ,
980+ plan_error : t .Optional [PlanError ] = None ,
980981 ) -> None :
981982 """
982983 Updates the status of the merge commit for the prod environment.
@@ -990,6 +991,7 @@ def conclusion_handler(
990991 GithubCheckConclusion .CANCELLED : "Cancelled deploying to prod" ,
991992 GithubCheckConclusion .SKIPPED : skip_reason ,
992993 GithubCheckConclusion .FAILURE : "Failed to deploy to prod" ,
994+ GithubCheckConclusion .ACTION_REQUIRED : "Failed due to error applying plan" ,
993995 }
994996 title = (
995997 conclusion_to_title .get (conclusion )
@@ -1002,6 +1004,11 @@ def conclusion_handler(
10021004 summary = (
10031005 captured_errors or f"{ title } \n \n **Error:**\n ```\n { traceback .format_exc ()} \n ```"
10041006 )
1007+ elif conclusion .is_action_required :
1008+ if plan_error :
1009+ summary = f"**Plan error:**\n ```\n { plan_error } \n ```"
1010+ else :
1011+ summary = "Got an action required conclusion but no plan error was provided. This is unexpected."
10051012 else :
10061013 summary = "**Generated Prod Plan**\n " + self .get_plan_summary (self .prod_plan )
10071014 return conclusion , title , summary
0 commit comments