Repository navigation
fix(plugins): follow the instrument value range on the Y axis - #394
Merged
Merged
Conversation
Assisted-by: Claude Opus 5.5
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.
The instrument window recomputed its axes only when the X axis changed (size or bounds of the signals), so a new
InstrumentFrame.value_rangewith the same time base was ignored. In the oscilloscope simulator, changing a channel scale or offset left the Y axis on the previous setting.Now, when only the value range changes, the Y axis follows it (or is autoscaled alone when the range becomes
None), and the user's zoom along X is kept, as when changing V/div on a real oscilloscope. A change of the X axis still rescales both axes.Tests
plugin_tools_app_test.pynow zooms along X, then renders a frame with the same X and a new range: Y follows and the X zoom is kept; without a range, Y is autoscaled alone; a new X axis is rescaled. This test fails on the previous code (Y stayed at (-2, 2) instead of (-5, 5)).plugin_generator_unit_test.pyfailures are environmental:sigimaxmissing in a subprocess).DataLab-Web is not affected: a browser probe on the unchanged code showed that, after a user zoom, the Y axis follows a new value range and the X zoom is kept.
Assisted-by: Claude Opus 5.5