1
0
mirror of https://github.com/craigerl/aprsd.git synced 2024-11-25 01:18:43 -05:00

Fixed a bug with OWMWeatherPlugin

The weather plugin wasn't able to find the from callsign,
so all of the weather reports were random and wrong.
This commit is contained in:
Hemna 2023-11-24 19:15:52 -05:00
parent a8f73610fe
commit 0433768784
2 changed files with 2 additions and 1 deletions

View File

@ -76,6 +76,7 @@ def fetch_openweathermap(api_key, lat, lon, units="metric", exclude=None):
exclude,
)
)
LOG.debug(f"Fetching OWM weather '{url}'")
response = requests.get(url)
except Exception as e:
LOG.error(e)

View File

@ -211,7 +211,7 @@ class OWMWeatherPlugin(plugin.APRSDRegexCommandPluginBase):
@trace.trace
def process(self, packet):
fromcall = packet.get("from")
fromcall = packet.get("from_call")
message = packet.get("message_text", None)
# ack = packet.get("msgNo", "0")
LOG.info(f"OWMWeather Plugin '{message}'")