wlourf's avatar

Graph Widget for Conky 1.1

10 17 6K (1 Today)
By wlourf   |   
Published:
© 2010 - 2020 wlourf
A little widget to draw some graphs with some options.

Update 07.01.11 for bug fix on memory leaks
Comments17
anonymous's avatar
Join the community to add your comment. Already a deviant? Log In
flooo68's avatar
Hi ! Very nice work !
sasha1594's avatar
sasha1594Hobbyist Traditional Artist
Dear Sir,

I am astounded by your conky scripts and various lua scripts and thank you for sharing with us,

I downloaded this graph widget and just simply ran it without any modification.
but I get a error
" Conky: llua_do_call: function conky_main_graph execution failed:graph.lua:424: bad argument #2 to 'max' (number expected, got nil)"

but still the graph is displayed, is it serious.
Please help.

Thankyou
N00by4Ever's avatar
Just want to say that you've done an amazing job, this is a very nice extension of conky.

Thank you!
JeSuisNerd's avatar
JeSuisNerdHobbyist Digital Artist
This is exactly what I needed! Thanks for the great widget.
wlourf's avatar
you're welcome, and thanks for the multiple favs ;-)
JeSuisNerd's avatar
JeSuisNerdHobbyist Digital Artist
My pleasure! Your conky work is great, and it wasn't very difficult to get it into londonali's script to work with multiple widgets.
RiPrope's avatar
Hi, great script, thank you.

When using diskio, diskio_write or diskio_read variables, it trows error:
Conky: llua_do_call: function conky_main_graph execution failed: /d/lpapps/scripts/graph.lua:292: bad argument #2 to 'max' (number expected, got nil)

This is probably because diskio variables have B,KiB,MiB,or GiB letters at the end, so it is not a number for script.
Is there a way to overcome this, and use script to graph disk usage also.

Thanks in advance !
Denis
wlourf's avatar
You're right about letters at the end ! The workaround is to replace theses lines :
---
value=tonumber(conky_parse('${' ..
graph_settings[i].name .. " " ..
graph_settings[i].arg ..'}'))
---
by this :
---
value=conky_parse('${' ..
graph_settings[i].name .. " " ..
graph_settings[i].arg ..'}')
value=string.gsub(value,"%a","")
value=tonumber(value)
---
and use, in the table settings :
---
name="diskio",
arg="sdc",
max=100,
autoscale=true,
---
it should be better with autoscale, HTH
RiPrope's avatar
it show graph now (without autoscale is inaccurate and have a glitches :( ).

Thank you.

Best regards
iacoporosso's avatar
firstly... a really good job!!!!

but I have a problem when loading your lua widgets , it give me back this error:


Conky: llua_do_call: function conky_main_graph execution failed: /home/XXX/graph.lua:211: attempt to compare number with nil

(the XXX it is only ma path to file )

do you know how to fix this error??
wlourf's avatar
Hi and thanks, it's just an error when the script is loading the first time.
On line 371, you can change :
if updates ==1 then
with
if updates<=1 then

Hth
iacoporosso's avatar
thx man!!! i'll try!! :bounce:
iacoporosso's avatar
thx man!!!!!! i have tried and.... i have correct whit:

if updates>=1 then

and now it works!!!
iacoporosso's avatar
edit... whit this value the scripts draw me only the background without the graph.. =(
Ubuntico's avatar
UbunticoProfessional Artisan Crafter
Excellent :)
arpinux's avatar
very nice .. :)
did you plain to post it in PitStop Conky website ?
wlourf's avatar
Tks arp!
Well, I have to ask the Chief ! I have to post a screen in real use before to ask ;-)
anonymous's avatar
Join the community to add your comment. Already a deviant? Log In