Skip to content

Fix logging when loggingOn is fmi3False#671

Open
pmai wants to merge 1 commit intomainfrom
fix-logging-when-disabled
Open

Fix logging when loggingOn is fmi3False#671
pmai wants to merge 1 commit intomainfrom
fix-logging-when-disabled

Conversation

@pmai
Copy link
Collaborator

@pmai pmai commented Dec 4, 2025

This PR fixes the logging behavior to comply with FMI 3.0 standard when loggingOn = fmi3False is passed to the instantiate function.

Fixes #670 and addresses modelica/fmi-standard#2072.

- Set comp->logErrors to loggingOn instead of always true
- Add loggingOn checks to all direct cbLogger calls in createModelInstance
- Ensures no logging callbacks are made when loggingOn = fmi3False

Fixes modelica/fmi-standard#2072
@Tc-Fast
Copy link

Tc-Fast commented Jan 27, 2026

Since logging was clarified in FMI, this PR is obsolete and can be closed
modelica/fmi-standard#2097

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Reference FMUs should call logMessage only when loggingOn is not fmi3False

2 participants