Open decryptedchaos opened 10 months ago
@decryptedchaos Sorry to hear you've had issues, both issues listed were different causes, but yeah, a blank graph is frustrating.
This is definitely overdue a dependencies update, which may fix your library issues. What libraries were causing problems?
Could you post your config and any error messages you got?
Thanks!
Just did an initial pass on updates with #174
Actually, it's looking like it might a js issue, could you check and see if you're getting a javascript error on the vaping page?
Sorry for the late response, GitHub isn't doing a good job of notifying me of responses, I will look into the pr tomorrow and get back to you it's late here
I believe I have the same issue:
I get the following error in the JS console:
Uncaught TypeError: this.d3.data.selectAll(...).data(...).enter is not a function
render_data http://localhost:7021/static/graphsrv/js/graphsrv.js:1465
render_dynamic http://localhost:7021/static/graphsrv/js/graphsrv.js:1356
Base http://localhost:7021/static/graphsrv/js/graphsrv.js:869
jQuery 2
dispatch
handle
[graphsrv.js:1465:10](http://localhost:7021/static/graphsrv/js/graphsrv.js)
Same issue on Firefox and Chrome.
Yea there were definitely JS errors like that, I just haven't had time to test it anymore I kinda got mad at it and removed it and I've been distro hopping lately so might test on this one soon
I also get blank pages, in the console all I get are warnings like:
The script from “http://yourdomain.coml:7121/graph/?targets=all&id=auto-2&fit=yes&type=multitarget&config=multitarget&source=latency.distant” was loaded even though its MIME type (“text/html”) is not a valid JavaScript MIME type.
These don't seem to be fatal though. This is in a virtualenv on debian 12 (python 3.11).
When blank, I got this response from api:
{"meta": {"error": "module 'inspect' has no attribute 'getargspec'"}, "data": []}
After search, I think that it comes from the 42 line of vodka/data/renderers.py
:
class RPC(DataRenderer):
"""
RPC renderer, renders an rpc response containing meta and data objects
Should be used as a decorator. The decorated function will be called
with the data container as first argument and the meta container referenced
in the "meta" keyword argument.
"""
def __init__(self, type="json", data_type=list, errors=False):
super().__init__(type=type)
self.errors = errors
self.data_type = data_type
def __call__(self, fn):
def wrapped(*args, **kwargs):
resp = {"meta": {}, "data": self.data_type()}
try:
i_args = inspect.getargspec(fn)
if i_args.args and i_args.args[0] == "self":
fn(args[0], resp["data"], meta=resp["meta"], *args, **kwargs)
else:
fn(resp["data"], meta=resp["meta"], *args, **kwargs)
except Exception as inst:
if self.errors:
resp["meta"]["error"] = str(inst)
else:
raise
return self.render(resp)
wrapped.__name__ = fn.__name__
return wrapped
I sent a PR to fix this: https://github.com/20c/vodka/pull/23
This has already been brought up back in 2022 here #164 and #136
I found none of the discussed workarounds viaable.. I really wanted vaping to work as a simpler alternative to smokeping (rrdtool alignment sucks)
But after a day of messing with it and trying to pin library versions which debian gets mad at you for doing anyway.. i just could not get it to work with a resonable amount of effort.. i'd have to completely change all my python librarys to older/newer versions to work and thats just not resonable to me..
I would have hoped this would have been solved since 2022, but with that said this does seam to be a small team project so thats understandable..
Well there you go, i suggest this remain open or something opened in its place because this is still very much a big issue.