Grafana-zabbix: Problems panel query editor issues

Created on 12 Jun 2020  路  7Comments  路  Source: alexanderzobnin/grafana-zabbix

Bug description
When I open the query editor of a Problems panel and try to scroll down to see all details of the query, the query window disappears. This issue is being reproduced constantly in our DEV environment where we installed Grafana 7.0.3 and the latest version 3.12.2 of your plugin. In another environment with Grafana 6.7.4 and the same version of the plugin, the query editor works fine.

How to reproduce

  1. Open the query editor of the Problems panel. The query window and the query details are in place.
    The query in place
  2. Try to scroll down to the bottom of the screen. The query disappears.
    The query disappeared

| Grafana | Zabbix | Grafana-Zabbix Plugin |
| ------- | ------ | --------------------- |
| 7.0.3 | 4.4.2 | 3.12.2 |

Problems panel bug

All 7 comments

We have same issue with Grafana - 6.7.4 , Zabbix - 4.4.5 , Plugin - 3.12.2

Hi! Could you provide some error details from the JS console?

It's also reproduced in 4.0.0
image

This is happening for me as well, except I don't have to scroll and nothing is output into the console. Just open the panel editor and after a few seconds the queries are deleted. If you close the editor and reopen it, the queries will come back after a few seconds (like the reverse of the initial problem).

This also affects the acknowledgement window - if you try to type in a message it will be deleted on the exact same interval. I don't know if it's tied to the refresh rate of the dashboard (ours is 10s). This is annoying - the only workaround is to write your message in another window and quickly copy-paste it in before it is automatically deleted from the text box.

The only error I can get is if I open the editor and refresh the page, I get this screen:
image

Could someone confirm the problem still exists in the latest plugin version (4.0.1)?

Yes, I can confirm it.

Scenario 1:

  1. Add new panel. (Default data source: "Zabbix".)
  2. Change "Visualization" from the default "Graph" to "Zabbix Problems".
  3. Scroll down in the Query Editor.
    Result: Query 'A' disappears.
  4. Bonus step _in case if you feel completely lost and do not know what to do_:
    Change back to something else e.g. "Graph", then "Zabbix Problems", then something else e.g. "Graph" again.
    Result: An unexpected error happened: TypeError: Cannot read property 'length' of undefined.

Scenario 2 (I know it is not a normal use case, but maybe related to the base problem.):

  1. Add new panel.
  2. Change "Visualization" from the default "Graph" to "Zabbix Problems".
  3. Change to "Graph".
  4. Change to "Zabbix Problems".
  5. Scroll down in the Query Editor.
    Result: NOT OK: An unexpected error happened: TypeError: Cannot read property 'map' of undefined.

Software versions
Grafana | Zabbix | Grafana-Zabbix Plugin
-- | -- | --
7.0.6 | 4.0.26 | 4.0.1
7.1.5 | 4.0.26 | 4.0.1
7.2.2 | 4.0.26 | 4.0.1
7.3.1 | 4.0.26 | 4.0.1

Found a root cause - the panel migrations. Since grafana allows to switch between visualizations, I should change logic a bit to adjust to the new state of things.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

dataniard picture dataniard  路  6Comments

maxlehot1234 picture maxlehot1234  路  5Comments

KevinInphos picture KevinInphos  路  4Comments

alexanderzobnin picture alexanderzobnin  路  4Comments

samyscoub picture samyscoub  路  6Comments