Getting an error that a flow “was” activate and cannot be overwritten

I’m using Salesforce Migration Tool (Ant) to deploy flows and processes. If memory serves, so long as the flow in the destination org was not activate (or deactivated) I could overwrite it. If you didn’t disable the flow first, I’d get this error:

Error: The version of the flow you’re updating is active and can’t
be overwritten

Now I am getting an error that tells me that the flow “was” active and cannot be overwritten, even after disabling the flow in the target org:

Error: The version of the flow you’re updating was active and
can’t be overwritten

Perhaps this was the way it has always been and I’m just taking crazy pills. Either way, the only way I see around this is to create a new version all flows I want to deploy each time I want to deploy them. Or, never make the deployed flows activate in the target org, which will make testing them quite difficult.

Any suggestions on ways to numb this pain?


Once activated, a flow version can never be modified. In fact, about the only reasonable approach is to delete all paused interviews, deactivate the current flow version, delete all references to the flow, delete the flow entirely, then deploy the flow and all its references back in place.

This restriction exists because if a flow was active, it could have paused interviews or interviews already in progress, and so changing the flow’s properties could invalidate those interviews. This is obviously an undesirable state since users would lose data, but it’d be a lot handier if Salesforce would simply check to see if there were any paused or active interviews and allow deletion or modification of a version if it’s reasonably safe to do so.

Source : Link , Question Author : Swisher Sweet , Answer Author : Swisher Sweet

Leave a Comment