-
Notifications
You must be signed in to change notification settings - Fork 41
Feature/45 reset #47
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature/45 reset #47
Conversation
We should probably consider changing the function definitions for def _get_fmu_state(self) -> Dict[int, Any]:
def _set_fmu_state(self, state: Dict[int, Any]): To use |
Dammit, I went about this in the wrong way. We could just re-instantiate the Python code as a whole. That would guarantee correct behavior.. |
683bc8d
to
c91ae78
Compare
Good to go. Works with integration test and FMI4j. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As the Python class definition won't change, I would recommend storing the pClass
object instead of pModule
as PySlaveInstance
member. So initialize
will only dismiss the previous instance and create a new one.
That seems to crash both pyfmi and FMI4j |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok so let's stick with your code then. Thanks for trying.
Closes #45