feat(curses): add configurable stripchart scale#602
Closed
Komzpa wants to merge 1 commit into
Closed
Conversation
Contributor
Author
|
Superseded by the updated #580, which now carries the stripchart scale option together with the related curses option plumbing so the merge stack no longer has an internal ui/mtr.c conflict. |
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.
Summary
This is a modern replacement for the old fixed-scale experiment in #227, following the shape discussed there.
The default stripchart behavior remains dynamic. A fixed scale is only used when requested with:
--scale fast--scale average--scale slow--scale 5:15:25:35:45:55:101:200:400style custom thresholdsThe
averagepreset uses the threshold sequence Roger suggested in #227. Custom scales require nine strictly increasing millisecond thresholds, matching the stripchart symbols before the final overflow marker.Supersedes #227.
Validation
make -j "$(nproc)"git diff --checksudo python3 ./test/cmdparse.py./mtr --help./mtr --report --scale average -c 1 127.0.0.1./mtr --report --scale 5:15:25:35:45:55:101:200:400 -c 1 127.0.0.1./mtr --report --scale 5:4:25:35:45:55:101:200:400 -c 1 127.0.0.1rejects the non-increasing scaletimeout 3s script -q -c 'TERM=xterm ./mtr --displaymode 1 --scale average 127.0.0.1' /tmp/mtr-scale.typescriptshowedScale: .:5 ms ... c:400 ms >