From 90b42cf6fe7f113e9de0e37fec74009655c575ed Mon Sep 17 00:00:00 2001 From: Shubhashish-Chakraborty Date: Fri, 24 Apr 2026 16:19:04 +0530 Subject: [PATCH] fix typeerror during test collection --- src/worker.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/worker.py b/src/worker.py index fbeccc0..32b7ca3 100644 --- a/src/worker.py +++ b/src/worker.py @@ -40,7 +40,7 @@ import re import traceback from types import SimpleNamespace -from typing import Any, Dict +from typing import Any, Dict, Optional from urllib.parse import urlparse, parse_qs from workers import Response, DurableObject @@ -2147,7 +2147,7 @@ async def on_fetch(request, env): # --------------------------------------------------------------------------- async def _create_notification(env, user_id: str, type_: str, title: str, - message: str, related_id: str | None = None) -> None: + message: str, related_id: Optional[str] = None) -> None: """Internal helper called by other handlers to create a notification. Silently swallows errors so a notification failure never breaks the