Coder Social home page Coder Social logo

Comments (6)

knightss27 avatar knightss27 commented on May 28, 2024

That's odd. Are you able to confirm that they are actually receiving the right data? You should be able to see the data by clicking on the Panel Title > Inspect > Data. So you can compare between your test / real panels.
image

Otherwise it is possible that the formatting of the data differs from what the weathermap is expecting. Are you able to do what I mentioned above, but after clicking Data choose JSON and then change the dropdown to "DataFrame structure" and then send the JSON in your response? This would be really helpful!

image

Also this is actually a different issue from the one listed on the FAQ page, so I'm not surprised that reloading didn't help.

from grafana-network-weathermap.

andorwestphal avatar andorwestphal commented on May 28, 2024

Hello,

the data looks ok for me.
i compared it with the test enviorment and the structur looks the same.
Also the values are formatted equally
i attached the output here. So maybe you can see somthing odd. What i had overseen.

weathermap.txt

from grafana-network-weathermap.

knightss27 avatar knightss27 commented on May 28, 2024

I think I found it, just for my own reference:

toReturn.sides[side].currentValue = values[0] ? values[0].value : 0;

I think I'm accessing values properly just above in this file (using .get(0)) and here I've assumed that there are objects with each value, which is at least true for Prometheus but clearly is not with your data source. This should be fixable, so I'll get on it.

from grafana-network-weathermap.

knightss27 avatar knightss27 commented on May 28, 2024

Nevermind actually, I just noticed something with your data. On further comparison everything looks fine structure-wise, i.e. I am actually accessing things correctly. However, your data seems to have a null value as the last entry? It seems that my code should show a null value as undefined once formatted as a link label, so this is likely the origin of your issue. To add, the weathermap always takes the most recent available value, which is the last value in the data array (here it's null of course).

There's no way the weathermap could be causing this, so it's either an issue with your datasource plugin or your current data. Maybe you can manipulate your query somehow to always return a second-to-last value? That could be an last minute workaround if nothing else works.

"data": {
    "values": [
        [
          1662600900000,
          ...,
          1662621900000,
          1662622200000
        ],
        [
          3591.4479616499443,
          ...,
          3648.0865911843466,
          null
        ]
      ]
    }

from grafana-network-weathermap.

andorwestphal avatar andorwestphal commented on May 28, 2024

Hey
i see the null statement also in a time series panel.
so i wonder if it is possilble to manipulate the Weathermap in a way to make a 0 out of a null.

Best.

from grafana-network-weathermap.

knightss27 avatar knightss27 commented on May 28, 2024

I could do that but I don't exactly want to as it's misleading considering a null and an actual 0 would be an important distinction for most people. This doesn't make sense for your data either, since it shouldn't be returning a null unless there actually isn't any data for that value. I will make it just show null for null values, but converting to a 0 would be up to you to do with your queries.

from grafana-network-weathermap.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.