Browse Source

mauigapi/thread: add better logging

Signed-off-by: Sumner Evans <sumner@beeper.com>
Sumner Evans 2 years ago
parent
commit
acf6273bb7
1 changed files with 3 additions and 1 deletions
  1. 3 1
      mauigpapi/http/thread.py

+ 3 - 1
mauigpapi/http/thread.py

@@ -62,7 +62,6 @@ class ThreadAPI(BaseAndroidAPI):
         local_limit: int | None = None,
         rate_limit_exceeded_backoff: float = 60.0,
     ) -> AsyncIterable[tuple[Thread, int | None, str | None]]:
-        print("ITER INBOX")
         thread_counter = 0
         if start_at:
             cursor = start_at.inbox.oldest_cursor
@@ -87,6 +86,9 @@ class ThreadAPI(BaseAndroidAPI):
                 )
                 await asyncio.sleep(rate_limit_exceeded_backoff)
                 continue
+            except Exception:
+                self.log.exception("Failed to fetch more threads")
+                raise
 
             seq_id = resp.seq_id
             cursor = resp.inbox.oldest_cursor