Consistently refuse non QName process ids.
ajeans opened this issue · 4 comments
Describe the Bug
In the modeler, when assigning an "Id" in the "General" tab, QName compliance is enforced.
If I try to input "2fa-sms", I get an error msg "Id must be a valid QName"
However, when I create a "Call Activity" element in a BPMN, I can assign a non QName value in tab "General" > "Details" > "Process Id"
AFAIU, the process-id in the call activity must match the BPMN general id, so there seems to be a consistency problem here.
Steps to Reproduce
- Create a new BPMN
- Add a call activity to it, with process-id "123"
- Save the BPMN
- Create a second BPMN
- Define its id as "123"
Expected Behavior
If QName is indeed mandatory for process-ids, it should also be enforced in the details of the call activity.
Environment
- OS: Ubuntu 20.04
- Zeebe Modeler Version: 0.9.1
Good point. Thanks for reporting!
Will be fixed upstream tracked via
We might need to also fix this in other places (to be analyzed) bpmn-js-properties-panel/issues/346.
- There is a validation already implemented (https://github.com/bpmn-io/bpmn-js-properties-panel/blob/master/lib/Utils.js#L169) and I would assume it can be re-used
- This validation is already used for the Id field (https://github.com/bpmn-io/bpmn-js-properties-panel/blob/master/lib/provider/bpmn/parts/IdProps.js#L35)
- To resolve this issue, we would also need to add that validation in zeebe modeler (https://github.com/zeebe-io/zeebe-modeler/blob/develop/client/src/app/tabs/bpmn/custom/properties-provider/parts/CallActivityProps.js)
@MaxTru Can I work on this issue?