Skip to content

Commit ebc4a48

Browse files
committed
[ModelicaSystem] rebase fallout - fix pathlib usage
1 parent 4172c6b commit ebc4a48

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

OMPython/ModelicaSystem.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1563,7 +1563,7 @@ def convertMo2Fmu(
15631563
fmuType: str = "me_cs",
15641564
fileNamePrefix: Optional[str] = None,
15651565
includeResources: bool = True,
1566-
) -> pathlib.Path:
1566+
) -> OMCPath:
15671567
"""Translate the model into a Functional Mockup Unit.
15681568
15691569
Args:
@@ -1600,7 +1600,7 @@ def convertMo2Fmu(
16001600
def convertFmu2Mo(
16011601
self,
16021602
fmu: os.PathLike,
1603-
) -> pathlib.Path:
1603+
) -> OMCPath:
16041604
"""
16051605
In order to load FMU, at first it needs to be translated into Modelica model. This method is used to generate
16061606
Modelica model from the given FMU. It generates "fmuName_me_FMU.mo".
@@ -1609,7 +1609,7 @@ def convertFmu2Mo(
16091609
>>> convertFmu2Mo("c:/BouncingBall.Fmu")
16101610
"""
16111611

1612-
fmu_path = pathlib.Path(fmu)
1612+
fmu_path = self._session.omcpath(fmu)
16131613

16141614
filename = self._requestApi(apiName='importFMU', entity=fmu_path.as_posix())
16151615
filepath = self._work_dir / filename

0 commit comments

Comments
 (0)