Repository navigation
fix(webui): colour each DISK I/O column by the direction it prints - #3717
Merged
nicolargo merged 1 commit intoSep 10, 2026
Merged
Conversation
The Rps cell prints `disk.bitrate.txps` and took the decoration of `write_bytes_rate_per_sec`; the Wps cell prints `rxps` and took `read_bytes_rate_per_sec`. `disks()` fills txps from read_bytes_rate_per_sec and rxps from write_bytes_rate_per_sec, so the two columns wore each other's alert. The latency pair is crossed the same way. update_views() gives the two directions separate alerts (`rx`/`tx` headers, and `rx_latency`/`tx_latency`), so a disk saturated by reads lit up the write column and left the read one plain. The curses UI already pairs each value with its own field. Also names the txps/rxps trap in the one place it is introduced.
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.
In the WebUI's DISK I/O table the read and write columns wear each other's alert.
disks()builds each row's values like this (plugin-diskio.vue:79-86):txpsholds the read rate andrxpsthe write rate — the keys read the other way round, which is the whole trap. The cells then did:Rpsbitrate.txps(read)write_bytes_rate_per_secWpsbitrate.rxps(write)read_bytes_rate_per_secms/opRlatency.txps(read)write_latencyms/opWlatency.rxps(write)read_latencyupdate_views()computes the two directions separately —get_alert(..., header='rx')andheader='tx'for the bitrates,rx_latency/tx_latencyfor the latencies — so these are four distinct values, not one shared style. A disk saturated by reads therefore left the read column plain and lit up the write column instead.The curses UI is not affected:
msg_cursepairs each printed value with its own field (read_byteswith the read rate,write_byteswith the write rate), so the two interfaces disagreed.The change swaps the four
getDecorationfield names so each cell asks for the field it prints, and names thetxps/rxpstrap in the one place those keys are assigned, since that naming is what makes the mistake easy to repeat.Verification
npx eslint js/components/plugin-diskio.vuereports the same 5 warnings before and after the change (4 ×vue/first-attribute-linebreak, 1 ×vue/require-default-prop, all pre-existing) and 0 errors. There is no test runner underglances/outputs/static— onlylint— so there is nothing to add a unit test to; the argument is the field mapping above, which is checkable by readingdisks()next to the four cells.