Enable POTA upstream logging as this was previously proved. #95 Improve logging

This commit is contained in:
Ian Renton
2026-09-27 14:44:17 +01:00
parent e6f0f737d0
commit 62976cba1f
10 changed files with 20 additions and 17 deletions
+4
View File
@@ -214,6 +214,7 @@ class APISpotHandler(tornado.web.RequestHandler):
spot.source = "API"
spot.infer_missing()
self._spots.set(spot.id, spot)
logger.info(f"Spot of {spot.dx_call} by {spot.de_call} added to Spothole.")
if upstream_warnings:
saved_locally_note = "" if any_upstream_succeeded else " The spot was saved to Spothole only."
@@ -245,6 +246,9 @@ class APISpotHandler(tornado.web.RequestHandler):
# Submit spot to the upstream provider. Run in a separate thread otherwise this blocks the whole web server
# for everyone!
await IOLoop.current().run_in_executor(None, provider.submit_spot, spot, credentials)
logger.info(
f"Spot of {spot.dx_call} by {spot.de_call} submitted upstream to {upstream_provider_name}."
)
# Trigger a re-poll after 3 second so the spot appears quickly. (Submitting to a cluster node is slower than
# this, but we get data as a live stream from cluster anyway, so force_poll does nothing in that case. This
# is really just for the HTTP providers when we submit a spot to them)