'type' can't be pending-approval

Hi There,
I’m new to codefresh. I’m trying to create a work-flow where there is an approval stage prior to deploying to production. There are multiple production instances that I need to deploy to, and I’m attempting to create an approval for each of those deployments.

I referenced Approval · Codefresh | Docs while creating the yaml, but see an error ‘type’ can’t be pending-approval. Below is a snippet of the yaml thats causing this error. What is likely to be the cause of this error?

Screen Shot 2021-08-06 at 10.10.55 AM

Thanks for your help with this

Hello.

You are trying to use an approval step inside a parallel workflow. Is this what you actually want?
I am not even sure how that would work.

Can you explain a bit what you want to accomplish?

Hi @Kostis
I work with Vidya and I can explain further.
Yes, we would love a scenario where we can add an approval step inside a parallel workflow. We want to have two approval steps actually and then also have two deploy steps that will each be dependent on the approval steps.
We tried it sequentially and it is at least not throwing any error.

Furthermore, we have a child issue. When we tried creating the pipeline sequentially, we seem to be seeing the approval steps and the deploy steps in duplicates :confused:

Hello

I am not sure that approval steps are supported in a parallel pipeline. An approval step pauses the pipeline. So if there are other steps that are still running, I think the behavior is undefined. I think it is better if you ask our support team for the exact behavior

Regarding approval steps in serial pipelines this should work out of the box. We already have several examples on this Production and Staging deployments · Codefresh | Docs or Progressive Delivery · Codefresh | Docs.

If you see something double in child pipelines then again we need to see if it is a problem on our side (a bug).

Please post the sequential yaml that you are trying to use, and also open a ticket (from the top right menu) so that our support team can check the duplicates.

Got it. We actually see double in the pipeline UI but definitely not in the yaml.

Should we post the yaml here or just open a ticket and follow up with support?

Meanwhile, in both examples you shared links for, I can see that none of the stages had any steps in parallel. While the step we want to use the approval in is serial, there are steps from previous stages that are parallel. Could that be a possible reason for our issue?

Created a bug ticket here anyways => Duplicate steps in UI for pipeline after adding approval step

Hello

When I say open a ticket I mean from the Codefresh UI

On the top right menu there is a support option that allows you to create a ticket with Zendesk. This is an internal system and will be handled by our support team.

Thanks and sorry for the confusion.

1 Like