Skip to content

Commit dde235b

Browse files
chore: replace usage of Type with type standard collection (GoogleCloudPlatform#1220)
1 parent afbe0a5 commit dde235b

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

google/cloud/sql/connector/connector.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
import logging
2222
from threading import Thread
2323
from types import TracebackType
24-
from typing import Any, Optional, Type, Union
24+
from typing import Any, Optional, Union
2525

2626
import google.auth
2727
from google.auth.credentials import Credentials
@@ -65,7 +65,7 @@ def __init__(
6565
user_agent: Optional[str] = None,
6666
universe_domain: Optional[str] = None,
6767
refresh_strategy: str | RefreshStrategy = RefreshStrategy.BACKGROUND,
68-
resolver: Type[DefaultResolver] | Type[DnsResolver] = DefaultResolver,
68+
resolver: type[DefaultResolver] | type[DnsResolver] = DefaultResolver,
6969
) -> None:
7070
"""Initializes a Connector instance.
7171
@@ -391,7 +391,7 @@ def __enter__(self) -> Any:
391391

392392
def __exit__(
393393
self,
394-
exc_type: Optional[Type[BaseException]],
394+
exc_type: Optional[type[BaseException]],
395395
exc_val: Optional[BaseException],
396396
exc_tb: Optional[TracebackType],
397397
) -> None:
@@ -404,7 +404,7 @@ async def __aenter__(self) -> Any:
404404

405405
async def __aexit__(
406406
self,
407-
exc_type: Optional[Type[BaseException]],
407+
exc_type: Optional[type[BaseException]],
408408
exc_val: Optional[BaseException],
409409
exc_tb: Optional[TracebackType],
410410
) -> None:

0 commit comments

Comments
 (0)