Display contract failed constraints

When a user submit a form with complex contract constraints and one of those contraint is not valid, we get a org.bonitasoft.engine.bpm.contract.ContractViolationException

The message associated with this exception is Exception while validating constraints and we also get an empty explanations array.

Is there a way to get the list of failed contraints? Also I believe the error message used to contain the error message associated with the failed constraint but my last tests (Bonita Community 7.3.3 and 7.2.3) does not show them.

Contrainte document MimeType "application/pdf"


J'aimerais limiter le type de fichier a charger sur mon processus en PDF uniquement.
J'ai ajouter une contrainte et j'ai définie sa valeur a :

Nom : OnlyPdfDocument
expression : return pjDemandeCompteDocumentInput.getContentType() == "application/pdf" ? true : false
Message d'erreur : Veuillez charger un document de type PDF

Sur mon formulaire j'arrive a charger tout type de document.
Someone can help me

How to check an user input against a process variable in Bonita 7 ?


I can't access any process variables from a constraint script. According to the documentation, it's normal because constraints has been designed this way.

So, how can I perform advanced checks on user input ? If I do it with a script after the task has been submited, I have no way to inform the user something was wrong with his input. If I check the user input on the client side, anyone can easily bypass it.

I could make my own API to execute tasks and define my own constraints without limitations but it seems a bit overkill.