Bug: Weather slow to update, sometimes gives unknown location, can't refresh
Describe the bug
When using the weather plugin in Dracula, I find that the weather often lags behind what it actually is -- for example, it may be 58 degrees and sunny at 11am and 65 degrees and rainy by 2pm, but the plugin will continue to show 58 degrees and sunny for hours without changing. Eventually it will change, at seemingly arbitrary times. I know the plugin retrieves weather from wttr.in, and if I query wttr.in myself I will rarely find the same weather Dracula is showing for my location. Reloading .tmux.conf or reinstalling plugins does not seem to refresh the weather API query.
Additionally I got this error today, but that's almost certainly because wttr.in seems to be down at the moment. This is an unrelated issue (and no big deal for me), but the blurred segment is my latitude and longitude and I see that weather.sh is intended to protect against PI leaks. Another issue is that this error is overlapping my clock.
To Reproduce
Using weather plugin as intended.
Expected behavior
I would expect the weather to query the weather API at more frequent intervals. I would also expect reloading my .tmux.conf to refresh the weather to the current conditions.
Screenshots
See link above
System
- OS: Ubuntu 24.04
- Tmux Version: 3.4
I tried default settings, disabling weather, setting a fixed location, etc.
Screenshots
System
- OS: macOS 15.3.2 24D81 arm64
- tmux 3.5a
IDK why or how, but only after posting do I actually get a fix. What I did doesn't make sense but here are the steps I've taken leading up to me no longer facing the problem.
- added
set -g @dracula-plugins "cpu-usage gpu-usage ram-usage"to my tmux config - quit tmux
- ran
tmux refreshandtmux refresh-clienteven though no tmux server was running - ran tmux
I am very sure that when I had set -g @dracula-plugins "cpu-usage gpu-usage ram-usage" and ran :refresh-client while in a session and even closed all sessions and re-opened, I was still seeing the weather status with unknown location.
Screenshots
I have started getting "Weather Unavailable" as well, and I think the culprit is a refactor done a couple months back.
Could you try opening .tmux/plugins/tmux/scripts/weather.sh and removing the '!' from line 104? (you might have to close and re-open tmux for the changes to get applied)
After making the change it seems to be working initially at least, but it still won't update so I'll do a bit more tinkering later on.
@OddKMS Removed the ! from line 104. It does change anything. Funny thing is, I have removed the weather lines from .tmux.conf, still it shows the "Unknown location..." thing