bpmn-io / bpmn-js-bpmnlint

A bpmnlint plug-in for bpmn-js.
MIT License
50 stars 15 forks source link

Empty error messages when hovering over BPMN validation issues #69

Open Tupiet opened 6 months ago

Tupiet commented 6 months ago

Describe the Bug

TL;DR: While the modeler is showing that there are some errors in a BPMN, it doesn't show the text of the errors when hovering.

I'm using the modeler layout from bpmn-js-examples, which allows me to see and create BPMN files. Then, I've added bpmn-js-bpmnlint, because I need to see the errors that are in the diagram. I've followed the steps from the bpmn-js-bpmnlint, and the result is that, while it shows the correct number of errors, when I hover the error, the message is empty.

Steps to Reproduce

  1. Clone the modeler folder from bpmn-js-examples
  2. Add bpmn-js-bpmnlint following the steps from the bpmn-js-bpmnlint page
  3. Add the bpmnlint-loader
  4. Add the .bpmnlintrc
  5. npm install
  6. npm run dev
  7. Open a BPMN file
  8. Enable the BPMN validation (click the "pill" at the bottom-center)
  9. Hover the errors
  10. See nothing in the error message

I've created a repro, if this helps: bpmn-editor.

In the repro, I've commented with an asterisk (*) the lines in src/app.js and webpack.config.js I've added that were not in the modeler base, the lines I've added to add bpmnlint.

With the repro, the steps are the following ones:

  1. git clone https://github.com/Tupiet/bpmn-editor.git
  2. cd bpmn-editor
  3. npm install
  4. npm run dev
  5. Open a BPMN file
  6. Enable the BPMN validation (click the "pill" at the bottom-center)
  7. Hover the errors
  8. See nothing in the error message
Captura de pantalla 2024-03-02 a las 13 03 49

Expected Behavior

I would expect to see the text of the errors.

Captura de pantalla 2024-03-02 a las 13 06 55

Environment

Finally, thanks for this amazing library! Feel free to ask me for more details if you need it.

Tupiet commented 6 months ago

If this helps, I've just discovered that warnings are shown, only errors aren't.

example showing a warning
nikku commented 6 months ago

Thanks for opening this bug. I can reproduce it with your setup and transferred this issue to bpmn-io/bpmn-js-bpmnlint.

barmac commented 6 months ago

Notice however that if you run npm start in this repo, both error and warning tooltips display correctly. So it might be something about the user's setup.

nikku commented 6 months ago

@barmac I was about to comment exactly that. We'd still need to investigate what is up, as this affects a simple modification of the existing modeler example.

Tupiet commented 6 months ago

Firstly, thank you for taking the time to review this. Strangely enough, in my case, doing npm start gives me the same result as npm run dev: error tooltips don't display correctly, while warnings do.

barmac commented 6 months ago

What browser do you use?

Tupiet commented 6 months ago

Tried both Safari and Chrome, same result.