Author: sebb
Date: Tue Jun 24 11:00:54 2025
New Revision: 1926684

URL: http://svn.apache.org/viewvc?rev=1926684&view=rev
Log:
If we cannot add a note, then wrap the exception to give better info

Modified:
    comdev/reporter.apache.org/trunk/scripts/mailglomper2.py

Modified: comdev/reporter.apache.org/trunk/scripts/mailglomper2.py
URL: 
http://svn.apache.org/viewvc/comdev/reporter.apache.org/trunk/scripts/mailglomper2.py?rev=1926684&r1=1926683&r2=1926684&view=diff
==============================================================================
--- comdev/reporter.apache.org/trunk/scripts/mailglomper2.py (original)
+++ comdev/reporter.apache.org/trunk/scripts/mailglomper2.py Tue Jun 24 
11:00:54 2025
@@ -106,6 +106,8 @@ async def weekly_stats(client, listpart,
         tsprint(f"Failed fetching {url}: {err}")
         if hasattr(err, 'add_note'):
             err.add_note(f"Failed fetching {url}: {err}")
+        else:
+            raise RuntimeError(f"Failed fetching {url}") from err
         raise
     weekly = {}
     count = 0
@@ -176,6 +178,8 @@ async def gather_stats():
             tsprint(f"While processing {listpart}@{domainpart} failed with 
{str(e)}")
             if hasattr(e, 'add_note'):
                 e.add_note(f"While processing {listpart}@{domainpart}")
+            else:
+                raise RuntimeError(f"While processing 
{listpart}@{domainpart}") from e
             raise
 
         if interrupted:


Reply via email to