Repository navigation
Let test.py set the OMPlot page of a report - #391
Merged
Merged
Conversation
A failed verification links to the OMPlot page on the playground, and that page fetches the two .mat files itself. This does not work for a report on a local machine or behind a login, such as a private GitLab instance (OpenModelica/OpenModelica#16732). Add --omplot to set the page. A relative URL is resolved against the report, so a copy of OMPlot can be hosted with the results. The default stays the playground, and no result data goes into the HTML. OMPlot cannot fetch files from file://, so there the link stays a download of the .diff.mat file. Assisted-by: Claude Opus 5.5
AnHeuermann
enabled auto-merge (squash)
November 4, 2026 10:09
AnHeuermann
disabled auto-merge
November 4, 2026 10:39
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Makes the verification plot usable for a report on a local machine or on a private server, see OpenModelica/OpenModelica#16732 (comment). This replaces #386, and follows the suggestion there to host the OMPlot WASM with the report.
Problem
A failed verification links to the OMPlot page on the playground, and that page fetches the two
.matfiles itself. The files must therefore be public and allow cross-origin reads. The link does not work for a report behind a login or on a private network.Approach
test.py --omplot=URLsets the OMPlot page. A relative URL is resolved against the library's report page, so a copy of OMPlot can be hosted with the results and reads them from the same origin.file://, so there the link stays a download of the.diff.matfile.install-result-web. It is static files, about 2.4 MB.openmodelica-library-testing-gitlab will use this: its image will contain OMPlot and pass
--omplot. That change needs the merge commit of this PR, so it comes after this one.Testing
Done locally with an AI agent (Claude), which also wrote the change.
test.pythrough the openmodelica-library-testing-gitlab image on its example library, with a copy of OMPlot in the results.nosniffand served.wasmwith the wrong MIME type. The browser contacted only that server.file://: the link is a download of the.diff.matfile.Not tested: a report generated with the default URL (the only change for it is that the URL goes through
new URL()), a real private GitLab instance, Firefox and Windows. CI has not run yet.🤖 Generated with Claude Code