OMPython
OMPython copied to clipboard
Make "ModelicaSystem" aware of "uses" annotation
When filing #63 I thought rather than having to rely on manually specifying the used libraries in the ModelicaSystem
call like:
mod=ModelicaSystem("BouncingBall.mo","BouncingBall","Modelica")
OMPython should be clever enough to interpret the uses
annotation inside the loaded model library.
This is related to trac ticket 2926. ModelicaSystem
relies on OMC API loadFile
.
That ticket you are pointing to seems to indicate that OMC API already supports this. Just the loading from packages from the same working dir is not working currently. However not providing the third argument will make the ModelicaSystem call fail if the opened class uses any other library. Even if that library is on the MODELICAPATH (which Modelica
most definitely is).
Just made a simple model with uses annotation and it worked fine.
OK let me check this once again and come back to you.
Hello, related to this issue, I was wondering if there was ever a feature introduced to allow the running of models without manually specifying the used libraries in the third argument.