brndnmtthws / conky

Light-weight system monitor for X, Wayland (sort of), and other things, too
https://conky.cc
GNU General Public License v3.0
7.31k stars 620 forks source link

[Enhancement]: Make update frequency more consistent #2060

Open BayouGuru67 opened 1 month ago

BayouGuru67 commented 1 month ago

What happened?

I have 4 conkys in total. A "clock" conky, a "system info" conky, a "cpu utilization" conky and a "network monitoring" conky.

The one conky currently affected by this issue is my network monitoring conky. When I run a Gnome app, specifically Shortwave internet radio tuner, the update frequency of my network conky goes from smoothly updating once per second to updating erratically, updating once up to every 4 seconds or so. Running the conky from the terminal does not report any errors and there are no errors reported in the logs that I can find. The other conkys are not affected.

Some historical perspective: In previous versions of conky, it would have exhibited the same or similar "stuttering" effect in both the conky ("the conky" being any one of or all of the CPU, system info and/or network monitoring conkys) and on any video playback that was going on, such as YouTube in Brave or FireFox, until the conky was killed. In previous conky versions, my CPU Utilization conky, which is just 7 lua meters with the text showing the % usage and current frequency of each core and the averages at the bottom would be the first and most-often-affected, but it is actually behaving well so far with the current version of conky. Same is true for the System info conky, which shows a LOT of system info such as free/used RAM, drive space, temps, etc. It used to get affected in the same way and cause stuttering video playback issues, but now is behaving well.

In version 1.21.7, the conky going wonky does not seem to affect video playback smoothness any more, (or any other system/software smoothness/operation) which is wonderful, but the conky itself is even more unresponsive when this bug/event/issue occurs. It should be stated that my clock conky has been a good little conky this whole time, smoothly updating every second like, well, clockwork. It only shows the time, date and uptime and I have declared it as the system conky config in the cmake config options. The correct network adapter was also defined in the cmake config, FYI. The only other items modified from default cmake config are the checking of the ~4 lua bindings. I'm running an all-AMD system with an ASUS AMD 970 chipset and an AMD RX580 GPU.

I had quit running all but my clock conky for some time now because of the video playback stuttering issue where video playback would annoyingly stutter in time with the conky update frequency. I had switched to using Plasma monitor widgets, which is so clunky and limited as to just barely be annoyingly functional, sort of. But now there is hope for me that it is no longer an issue with this latest version of conky, and I have progressed from having 3 conkys that are acting up and therefore unusable, to only one! I am calling that positive progress, and I am very grateful to the humble programmer(s) for that! I am so very happy to have my system info and CPU conkys back in operation! Thank you! I wish us all luck in solving the riddle of my network conky with a case of the pregnant-pauses/stutters/hitches! I've done so many web searches for permutations of this issue description in the last few months I'm now just at a loss for ideas on how to proceed. In the code box below, I am posting the current problem config first, with the others following it. I put 3 blank lines in between each of them and each config starts with a comment section at the top. I look forward to your feedback!

Version

1.21.7

Which OS/distro are you seeing the problem on?

Ubuntu

Conky config

```Lua -- -- BayouGuru's Right Conky! -- version: 2024-08-17.0723 -- conky.config = { display = ":0.0", update_interval = 1, net_avg_samples = 1, total_run_times = 0, alignment = "top_right", gap_x = 2, gap_y = 2, minimum_width = 300, maximum_width = 300, minimum_height = 1064, own_window = true, own_window_title = "conky-rightconky", own_window_type = "normal", own_window_transparent = false, own_window_argb_visual = true, own_window_argb_value = 180, double_buffer = true, own_window_hints = "undecorated,below,sticky,skip_taskbar", show_graph_scale = false, no_buffers = false, pad_percents = 1, use_xft = true, xftalpha = 0.8, font = "Larabiefont-Regular:bold:size=11", text_buffer_size = 256, short_units = true, temperature_unit = "fahrenheit", forced_redraw = false, draw_graph_borders = false, draw_outline = true, draw_shades = true, draw_borders = true, border_inner_margin = 1, border_outer_margin = 0, border_width = 3, own_window_colour = "080721", default_outline_color = "000000", default_color = "000415", default_shade_color = "080721", color0 = '080721', -- Dark Blue - Background color1 = 'lightblue', -- Light Blue - Labels color2 = 'orange', -- Orange - Monitored Item (Frequently Updates) color3 = 'goldenrod1', -- GoldenRod - Monitored Item 2 color4 = 'white', -- White - Headers color5 = '008989', -- Blue - ANSI Header Art color6 = '2723a6', -- Another Blue - Bar Fill color7 = 'white', -- White - Drive Labels color8 = 'SteelBlue', -- SteelBlue - ANSI Forks -- color9 = 'unused', -- Available template0 = '${goto 2}${font Larabiefont-Regular:bold:size=12}', -- Header Text template1 = '${color1}${font Larabiefont-Regular:bold:size=11}', -- Label Text template2 = '${font Larabiefont-Regular:bold:size=11}', -- Data Text -- template3 = 'unused', -- Available -- template4 = 'unused', -- Available template5 = '${voffset -3}${font UbuntuCondensed:size=10}', -- Connection Hostnames template6 = '${color8}${font Arial:bold:size=11}', -- ANSI template7 = '${color8}${font Arial:bold:size=11}', -- ANSI forks template8 = '${font Larabiefont-Regular:bold:size=10}', -- WAN Hostname lua_load = '/home/bayouguru/.conky/updownbars.lua', lua_draw_hook_post = 'conky_widgets' } conky.text = [[${image ~/.conky/images/network.png -p 3,266 -s 38x38}\ ${if_existing /sys/class/net/enp4s0/operstate down}${image ~/.conky/images/red.png -p 1,285 -s 36x10}${voffset 450}${alignc}${color red}${blink NO CONNECTION!}${else}${image ~/.conky/images/green.png -p 3,285 -s 36x10}\ ${color4}${template0}Processes ${color8}${voffset -2}${hr 1} ${template7}└${color4}${template2}Top 5 - RAM Usage ${color8}${voffset -2}${hr 1} ${voffset -2}${color1}${template8} Name${goto 158}PID${goto 200}RAM-%${goto 252}RAM-Mb ${voffset -2}${color2}${template8} ${top_mem name 1}${offset -12}${top_mem pid 1}${goto 184}${top_mem mem 1}${color1}%${color2}${alignr 4}${top_mem mem_res 1}b ${voffset -2}${color2} ${top_mem name 2}${offset -12}${top_mem pid 2}${goto 184}${top_mem mem 2}${color1}%${color2}${alignr 4}${top_mem mem_res 2}b ${voffset -2}${color2} ${top_mem name 3}${offset -12}${top_mem pid 3}${goto 184}${top_mem mem 3}${color1}%${color2}${alignr 4}${top_mem mem_res 3}b ${voffset -2}${color2} ${top_mem name 4}${offset -12}${top_mem pid 4}${goto 184}${top_mem mem 4}${color1}%${color2}${alignr 4}${top_mem mem_res 4}b ${voffset -2}${color2} ${top_mem name 5}${offset -12}${top_mem pid 5}${goto 184}${top_mem mem 5}${color1}%${color2}${alignr 4}${top_mem mem_res 5}b ${template7}└${color4}${template2}Top 5 - CPU Usage ${color8}${voffset -2}${hr 1} ${voffset -2}${color1}${template8} Name${goto 158}PID${goto 208}CPU${goto 270}RAM ${voffset -2}${color2}${template8} ${top name 1}${offset -12}${top pid 1}${goto 184}${top cpu 1}${color1}%${color2}${alignr 4}${top mem 1}${color1}% ${voffset -2}${color2} ${top name 2}${offset -12}${top pid 2}${goto 184}${top cpu 2}${color1}%${color2}${alignr 4}${top mem 2}${color1}% ${voffset -2}${color2} ${top name 3}${offset -12}${top pid 3}${goto 184}${top cpu 3}${color1}%${color2}${alignr 4}${top mem 3}${color1}% ${voffset -2}${color2} ${top name 4}${offset -12}${top pid 4}${goto 184}${top cpu 4}${color1}%${color2}${alignr 4}${top mem 4}${color1}% ${voffset -2}${color2} ${top name 5}${offset -12}${top pid 5}${goto 184}${top cpu 5}${color1}%${color2}${alignr 4}${top mem 5}${color1}% ${color4}${template0}Network ${color8}${voffset -2}${hr 1} ${voffset -3}${goto 44}${template7}├${template1} LAN v4 IP${color3}${alignr 4}${template2}${addr enp4s0} ${voffset -3}${goto 44}${template7}├${template1} WAN v4 IP${color3}${alignr 4}${template2}${execi 180 curl ifconfig.me} ${voffset -3}${goto 44}${template7}├${template1} MAC${color3}${alignr 3}${template2}${execi 360 ip link show enp4s0 | awk '/ether/ {print $2}'} ${voffset -2}${goto 4}${template7}┌───${goto 44}┴${voffset -2}${template1} Hostname${template2}${color3}${alignr 4}${nodename_short} ${voffset -2}${template7}├${color1}▲${color2}${template2}${upspeed enp4s0} ${voffset -3}${template7}├${color1}▼${color2}${template2}${downspeed enp4s0} ${voffset -2}${color8}${template7}├ ${color4}${template2}Connections${color8}${goto 164}${color yellow}${template2}In ${template2}${color2}${tcp_portmon 1 32767 count}${color5}${alignr 4}${voffset -1}Out ${template2}${color2}${tcp_portmon 32768 61000 count} ${if_match ${tcp_portmon 1 32767 count}>=1}${goto 4}${color8}${voffset -2}${template7}├${color yellow}${template2}In${template7} ◄${color2} ${template2}${tcp_portmon 1 32768 rip 0}${alignr 4}${tcp_portmon 1 32768 rservice 0} ${else}${endif}\ ${if_match ${tcp_portmon 1 32767 count}>=1}${voffset -3}${goto 4}${template7}└ ${color3}${template5}${tcp_portmon 1 32768 rhost 0} ${else}${endif}\ ${if_match ${tcp_portmon 1 32767 count}>=2}${goto 4}${color8}${voffset -2}${template7}├${color yellow}${template2}In${template7} ◄${color2} ${template2}${tcp_portmon 1 32768 rip 1}${alignr 4}${tcp_portmon 1 32768 rservice 1} ${else}${endif}\ ${if_match ${tcp_portmon 1 32767 count}>=2}${voffset -3}${goto 4}${template7}└ ${color3}${template5}${tcp_portmon 1 32768 rhost 1} ${else}${endif}\ ${if_match ${tcp_portmon 1 32767 count}>=3}${goto 4}${color8}${voffset -2}${template7}├${color yellow}${template2}In${template7} ◄${color2} ${template2}${tcp_portmon 1 32768 rip 2}${alignr 4}${tcp_portmon 1 32768 rservice 2} ${else}${endif}\ ${if_match ${tcp_portmon 1 32767 count}>=3}${voffset -3}${goto 4}${template7}└ ${color3}${template5}${tcp_portmon 1 32768 rhost 2} ${else}${endif}\ ${if_match ${tcp_portmon 1 32767 count}>=4}${goto 4}${color8}${voffset -2}${template7}├${color yellow}${template2}In${template7} ◄${color2} ${template2}${tcp_portmon 1 32768 rip 3}${alignr 4}${tcp_portmon 1 32768 rservice 3} ${else}${endif}\ ${if_match ${tcp_portmon 1 32767 count}>=4}${voffset -3}${goto 4}${template7}└ ${color3}${template5}${tcp_portmon 1 32768 rhost 3} ${else}${endif}\ ${if_match ${tcp_portmon 1 32767 count}>=5}${goto 4}${color8}${voffset -2}${template7}├${color yellow}${template2}In${template7} ◄${color2} ${template2}${tcp_portmon 1 32768 rip 4}${alignr 4}${tcp_portmon 1 32768 rservice 4} ${else}${endif}\ ${if_match ${tcp_portmon 1 32767 count}>=5}${voffset -3}${goto 4}${template7}└ ${color3}${template5}${tcp_portmon 1 32768 rhost 4} ${else}${endif}\ ${if_match ${tcp_portmon 1 32767 count}>=6}${goto 4}${color8}${voffset -2}${template7}├${color yellow}${template2}In${template7} ◄${color2} ${template2}${tcp_portmon 1 32768 rip 5}${alignr 4}${tcp_portmon 1 32768 rservice 5} ${else}${endif}\ ${if_match ${tcp_portmon 1 32767 count}>=6}${voffset -3}${goto 4}${template7}└ ${color3}${template5}${tcp_portmon 1 32768 rhost 5} ${else}${endif}\ ${if_match ${tcp_portmon 32768 61000 count}>=1}${goto 4}${color8}${voffset -2}${template7}├${color5}${template2}Out${template7} ►${color2} ${template2}${tcp_portmon 32768 61000 rip 0}${alignr 4}${tcp_portmon 32768 61000 rservice 0} ${else}${endif}\ ${if_match ${tcp_portmon 32768 61000 count}>=1}${voffset -3}${goto 4}${template7}└ ${color3}${template5}${tcp_portmon 32768 61000 rhost 0} ${else}${endif}\ ${if_match ${tcp_portmon 32768 61000 count}>=2}${goto 4}${color8}${voffset -2}${template7}├${color5}${template2}Out${template7} ►${color2} ${template2}${tcp_portmon 32768 61000 rip 1}${alignr 4}${tcp_portmon 32768 61000 rservice 1} ${else}${endif}\ ${if_match ${tcp_portmon 32768 61000 count}>=2}${voffset -3}${goto 4}${template7}└ ${color3}${template5}${tcp_portmon 32768 61000 rhost 1} ${else}${endif}\ ${if_match ${tcp_portmon 32768 61000 count}>=3}${goto 4}${color8}${voffset -2}${template7}├${color5}${template2}Out${template7} ►${color2} ${template2}${tcp_portmon 32768 61000 rip 2}${alignr 4}${tcp_portmon 32768 61000 rservice 2} ${else}${endif}\ ${if_match ${tcp_portmon 32768 61000 count}>=3}${voffset -3}${goto 4}${template7}└ ${color3}${template5}${tcp_portmon 32768 61000 rhost 2} ${else}${endif}\ ${if_match ${tcp_portmon 32768 61000 count}>=4}${goto 4}${color8}${voffset -2}${template7}├${color5}${template2}Out${template7} ►${color2} ${template2}${tcp_portmon 32768 61000 rip 3}${alignr 4}${tcp_portmon 32768 61000 rservice 3} ${else}${endif}\ ${if_match ${tcp_portmon 32768 61000 count}>=4}${voffset -3}${goto 4}${template7}└ ${color3}${template5}${tcp_portmon 32768 61000 rhost 3} ${else}${endif}\ ${if_match ${tcp_portmon 32768 61000 count}>=5}${goto 4}${color8}${voffset -2}${template7}├${color5}${template2}Out${template7} ►${color2} ${template2}${tcp_portmon 32768 61000 rip 4}${alignr 4}${tcp_portmon 32768 61000 rservice 4} ${else}${endif}\ ${if_match ${tcp_portmon 32768 61000 count}>=5}${voffset -3}${goto 4}${template7}└ ${color3}${template5}${tcp_portmon 32768 61000 rhost 4} ${else}${endif}\ ${if_match ${tcp_portmon 32768 61000 count}>=6}${goto 4}${color8}${voffset -2}${template7}├${color5}${template2}Out${template7} ►${color2} ${template2}${tcp_portmon 32768 61000 rip 5}${alignr 4}${tcp_portmon 32768 61000 rservice 5} ${else}${endif}\ ${if_match ${tcp_portmon 32768 61000 count}>=6}${voffset -3}${goto 4}${template7}└ ${color3}${template5}${tcp_portmon 32768 61000 rhost 5} ${else}${endif}\ ${if_match ${tcp_portmon 32768 61000 count}>=7}${goto 4}${color8}${voffset -2}${template7}├${color5}${template2}Out${template7} ►${color2} ${template2}${tcp_portmon 32768 61000 rip 6}${alignr 4}${tcp_portmon 32768 61000 rservice 6} ${else}${endif}\ ${if_match ${tcp_portmon 32768 61000 count}>=7}${voffset -3}${goto 4}${template7}└ ${color3}${template5}${tcp_portmon 32768 61000 rhost 6} ${else}${endif}\ ${if_match ${tcp_portmon 32768 61000 count}>=8}${goto 4}${color8}${voffset -2}${template7}├${color5}${template2}Out${template7} ►${color2} ${template2}${tcp_portmon 32768 61000 rip 7}${alignr 4}${tcp_portmon 32768 61000 rservice 7} ${else}${endif}\ ${if_match ${tcp_portmon 32768 61000 count}>=8}${voffset -3}${goto 4}${template7}└ ${color3}${template5}${tcp_portmon 32768 61000 rhost 7} ${else}${endif}\ ${if_match ${tcp_portmon 32768 61000 count}>=9}${goto 4}${color8}${voffset -2}${template7}├${color5}${template2}Out${template7} ►${color2} ${template2}${tcp_portmon 32768 61000 rip 8}${alignr 4}${tcp_portmon 32768 61000 rservice 8} ${else}${endif}\ ${if_match ${tcp_portmon 32768 61000 count}>=9}${voffset -3}${goto 4}${template7}└ ${color3}${template5}${tcp_portmon 32768 61000 rhost 8} ${else}${endif}\ ${if_match ${tcp_portmon 32768 61000 count}>=10}${goto 4}${color8}${voffset -2}${template7}├${color5}${template2}Out${template7} ►${color2} ${template2}${tcp_portmon 32768 61000 rip 9}${alignr 4}${tcp_portmon 32768 61000 rservice 9} ${else}${endif}\ ${if_match ${tcp_portmon 32768 61000 count}>=10}${voffset -3}${goto 4}${template7}└ ${color3}${template5}${tcp_portmon 32768 61000 rhost 9} ${else}${endif}\ ${if_match ${tcp_portmon 32768 61000 count}>=11}${goto 4}${color8}${voffset -2}${template7}├${color5}${template2}Out${template7} ►${color2} ${template2}${tcp_portmon 32768 61000 rip 10}${alignr 4}${tcp_portmon 32768 61000 rservice 10} ${else}${endif}\ ${if_match ${tcp_portmon 32768 61000 count}>=11}${voffset -3}${goto 4}${template7}└ ${color3}${template5}${tcp_portmon 32768 61000 rhost 10} ${else}${endif}\ ${if_match ${tcp_portmon 32768 61000 count}>=12}${goto 4}${color8}${voffset -2}${template7}├${color5}${template2}Out${template7} ►${color2} ${template2}${tcp_portmon 32768 61000 rip 11}${alignr 4}${tcp_portmon 32768 61000 rservice 11} ${else}${endif}\ ${if_match ${tcp_portmon 32768 61000 count}>=12}${voffset -3}${goto 4}${template7}└ ${color3}${template5}${tcp_portmon 32768 61000 rhost 11} ${else}${endif}\ ${if_match ${tcp_portmon 1 32767 count}<=5}${if_match ${tcp_portmon 32768 61000 count}>=13}${goto 4}${color8}${voffset -2}${template7}├${color5}${template2}Out${template7} ►${color2} ${template2}${tcp_portmon 32768 61000 rip 12}${alignr 4}${tcp_portmon 32768 61000 rservice 12} ${else}${endif}${else}${endif}\ ${if_match ${tcp_portmon 1 32767 count}<=5}${if_match ${tcp_portmon 32768 61000 count}>=13}${voffset -3}${goto 4}${template7}└ ${color3}${template5}${tcp_portmon 32768 61000 rhost 12} ${else}${endif}${else}${endif}\ ${if_match ${tcp_portmon 1 32767 count}<=4}${if_match ${tcp_portmon 32768 61000 count}>=14}${goto 4}${color8}${voffset -2}${template7}├${color5}${template2}Out${template7} ►${color2} ${template2}${tcp_portmon 32768 61000 rip 13}${alignr 4}${tcp_portmon 32768 61000 rservice 13} ${else}${endif}${else}${endif}\ ${if_match ${tcp_portmon 1 32767 count}<=4}${if_match ${tcp_portmon 32768 61000 count}>=14}${voffset -3}${goto 4}${template7}└ ${color3}${template5}${tcp_portmon 32768 61000 rhost 13} ${else}${endif}${else}${endif}\ ${if_match ${tcp_portmon 1 32767 count}<=3}${if_match ${tcp_portmon 32768 61000 count}>=15}${goto 4}${color8}${voffset -2}${template7}├${color5}${template2}Out${template7} ►${color2} ${template2}${tcp_portmon 32768 61000 rip 14}${alignr 4}${tcp_portmon 32768 61000 rservice 14} ${else}${endif}${else}${endif}\ ${if_match ${tcp_portmon 1 32767 count}<=3}${if_match ${tcp_portmon 32768 61000 count}>=15}${voffset -3}${goto 4}${template7}└ ${color3}${template5}${tcp_portmon 32768 61000 rhost 14} ${else}${endif}${else}${endif}\ ${if_match ${tcp_portmon 1 32767 count}<=2}${if_match ${tcp_portmon 32768 61000 count}>=16}${goto 4}${color8}${voffset -2}${template7}├${color5}${template2}Out${template7} ►${color2} ${template2}${tcp_portmon 32768 61000 rip 15}${alignr 4}${tcp_portmon 32768 61000 rservice 15} ${else}${endif}${else}${endif}\ ${if_match ${tcp_portmon 1 32767 count}<=2}${if_match ${tcp_portmon 32768 61000 count}>=16}${voffset -3}${goto 4}${template7}└ ${color3}${template5}${tcp_portmon 32768 61000 rhost 15} ${else}${endif}${else}${endif}\ ${if_match ${tcp_portmon 1 32767 count}<=1}${if_match ${tcp_portmon 32768 61000 count}>=17}${goto 4}${color8}${voffset -2}${template7}├${color5}${template2}Out${template7} ►${color2} ${template2}${tcp_portmon 32768 61000 rip 16}${alignr 4}${tcp_portmon 32768 61000 rservice 16} ${else}${endif}${else}${endif}\ ${if_match ${tcp_portmon 1 32767 count}<=1}${if_match ${tcp_portmon 32768 61000 count}>=17}${voffset -3}${goto 4}${template7}└ ${color3}${template5}${tcp_portmon 32768 61000 rhost 16} ${else}${endif}${else}${endif}\ ${if_match ${tcp_portmon 1 32767 count}==0}${if_match ${tcp_portmon 32768 61000 count}>=18}${goto 4}${color8}${voffset -2}${template7}├${color5}${template2}Out${template7} ►${color2} ${template2}${tcp_portmon 32768 61000 rip 17}${alignr 4}${tcp_portmon 32768 61000 rservice 17} ${else}${endif}${else}${endif}\ ${if_match ${tcp_portmon 1 32767 count}==0}${if_match ${tcp_portmon 32768 61000 count}>=18}${voffset -3}${goto 4}${template7}└ ${color3}${template5}${tcp_portmon 32768 61000 rhost 17} ${else}${endif}${else}${endif}${endif}${font}\ ]] -- -- BayouGuru's New Modular System Conky Config - Clock Section - Top! -- version: 2024-07-20.0346 -- conky.config = { -- display = ":0.0", update_interval = 1, net_avg_samples = 1, cpu_avg_samples = 1, total_run_times = 0, alignment = "top_left", gap_x = 1, gap_y = 0, minimum_width = 260, maximum_width = 260, own_window = true, own_window_type = "normal", own_window_hints = "undecorated,below,sticky,skip_taskbar,skip_pager", own_window_transparent = false, own_window_argb_visual = true, own_window_argb_value = 180, show_graph_scale = false, double_buffer = true, text_buffer_size = 256, no_buffers = false, use_xft = true, font = "Larabiefont-Regular:bold:size=11", short_units = true, temperature_unit = "fahrenheit", forced_redraw = false, draw_graph_borders = false, draw_outline = true, draw_shades = true, draw_borders = true, border_inner_margin = 2, border_outer_margin = 1, border_width = 3, own_window_colour = "080721", default_outline_color = "000000", default_color = "000415", default_shade_color = "080721", color0 = '080721', -- Dark Blue - Background color1 = 'orange', -- Orange - Monitored Item (Frequently Updates) color2 = 'goldenrod', -- GoldenRod - Monitored Item (Infrequent/Versions) template0 = '${color2}${font Larabiefont-Regular:bold:size=11}${alignc}', -- Date template1 = '${color1}${font Larabiefont-Regular:bold:size=34}${alignc}', -- Clock } conky.text = [[${template1}${time %I:%M:%S}${font} ${template0}${time %A %B %e} ${alignc}Uptime: ${color1}${uptime}${font}${voffset -4}]] -- -- BayouGuru's New Modular System Conky Config - CPU Section! -- version: 2024-07-20.0346 -- conky.config = { -- display = ":0.0", update_interval = 1, net_avg_samples = 1, cpu_avg_samples = 1, total_run_times = 0, alignment = "top_left", gap_x = 3, gap_y = 103, minimum_width = 260, maximum_width = 260, own_window = true, own_window_type = "normal", own_window_hints = "undecorated,below,sticky,skip_taskbar,skip_pager", own_window_transparent = false, own_window_argb_visual = true, own_window_argb_value = 180, show_graph_scale = false, double_buffer = true, text_buffer_size = 256, no_buffers = false, use_xft = true, font = "Larabiefont-Regular:bold:size=11", short_units = true, temperature_unit = "fahrenheit", forced_redraw = false, draw_graph_borders = false, draw_outline = false, draw_shades = true, draw_borders = true, border_inner_margin = 2, border_outer_margin = 1, border_width = 3, own_window_colour = "080721", default_outline_color = "000000", default_color = "000415", default_shade_color = "080721", color0 = '080721', -- Dark Blue - Background color1 = 'lightblue', -- Light Blue - Labels color2 = 'orange', -- Orange - Monitored Item (Frequently Updates) color3 = 'goldenrod1', -- GoldenRod - Monitored Item (Infrequent/Versions) color4 = 'white', -- White - Headers color5 = 'SteelBlue', -- Blue - ANSI Header Art color6 = 'green3', -- ? color7 = 'white', -- White - Drive Labels color8 = 'green3', -- Light Green - Bar Green color9 = 'SteelBlue', -- Steel Blue - Bar Scales template0 = '${font Larabiefont-Regular:bold:size=11}', -- template1 = '${voffset 0}${color1}${font Larabiefont-Regular:bold:size=10}', -- lua_load = '/home/bayouguru/.conky/conkycpubars.lua', lua_draw_hook_post = 'conky_widgets' } conky.text = [[${color4}${template0}${execi 86400 cat /proc/cpuinfo | grep 'model name' | sed -e 's/model name.*: //' | sed -e 's/Processor//' | sed -e 's/(tm)/™/' | sed -e 's/(R)//' | sed -e 's/CPU//' | sed -e 's/@/:/' | sed -e 's/\ \ //' | sed -e 's/[0-9].[0-9][0-9]GHz//'|uniq}${font}${color5}${voffset -2}${hr 1} ${voffset 16}${color2}${template0}${cpu cpu1}${template1}%${goto 44}@${color2}${template0}${goto 64}${freq 1}${template1}Mhz${goto 134}${color2}${template0}${voffset -2}${cpu cpu2}${template1}%${goto 178}@${color2}${template0}${alignr}${freq 2}${template1}Mhz ${voffset 16}${color2}${template0}${cpu cpu3}${template1}%${goto 44}@${color2}${template0}${goto 64}${freq 3}${template1}Mhz${goto 134}${color2}${template0}${voffset -2}${cpu cpu4}${template1}%${goto 178}@${color2}${template0}${alignr}${freq 4}${template1}Mhz ${voffset 16}${color2}${template0}${cpu cpu5}${template1}%${goto 44}@${color2}${template0}${goto 64}${freq 5}${template1}Mhz${goto 134}${color2}${template0}${voffset -2}${cpu cpu6}${template1}%${goto 178}@${color2}${template0}${alignr}${freq 6}${template1}Mhz ${voffset 16}${template1}Average ${color2}${template0}${goto 120}${cpu cpu0}${template1}%${color2}${template0}${alignr}${freq 0}${template1}Mhz ${voffset 5}${font}]] -- -- BayouGuru's New Modular Conky Config - System Info Section! -- version: 2024-08-13.1016 -- conky.config = { -- display = ":0.0", update_interval = 1, net_avg_samples = 1, cpu_avg_samples = 1, total_run_times = 0, alignment = "top_left", gap_x = 3, gap_y = 282, minimum_width = 260, maximum_width = 260, own_window = true, own_window_type = "normal", own_window_hints = "undecorated,below,sticky,skip_taskbar,skip_pager", own_window_transparent = false, own_window_argb_visual = true, own_window_argb_value = 180, show_graph_scale = false, double_buffer = true, text_buffer_size = 256, no_buffers = false, use_xft = true, font = "Larabiefont-Regular:bold:size=10", short_units = true, temperature_unit = "fahrenheit", forced_redraw = false, draw_graph_borders = false, draw_outline = true, draw_shades = true, draw_borders = true, border_inner_margin = 2, border_outer_margin = 1, border_width = 3, own_window_colour = "080721", default_outline_color = "000000", default_color = "000415", default_shade_color = "080721", color0 = '080721', -- Dark Blue - Background color1 = 'lightblue', -- Light Blue - Labels color2 = 'orange', -- Orange - Monitored Item (Frequently Updates) color3 = 'goldenrod1', -- GoldenRod - Monitored Item (Infrequent/Versions) color4 = 'white', -- White - Headers color5 = 'SteelBlue', -- Blue - ANSI Header Art color6 = 'green3', -- ? color7 = 'white', -- White - Drive Labels color8 = 'green3', -- Light Green - Bar Green color9 = 'SteelBlue', -- Steel Blue - Bar Scales template0 = '${font Larabiefont-Regular:bold:size=10}', -- template1 = '${color1}${font Larabiefont-Regular:bold:size=10}', -- template2 = '${color9}${font Arial:size=10}', -- Bar Scales template3 = '${color4}${font Larabiefont-Regular:bold:size=8}', template4 = '${voffset -2}${goto 41}${color5}${font Arial:size=10}', -- ANSI Forks template7 = '${color5}${font Arial:size=10}', -- MORE ANSI Forks (w/o positioning} template9 = '${font Larabiefont-Regular:bold:size=10}', -- Medium text to fit. lua_load = '/home/bayouguru/.conky/sysbars.lua', lua_draw_hook_post = 'conky_widgets' } conky.text = [[ ${image ~/.conky/images/kubuntu-logo-icon.png -p 1,32 -s 34x34}\ ${image ~/.conky/images/002-warm.png -p 1,132 -s 42x50 }\ ${image ~/.conky/images/005-fan.png -p 1,193 -s 35x35}\ ${image ~/.conky/images/004-ram.png -p 1,260 -s 42x80}\ ${image ~/.conky/images/003-hard-drive.png -p 1,378 -s 38x38}\ ${image ~/.conky/images/003-hard-drive.png -p 1,440 -s 38x38}\ ${image ~/.conky/images/003-hard-drive.png -p 1,494 -s 38x38}\ ${image ~/.conky/images/006-penguin.png -p 1,574 -s 40x50}\ ${if_match "${key_caps_lock}"=="Off"}${image ~/.conky/images/green.png -p 128,30 -s 17x17}${else}${image ~/.conky/images/red.png -p 128,30 -s 17x17}${endif}${if_match "${key_num_lock}"=="On"}${image ~/.conky/images/green.png -p 239,30 -s 17x17}${else}${image ~/.conky/images/red.png -p 239,30 -s 17x17}${endif}\ ${if_match ${hwmon 2 temp 1} <= 95 }${image ~/.conky/images/green.png -p 170,126 -s 17x17}${else}${if_match ${hwmon 2 temp 1} >= 128 }${image ~/.conky/images/red.png -p 170,126 -s 17x17}${else}${image ~/.conky/images/yellow.png -p 170,126 -s 17x17}${endif}${endif}\ ${if_match ${hwmon 1 temp 1} <= 115 }${image ~/.conky/images/green.png -p 170,141 -s 17x17}${else}${if_match ${hwmon 1 temp 1} >= 135 }${image ~/.conky/images/red.png -p 170,141 -s 17x17}${else}${image ~/.conky/images/yellow.png -p 170,141 -s 17x17}${endif}${endif}\ ${if_match ${hwmon 1 temp 2} <= 110 }${image ~/.conky/images/green.png -p 170,156 -s 17x17}${else}${if_match ${hwmon 1 temp 2} >= 130 }${image ~/.conky/images/red.png -p 170,156 -s 17x17}${else}${image ~/.conky/images/yellow.png -p 170,156 -s 17x17}${endif}${endif}\ ${if_match ${hwmon 0 temp 1} <= 110 }${image ~/.conky/images/green.png -p 170,171 -s 17x17}${else}${if_match ${hwmon 0 temp 1} >= 130 }${image ~/.conky/images/red.png -p 170,171 -s 17x17}${else}${image ~/.conky/images/yellow.png -p 170,171 -s 17x17}${endif}${endif}\ ${if_match ${hwmon 3 temp 1} <= 120 }${image ~/.conky/images/green.png -p 140,382 -s 17x17}${else}${if_match ${hwmon 3 temp 1} >= 130 }${image ~/.conky/images/red.png -p 140,382 -s 17x17}${else}${image ~/.conky/images/yellow.png -p 140,382 -s 11x11}${endif}${endif}\ ${if_match ${hwmon 4 temp 1} <= 120 }${image ~/.conky/images/green.png -p 140,442 -s 17x17}${else}${if_match ${hwmon 4 temp 1} >= 130 }${image ~/.conky/images/red.png -p 140,442 -s 17x17}${else}${image ~/.conky/images/yellow.png -p 140,442 -s 17x17}${endif}${endif}\ ${if_match ${memperc} <= 80 }${image ~/.conky/images/green.png -p 198,260 -s 18x18}${else}${if_match ${memperc} >= 90 }${image ~/.conky/images/red.png -p 198,260 -s 18x18}${else}${image ~/.conky/images/yellow.png -p 198,260 -s 18x18}${endif}${endif}\ ${if_match ${fs_used_perc /} <= 80 }${image ~/.conky/images/green.png -p 11,383 -s 18x18}${image ~/.conky/images/green.png -p 198,397 -s 17x17}${else}${if_match ${fs_used_perc /} >= 90 }${image ~/.conky/images/red.png -p 11,383 -s 18x18}${image ~/.conky/images/red.png -p 198,397 -s 18x18}${else}${image ~/.conky/images/yellow.png -p 11,383 -s 18x18}${image ~/.conky/images/yellow.png -p 198,397 -s 18x18}${endif}${endif}\ ${if_match ${fs_used_perc /home/bayouguru/N-1Tb/} <= 80 }${image ~/.conky/images/green.png -p 11,445 -s 18x18}${image ~/.conky/images/green.png -p 198,457 -s 17x17}${else}${if_match ${fs_used_perc /home/bayouguru/N-1Tb/} >= 90 }${image ~/.conky/images/red.png -p 11,445 -s 18x18}${image ~/.conky/images/red.png -p 198,457 -s 18x18}${else}${image ~/.conky/images/yellow.png -p 11,445 -s 18x18}${image ~/.conky/images/yellow.png -p 198,457 -s 18x18}${endif}${endif}\ ${if_match ${swapperc} <= 80 }${image ~/.conky/images/green.png -p 11,499 -s 18x18}${image ~/.conky/images/green.png -p 103,500 -s 17x17}${else}${if_match ${swapperc} >= 90 }${image ~/.conky/images/red.png -p 11,499 -s 17x17}${image ~/.conky/images/red.png -p 103,500 -s 18x18}${else}${image ~/.conky/images/yellow.png -p 11,499 -s 18x18}${image ~/.conky/images/yellow.png -p 103,500 -s 18x18}${endif}${endif}\ ${color4}${template0}System${font} ${color5}${hr 1} ${template4}├${template1} Uptime${color2}${alignr 3}${template0}${uptime} ${template4}├${template1} CapsLock ( )${alignr}NumLock ( ) ${template4}├${template1} Updates${color2}${template0} ${execi 3600 aptitude search "~U" | wc -l | tail}${goto 176}${template1}USB ${alignr}${color2}${template0}${execpi 10 lsusb | grep -iv 'hub' | cut --fields=7- --delimiter=' ' | wc -l} ${template4}├${template1} Processes${template7} ┬${template1} Total${color2}${template0}${alignr}${processes} ${color5}${font Arial:size=10}${goto 14}┌──┘${goto 134}└${template1} Active${color2}${template0}${alignr 3} ${running_processes}${font} ${color5}${font Arial:size=10}${goto 14}└${template1} Load Averages${template7} ┬${template1} 1'${color2}${template0}${alignr}${loadavg 1} ${color2}${template0}${goto 48}${loadavg 2} ${template1}5' ${template4}${goto 143}┴${template1} 15'${color2}${template0}${alignr}${loadavg 3} ${color1}${template4}┌${template1} CPU Core${color2}${template0}${alignr}${hwmon 2 temp 1}${template1}°F ${template4}├${template1} CPU Socket${color2}${template0}${alignr}${hwmon 1 temp 1}${template1}°F ${template4}├${template1} Mainboard${color2}${template0}${alignr}${hwmon 1 temp 2}${template1}°F ${template4}└${template1} GPU Edge${color2}${template0}${alignr}${hwmon 0 temp 1}${template1}°F ${template4}┌${template1} CPU${color2}${template0}${alignr 8}${hwmon 1 fan 1}${template1} rpm${color2}${template0}${alignr}${hwmon 1 fan 1 0.0667 0,0}${template1}% ${template4}├${template1} GPU${color2}${template0}${alignr 8}${hwmon 0 fan 1}${template1} rpm${color2}${template0}${alignr}${hwmon 0 fan 1 0.0270270 0,0}${template1}% ${template4}└${template1} Case${color2}${template0}${alignr 8}${hwmon 1 fan 3}${template1} rpm${color2}${template0}${alignr}${hwmon 1 fan 3 0.0667 0,0}${template1}% ${color4}${template0}${memmax}b RAM${font} ${color5}${hr 1} ${template4}├ ${template4}├${template1} Used${color2}${template0}${goto 120}${mem}b${template0}${color2}${alignr}${memperc}${template1}% ${template4}├${template1} Free ${template8}(+ easily)${color2}${template0}${alignr}${memeasyfree}b ${template4}├${template1} Free physical${color2}${template0}${alignr}${memfree}b ${template4}├${template1} Cached${color2}${alignr}${template0}${cached}b ${template4}├${template1} Buffered${color2}${alignr}${template0}${buffers}b ${template4}└${template1} Threads${color2}${template0}${goto 160}${running_threads}${template1}${goto 200}of${color2}${template0}${alignr}${threads} ${color4}${template0}Storage${font} ${color5}${hr 1} ${template4}├${color7}${template0}${goto 58}/dev/sda${font}${goto 164}${color1}Size${color2}${alignr}${template0}${fs_size /}b ${template4}├${goto 58}${template1}Temp${color2}${template0}${goto 100}${hwmon 3 temp 1}${template1}°F${goto 164}${color1}Free${color2}${alignr}${template0}${fs_free /}b ${template4}├${goto 58}${template1}Used${template9}${color2}${goto 120}${fs_used /}b${template9}${color2}${alignr 4}${fs_used_perc /}${template1}% ${template4}└${font} ${template4}┌${color7}${template0}${goto 58}/dev/sdb${font}${goto 164}${color1}Size${color2}${template0}${alignr}${fs_size /home/bayouguru/N-1Tb/}b ${template4}├${goto 58}${template1}Temp${color2}${goto 100}${template0}${hwmon 4 temp 1}${template1}°F${goto 164}${color1}Free${color2}${alignr}${template0}${fs_free /home/bayouguru/N-1Tb}b ${template4}├${goto 58}${template1}Used${color2}${template9}${goto 120}${fs_used /home/bayouguru/N-1Tb/}b${color2}${template9}${alignr}${fs_used_perc /home/bayouguru/N-1Tb/}${template1}% ${template4}└ ${template4}┌${color7}${template0}${goto 58}/dev/sdc2 ${color1}${alignr}${template3}24Gb Swap ${template4}├${color2}${goto 55}${template9}${swap}b${color2}${template9}${goto 130}${swapperc}${template1}%${goto 166}Free${color2}${alignr}${template9}${swapfree}b ${template4}└${font} ${color4}${template0}Versions${font}${color5} ${hr 1} ${color5}${template4}├${template1} OS${template9}${color3}${alignr}Kubuntu ${execi 43200 lsb_release -d | awk '{print $3,$4}'} ${color5}${template4}├${template1} Plasma${template9}${color3}${alignr}${execi 43200 plasmashell --version | sed 's/\plasmashell //g'} ${color5}${template4}├${template1} Kernel${template9}${color3}${alignr}${execi 43200 uname -r | sed -e 's/-generic//'} ${color5}${template4}├${template1} X.org${template9}${color3}${alignr}${execi 43200 xdpyinfo | grep version: | cut -d' ' -f3} ${color5}${template4}├${template1} GPU${template9}${color3}${alignr}${execi 43200 glxinfo | grep "OpenGL version" |cut -c52-70} ${color5}${template4}├${template1} PipeWire${template9}${color3}${alignr}${execi 43200 pipewire --version | awk 'NR==2{print $NF}'} ${color5}${template4}└${template1} Conky${template9}${color3}${alignr}${conky_version} ${voffset -80}\ ]] ```
BayouGuru67 commented 1 month ago

OS is Kubuntu 22.04.5-LTS w. Plasma 5.27.11, Kernel 6.8.0-47, X.org 1.21.1.4, GPU driver Mesa 23.2.1-kubuntu, and pipewire 1.07.

Caellian commented 1 month ago

Would be affected by: #1879. Related to issue: #1001.

This is caused because variable evaluation is tied to update loop. If evaluating a script takes a very long time, it can mess with update timing.

A random cheap fix idea is to use some existing scheduler for updating the window.

But in any case, you are limited by your hardware. Even if the code was perfect (it isn't), and you ran conky on a very low spec machine, it wouldn't be able to layout and draw every time it should. #1879 uses async for networking to avoid exactly this issue, but async is very annoying in C++, esp. in combination with templates and debugging, so I'm not too enthusiastic about writing it and can't tell when it will be done.

But yeah, having the main loop run separately from everything and then skip updates would fix some issues. Parallelization is impossible without a good layout engine which doesn't exist atm. So in this respect, there's more work left to do than is completed.

Reading material: