Skip to content

Further improve on the method to retrieve simulation data from outside of OpenCOR#444

Merged
agarny merged 4 commits intoopencor:mainfrom
agarny:issue443
Mar 4, 2026
Merged

Further improve on the method to retrieve simulation data from outside of OpenCOR#444
agarny merged 4 commits intoopencor:mainfrom
agarny:issue443

Conversation

@agarny
Copy link
Contributor

@agarny agarny commented Mar 4, 2026

Fixes #443.

Copilot AI review requested due to automatic review settings March 4, 2026 05:30
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates OpenCOR’s external simulation-data API (Fixes #443) by replacing one-off data retrieval with a tracking-based mechanism that emits updated simulation data whenever the interactive simulation refreshes.

Changes:

  • Replace the exposed simulationData() API with trackSimulationData() / untrackSimulationData() / untrackAllSimulationData() and emit simulationData events on updates.
  • Propagate a “simulation data changed” signal from SimulationExperimentView up to OpenCOR, triggering re-emission of tracked simulation data.
  • Bump package versions and remove the no-longer-used HUGE_DELAY constant.

Reviewed changes

Copilot reviewed 16 out of 19 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
src/renderer/src/components/widgets/InputWidget.vue Minor ordering/formatting change around emits/props.
src/renderer/src/components/widgets/InputScientificNumber.vue Minor formatting (blank line) for consistency.
src/renderer/src/components/widgets/GraphPanelWidget.vue Minor formatting (blank line) for consistency.
src/renderer/src/components/views/SimulationExperimentView.vue Adds simulationData emit to signal that interactive simulation data has refreshed.
src/renderer/src/components/propertyEditors/SimulationPropertyEditor.vue Removes a now-unneeded @ts-expect-error comment.
src/renderer/src/components/propertyEditors/PropertyEditor.vue Reorders columnWidth definition after emits (formatting/structure).
src/renderer/src/components/dialogs/YesNoQuestionDialog.vue Moves defineEmits after defineProps (formatting/structure).
src/renderer/src/components/dialogs/OpenRemoteDialog.vue Minor formatting (blank line) for consistency.
src/renderer/src/components/dialogs/OkMessageDialog.vue Minor formatting (blank line) for consistency.
src/renderer/src/components/OpenCOR.vue Implements tracking/untracking + re-emits updated tracked simulation data to external consumers.
src/renderer/src/components/ContentsComponent.vue Propagates simulationData signal upward; simplifies simulation-only data retrieval retry logic.
src/renderer/src/common/constants.ts Removes HUGE_DELAY constant (no longer used).
src/renderer/src/AppWithSimulationData.vue Updates example usage to track/untrack model parameters and react to simulationData events.
src/renderer/package.json Bumps renderer package version.
src/renderer/index.ts Adds exported TS interfaces for exposed methods and emitted events.
src/renderer/index.d.ts Re-exports new public types.
src/renderer/bun.lock Lockfile update (node-releases).
package.json Bumps root package version.
bun.lock Lockfile update (node-releases).

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

You can also share your feedback on Copilot code review. Take the survey.

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 16 out of 19 changed files in this pull request and generated no new comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

You can also share your feedback on Copilot code review. Take the survey.

@agarny agarny merged commit 40f9f47 into opencor:main Mar 4, 2026
12 checks passed
@agarny agarny deleted the issue443 branch March 4, 2026 06:31
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.

Further improve on the method to retrieve simulation data from outside of OpenCOR

2 participants