This is an automated email from the ASF dual-hosted git repository.

sebbASF pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-ponymail-foal.git


The following commit(s) were added to refs/heads/master by this push:
     new 600bd7a  Satisfy mypy
600bd7a is described below

commit 600bd7a27cb57a47eac7e4aea208c9880ae6bbea
Author: Sebb <[email protected]>
AuthorDate: Fri Jun 19 21:51:54 2026 +0100

    Satisfy mypy
---
 server/endpoints/gravatar.py | 5 +++--
 tools/import-mbox.py         | 3 ++-
 2 files changed, 5 insertions(+), 3 deletions(-)

diff --git a/server/endpoints/gravatar.py b/server/endpoints/gravatar.py
index cbd190c..6622c70 100644
--- a/server/endpoints/gravatar.py
+++ b/server/endpoints/gravatar.py
@@ -23,12 +23,13 @@ import aiohttp
 import aiohttp.web
 import base64
 import string
+import typing
 
 CACHE_LIMIT = 25000  # Store a maximum of 25,000 gravatars in memory at any 
given time (25k x 5kb ≃125mb)
 GRAVATAR_URL = "https://secure.gravatar.com/avatar/%s.png?s=96&r=g&d=mm";
 
-gravatars = []
-gravatar_cache = {}
+gravatars: list[str] = []
+gravatar_cache: dict[str, typing.Any] = {}
 gravatar_default = base64.b64decode("""\
 /9j/4AAQSkZJRgABAQEAYABgAAD//gA7Q1JFQVRPUjogZ2QtanBlZyB2MS4wICh1c2luZyBJSkcgSlB
 FRyB2NjIpLCBxdWFsaXR5ID0gOTAK/9sAQwADAgIDAgIDAwMDBAMDBAUIBQUEBAUKBwcGCAwKDAwLCg
diff --git a/tools/import-mbox.py b/tools/import-mbox.py
index 5426d95..bdd8bdc 100755
--- a/tools/import-mbox.py
+++ b/tools/import-mbox.py
@@ -34,6 +34,7 @@ from os import listdir
 from os.path import isdir, isfile, join
 from threading import Lock, Thread
 from urllib.request import urlopen
+import typing
 
 # TODO: Fix this by creating a main() method
 # pylint: disable=redefined-outer-name
@@ -72,7 +73,7 @@ imap = False
 list_override = None
 project = ""
 filebased = False
-fileToLID = {}
+fileToLID: dict[typing.Any, str] = {}
 interactive = False
 extension = ".mbox"
 piperWeirdness = False

Reply via email to