From a119b4b4bf0495083f84dcea814e1c75a6a0ebc8 Mon Sep 17 00:00:00 2001 From: Marcelo Trylesinski Date: Fri, 20 Dec 2024 12:29:59 +0100 Subject: [PATCH] mypy: don't follow imports --- mypy.ini | 4 +++- opentelemetry-sdk/src/opentelemetry/sdk/util/__init__.pyi | 4 ++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/mypy.ini b/mypy.ini index dca41f8c6be..4c368fcd944 100644 --- a/mypy.ini +++ b/mypy.ini @@ -17,4 +17,6 @@ strict_equality = True strict_optional = True no_implicit_optional = True - no_implicit_reexport = True \ No newline at end of file + no_implicit_reexport = True + # https://mypy.readthedocs.io/en/stable/running_mypy.html#follow-imports + follow_imports = silent diff --git a/opentelemetry-sdk/src/opentelemetry/sdk/util/__init__.pyi b/opentelemetry-sdk/src/opentelemetry/sdk/util/__init__.pyi index e949ad4ebc3..55042fcf0ee 100644 --- a/opentelemetry-sdk/src/opentelemetry/sdk/util/__init__.pyi +++ b/opentelemetry-sdk/src/opentelemetry/sdk/util/__init__.pyi @@ -49,8 +49,8 @@ class BoundedList(Sequence[_T]): @overload def __getitem__(self, s: slice) -> Sequence[_T]: ... def __len__(self) -> int: ... - def append(self, item: _T): ... - def extend(self, seq: Sequence[_T]): ... + def append(self, item: _T) -> None: ... + def extend(self, seq: Sequence[_T]) -> None: ... @classmethod def from_seq(cls, maxlen: int, seq: Iterable[_T]) -> BoundedList[_T]: ... # pylint: disable=undefined-variable