]> git.ipfire.org Git - thirdparty/starlette.git/commitdiff
Update for new mypy 653/head
authorDavid Montague <david@exactrics.com>
Wed, 2 Oct 2019 07:12:34 +0000 (00:12 -0700)
committerDavid Montague <david@exactrics.com>
Wed, 2 Oct 2019 07:14:37 +0000 (00:14 -0700)
starlette/datastructures.py
starlette/testclient.py

index bc5ae36fd738985dd8487ab9c3ee6c2f0e8cf21b..087a27f530a341886815c4a06c7e706c507d3042 100644 (file)
@@ -161,7 +161,7 @@ class URLPath(str):
     Used by the routing to return `url_path_for` matches.
     """
 
-    def __new__(cls, path: str, protocol: str = "", host: str = "") -> str:
+    def __new__(cls, path: str, protocol: str = "", host: str = "") -> "URLPath":
         assert protocol in ("http", "websocket", "")
         return str.__new__(cls, path)  # type: ignore
 
index d1b8bff90ff5db47fb77bcdb13b140a4183409f4..5ec52bec5788af340eea7d53e5f81f77031c1a95 100644 (file)
@@ -382,7 +382,7 @@ class TestClient(requests.Session):
         self.app = asgi_app
         self.base_url = base_url
 
-    def request(
+    def request(  # type: ignore
         self,
         method: str,
         url: str,