bpmn-visualization-js
bpmn-visualization-js copied to clipboard
[BUG] Extra parsing of `lane` elements which are not in the BPMN spec
Describe the bug
Currently, in [email protected], we parse the Lane from a LaneSet and from a Process directly. (See the ProcessConverter https://github.com/process-analytics/bpmn-visualization-js/blob/v0.26.0/src/component/parser/json/converter/ProcessConverter.ts#L95)
However according to the BPMN specification, Lane lane is defined only within a LaneSet.
So, the Lanes are not parsed correctly.
To Reproduce Steps to reproduce the behavior:
- Load a bpmn file with a wrong format (
lanedirectly inprocessand nolaneset) - See no error and the lane is display
Expected behavior The lane should be not displayed, and we should have a warning/error for the bad format.
Desktop (please complete the following information):
- Version 0.25.3, 0.26.0
Additional context If we remove the bad parsing, there is:
- 7 tests failed in BpmnJsonParser.lane.test.ts
- no error in the integration tests
- no error in the e2e tests
BPMN Specification
When a `Lane` is defined it is contained within a `LaneSet`, which is contained within a `Process`.
ℹ️ For more information: https://www.omg.org/spec/BPMN/2.0.2/PDF
⚠️ Check the contribution guidelines for BPMN support
I have checked the reference files in the bpmn-miwg-test-suite repository. All the files that have lanes declare laneset > lane, never declare lanes directly.
If this is in the BPMN specification, this is what it was expected. With this is verification, this is for sure. 🤟🏿