diff --git a/hvcc/core/hv2ir/types/IR.py b/hvcc/core/hv2ir/types/IR.py index dc2b9d2..06169a5 100644 --- a/hvcc/core/hv2ir/types/IR.py +++ b/hvcc/core/hv2ir/types/IR.py @@ -1,5 +1,5 @@ from pydantic import BaseModel, RootModel -from typing import List, Optional, Union, Literal +from typing import Dict, List, Optional, Union, Literal IRConnectionType = Literal["-->", "~i>", "~f>", "signal"] @@ -39,7 +39,7 @@ class IRNode(BaseModel): class HeavyIRType(RootModel): - root: dict[str, IRNode] + root: Dict[str, IRNode] if __name__ == "__main__": diff --git a/hvcc/core/hv2ir/types/Lang.py b/hvcc/core/hv2ir/types/Lang.py index 0f790cb..2dd9c29 100644 --- a/hvcc/core/hv2ir/types/Lang.py +++ b/hvcc/core/hv2ir/types/Lang.py @@ -35,7 +35,7 @@ class LangNode(BaseModel): class HeavyLangType(RootModel): - root: dict[str, LangNode] + root: Dict[str, LangNode] if __name__ == "__main__": diff --git a/hvcc/interpreters/pd2hv/PdGraph.py b/hvcc/interpreters/pd2hv/PdGraph.py index e5a1b47..ea0eda2 100644 --- a/hvcc/interpreters/pd2hv/PdGraph.py +++ b/hvcc/interpreters/pd2hv/PdGraph.py @@ -118,7 +118,14 @@ def add_parsed_connection(self, from_index: int, from_outlet: int, to_index: int "Have all inlets and outlets been declared?", NotificationEnum.ERROR_UNABLE_TO_CONNECT_OBJECTS) - def add_hv_arg(self, arg_index: int, name: str, value_type: str, default_value: str, required: bool) -> None: + def add_hv_arg( + self, + arg_index: int, + name: str, + value_type: str, + default_value: Optional[str], + required: bool + ) -> None: """ Add a Heavy argument to the graph. Indicies are from zero (not one, like Pd). """ # ensure that self.hv_args is big enough, as heavy arguments are not