Skip to content

Commit 0e441b2

Browse files
committed
Simplify AllowList constructor type annotation per PR feedback.
1 parent d522ea0 commit 0e441b2

File tree

1 file changed

+3
-3
lines changed
  • instrumentation-genai/opentelemetry-instrumentation-google-genai/src/opentelemetry/instrumentation/google_genai

1 file changed

+3
-3
lines changed

instrumentation-genai/opentelemetry-instrumentation-google-genai/src/opentelemetry/instrumentation/google_genai/allowlist_util.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414

1515
import re
1616
import os
17-
from typing import Callable, List, Optional, Set, Union
17+
from typing import Callable, Iterable, Optional, Set, Union
1818

1919
ALLOWED = True
2020
DENIED = False
@@ -69,8 +69,8 @@ def matches(self, x):
6969
class AllowList:
7070
def __init__(
7171
self,
72-
includes: Optional[Union[Set[str], List[str]]] = None,
73-
excludes: Optional[Union[Set[str], List[str]]] = None,
72+
includes: Optional[Iterable[str]] = None,
73+
excludes: Optional[Iterable[str]] = None,
7474
):
7575
self._includes = _CompoundMatcher(set(includes or []))
7676
self._excludes = _CompoundMatcher(set(excludes or []))

0 commit comments

Comments
 (0)