diff --git a/changelog.d/349.misc b/changelog.d/349.misc new file mode 100644 index 00000000..997f439c --- /dev/null +++ b/changelog.d/349.misc @@ -0,0 +1 @@ +Bump development dependencies. diff --git a/mypy.ini b/mypy.ini index 221bcf20..1f147dd1 100644 --- a/mypy.ini +++ b/mypy.ini @@ -6,36 +6,9 @@ show_error_codes = True show_traceback = True mypy_path = stubs -[mypy-idna] -ignore_missing_imports = True - -[mypy-OpenSSL] -ignore_missing_imports = True - -[mypy-twisted.*] -ignore_missing_imports = True - -[mypy-jaeger_client] -ignore_missing_imports = True - -[mypy-aioapns] -ignore_missing_imports = True - -[mypy-aioapns.common] -ignore_missing_imports = True - -[mypy-service_identity.*] -ignore_missing_imports = True - [mypy-prometheus_client] ignore_missing_imports = True -[mypy-setuptools] -ignore_missing_imports = True - -[mypy-OpenSSL.*] -ignore_missing_imports = True - [mypy-py_vapid] ignore_missing_imports = True diff --git a/pyproject.toml b/pyproject.toml index b55cd96e..87cd223c 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -94,15 +94,17 @@ dependencies = [ [project.optional-dependencies] dev = [ - "black==22.3.0", + "black==23.9.1", "coverage~=5.5", - "ruff==0.0.262", - "isort~=5.0", - "mypy==0.812", - "mypy-zope==0.3.0", + "ruff==0.0.291", + "isort~=5.10", + "mypy==1.5.1", + "mypy-zope==1.0.1", "towncrier", "tox", "types-opentracing>=2.4.2", + "types-pyOpenSSL", + "types-PyYAML", "typing-extensions>=3.7.4", ] diff --git a/sygnal/helper/proxy/proxy_asyncio.py b/sygnal/helper/proxy/proxy_asyncio.py index 94bbb7ae..31c97659 100644 --- a/sygnal/helper/proxy/proxy_asyncio.py +++ b/sygnal/helper/proxy/proxy_asyncio.py @@ -166,6 +166,7 @@ async def switch_over_when_ready(self) -> Tuple[BaseTransport, Protocol]: # start_tls does NOT call connection_made on new_protocol, so we # must do it ourselves + assert transport buffered_protocol.connection_made(transport) else: # no wrapping required for non-TLS @@ -326,7 +327,7 @@ def make_protocol() -> HttpConnectProtocol: # (N.B. if we want to ever use TLS to the proxy [e.g. to protect the proxy # credentials], we can ask this to give us a TLS connection). - transport, connect_protocol = await self._wrapped_loop.create_connection( + _, connect_protocol = await self._wrapped_loop.create_connection( make_protocol, proxy_url_parts.hostname, proxy_url_parts.port ) diff --git a/sygnal/utils.py b/sygnal/utils.py index 5d82393d..1cd30f76 100644 --- a/sygnal/utils.py +++ b/sygnal/utils.py @@ -43,6 +43,7 @@ class NotificationLoggerAdapter(LoggerAdapter): def process( self, msg: str, kwargs: MutableMapping[str, Any] ) -> Tuple[str, MutableMapping[str, Any]]: + assert self.extra return f"[{self.extra['request_id']}] {msg}", kwargs diff --git a/tests/asyncio_test_helpers.py b/tests/asyncio_test_helpers.py index 20a7fdf2..32dc7d94 100644 --- a/tests/asyncio_test_helpers.py +++ b/tests/asyncio_test_helpers.py @@ -141,7 +141,9 @@ def pause_reading(self) -> None: def resume_reading(self) -> None: pass # NOP - def set_write_buffer_limits(self, high: int = None, low: int = None) -> None: + def set_write_buffer_limits( + self, high: Optional[int] = None, low: Optional[int] = None + ) -> None: pass # NOP def get_write_buffer_size(self) -> int: