Skip to content

Commit

Permalink
Fixed issues with using ParamSpec prior to its formal introduction
Browse files Browse the repository at this point in the history
  • Loading branch information
christophertubbs committed Nov 2, 2023
1 parent 6671a35 commit bd029ea
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
4 changes: 3 additions & 1 deletion python/lib/core/dmod/core/common/collection.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@

from datetime import datetime

from typing_extensions import ParamSpec

from collections.abc import Collection
from typing import Iterator

Expand All @@ -19,7 +21,7 @@
_T = typing.TypeVar("_T")
_HT = typing.TypeVar("_HT", bound=typing.Union[typing.Hashable, typing.Mapping, typing.Sequence[typing.Hashable]])

_VARIABLE_PARAMETERS = typing.ParamSpec("_VARIABLE_PARAMETERS")
_VARIABLE_PARAMETERS = ParamSpec("_VARIABLE_PARAMETERS")
"""Represents *args and **kwargs"""


Expand Down
4 changes: 3 additions & 1 deletion python/lib/core/dmod/core/events/base_function.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,14 @@
import inspect
import logging

from typing_extensions import ParamSpec

from dataclasses import field
from dataclasses import dataclass

from pydantic import root_validator

PARAMS = typing.ParamSpec("PARAMS")
PARAMS = ParamSpec("PARAMS")


class Event:
Expand Down

0 comments on commit bd029ea

Please sign in to comment.