Skip to main content

This content has been archived and is no longer being updated. Links may not function; however, this content may be relevant to outdated versions of the product.

Support Article

pyCommitError on click of submit button

SA-14443

Summary



Developer creates an interaction case in the application with functionality which calls an activity. The activity contains Page-set-message and Flow-new methods.

If user fires a validation error via this page set message and then select another local action, then it clears the error message on page. At this page, user clicks a button on screen which is suppose to perform an ADD work if user clicks submit, it fails to submit and throws an error message to screen which is not expected behavior.


Error Messages



pyCommitError:** A commit cannot be performed because a deferred save of instance AB-XYZ-123 ICALL-20286 failed: code: <none> SQLState: <none> Message: <none>

Steps to Reproduce



1. Create an activity which will be called on click of a button.
2. Configure two methods Page-set-message and Flow-new on this activity.
3. Configure another local action which contains a button. configure an activity on this button which contains 'call ADD' step.
4. Run the flow and observe the behavior.



Root Cause



There were some uncommitted data present in the database due to this uncommitted data, when the second time user submits another flowaction, PRPC is throwing an error.

Once the Flow-new method fails, PRPC should rollback the all uncommitted data for the next commit operation to succeed.


Resolution



Perform the following local-change:

Configure explicit rollback method in the same activity where Flow-New is there.
This Rollback must be called only when the Flow-New method fails.

Published October 6, 2015 - Updated October 8, 2020

Was this useful?

0% found this useful

Have a question? Get answers now.

Visit the Collaboration Center to ask questions, engage in discussions, share ideas, and help others.

Did you find this content helpful?

Want to help us improve this content?

We'd prefer it if you saw us at our best.

Pega Community has detected you are using a browser which may prevent you from experiencing the site as intended. To improve your experience, please update your browser.

Close Deprecation Notice
Contact us