Skip to content

Commit 14629eb

Browse files
committed
[ModelicaSystem*] rebase cleanup
1 parent b5879e4 commit 14629eb

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

OMPython/ModelicaSystem.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@
4343
import warnings
4444
import xml.etree.ElementTree as ET
4545

46-
from OMPython.OMCSession import OMCSessionException, OMCSessionRunData, OMCSessionZMQ, OMCProcessLocal, OMCPath
46+
from OMPython.OMCSession import OMCSessionException, OMCSessionRunData, OMCSessionZMQ, OMCProcess, OMCPath
4747

4848
# define logger using the current module name as ID
4949
logger = logging.getLogger(__name__)
@@ -262,7 +262,9 @@ def definition(self) -> OMCSessionRunData:
262262
cmd_timeout=self._timeout,
263263
)
264264

265-
omc_run_data_updated = self._session.omc_run_data_update(omc_run_data=omc_run_data)
265+
omc_run_data_updated = self._session.omc_run_data_update(
266+
omc_run_data=omc_run_data,
267+
)
266268

267269
return omc_run_data_updated
268270

@@ -315,7 +317,7 @@ def __init__(
315317
variableFilter: Optional[str] = None,
316318
customBuildDirectory: Optional[str | os.PathLike] = None,
317319
omhome: Optional[str] = None,
318-
omc_process: Optional[OMCProcessLocal] = None,
320+
omc_process: Optional[OMCProcess] = None,
319321
build: bool = True,
320322
) -> None:
321323
"""Initialize, load and build a model.
@@ -380,8 +382,6 @@ def __init__(
380382
self._linearized_states: list[str] = [] # linearization states list
381383

382384
if omc_process is not None:
383-
if not isinstance(omc_process, OMCProcessLocal):
384-
raise ModelicaSystemError("Invalid (local) omc process definition provided!")
385385
self._getconn = OMCSessionZMQ(omc_process=omc_process)
386386
else:
387387
self._getconn = OMCSessionZMQ(omhome=omhome)

0 commit comments

Comments
 (0)