Skip to content

Commit 37d1bd0

Browse files
committed
remove some more __future__ annotations imports, possible #42 fix
Signed-off-by: Lance-Drane <Lance-Drane@users.noreply.github.com>
1 parent 675c427 commit 37d1bd0

3 files changed

Lines changed: 6 additions & 19 deletions

File tree

src/intersect_sdk/client.py

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,7 @@
1010
Most useful definitions and typings will be found in the client_callback_definitions module.
1111
"""
1212

13-
from __future__ import annotations
14-
1513
import time
16-
from typing import TYPE_CHECKING
1714
from uuid import uuid4
1815

1916
from pydantic import ValidationError
@@ -37,17 +34,13 @@
3734
from ._internal.utils import die, send_os_signal
3835
from ._internal.version_resolver import resolve_user_version
3936
from .client_callback_definitions import (
37+
INTERSECT_CLIENT_EVENT_CALLBACK_TYPE,
38+
INTERSECT_CLIENT_RESPONSE_CALLBACK_TYPE,
4039
IntersectClientCallback,
4140
)
4241
from .config.client import IntersectClientConfig
4342
from .config.shared import HierarchyConfig
44-
45-
if TYPE_CHECKING:
46-
from .client_callback_definitions import (
47-
INTERSECT_CLIENT_EVENT_CALLBACK_TYPE,
48-
INTERSECT_CLIENT_RESPONSE_CALLBACK_TYPE,
49-
)
50-
from .shared_callback_definitions import IntersectDirectMessageParams
43+
from .shared_callback_definitions import IntersectDirectMessageParams
5144

5245

5346
@final

src/intersect_sdk/service.py

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -14,13 +14,11 @@
1414
Most useful definitions and typings will be found in the service_definitions module.
1515
"""
1616

17-
from __future__ import annotations
18-
1917
import time
2018
from collections import defaultdict
2119
from threading import Lock
2220
from types import MappingProxyType
23-
from typing import TYPE_CHECKING, Any, Literal
21+
from typing import Any, Literal
2422
from uuid import UUID, uuid1, uuid3, uuid4
2523

2624
from pydantic import ConfigDict, ValidationError, validate_call
@@ -32,6 +30,7 @@
3230
)
3331
from ._internal.data_plane.data_plane_manager import DataPlaneManager
3432
from ._internal.exceptions import IntersectApplicationError, IntersectError
33+
from ._internal.function_metadata import FunctionMetadata
3534
from ._internal.generic_serializer import GENERIC_MESSAGE_SERIALIZER
3635
from ._internal.interfaces import IntersectEventObserver
3736
from ._internal.logger import logger
@@ -68,9 +67,6 @@
6867
)
6968
from .version import version_string
7069

71-
if TYPE_CHECKING:
72-
from ._internal.function_metadata import FunctionMetadata
73-
7470

7571
@final
7672
class IntersectService(IntersectEventObserver):
@@ -686,7 +682,7 @@ def _process_external_requests(self) -> None:
686682
del extreq
687683
self._external_requests_lock.release_lock()
688684

689-
def _process_external_request(self, extreq: IntersectService._ExternalRequest) -> None:
685+
def _process_external_request(self, extreq: _ExternalRequest) -> None:
690686
if extreq.request_state == 'unhandled':
691687
# use temporary intermediate state to avoid sending message twice
692688
extreq.request_state = 'sending'

tests/unit/test_base_capability_implementation.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
from __future__ import annotations
2-
31
from typing import Any
42
from uuid import UUID, uuid4
53

0 commit comments

Comments
 (0)