If there is any issue with commit, pega shows the message "PyCommitError: A Commit can not be performed because a deferred save of instance of class failed".
It looks like the Final activity commitWithErrorHandling handles this error message. Since it is final, we can't override this rule. As per requirements, we need to show user friendly message like "Sorry... Something went wrong. Pls try again later"
Pls help on how to acheive this customization and override all pega technical messages with user friendly message (See attachment for the pyCommitError)
***Moderator Edit-Vidyaranjan: Updated SR details***
The intend of such a message is to debug the root cause.
It's a technical exception, not business. Thus, it should never appear on production.
But if you concern about quality of your code on production, you could try to observe - what activity is calling that final activity commitWithErrorHandling . I hope you'll be able to bubble up until you find non-Final activity and override it - just in case of errors, use Clear messages method and add your own message.