Repository navigation
Label the funders histogram axes, and quiet the clean checks on /relation_integrity - #537
Merged
Merged
Conversation
dis_plots had no single-series vertical bar chart - only stacked_bar_chart and hbar_chart, which is horizontal - so the funders histogram was drawn by stacking one series. That renders correctly, since vbar_stack of a single series is a plain vbar, but it left the chart with nothing naming its axes. stacked_bar_chart identifies its series through a legend, so it never sets an axis label. Of its thirteen callers the funders histogram is the only one passing legend=False, and the only single-series one: having suppressed the legend it had no label of any kind left. The other twelve are genuinely stacked and read fine from their legends, so they are untouched. bar_chart takes x_label and y_label, defaulting to the field names, and is otherwise the same chart: same color, grid, baseline and ghostwhite background, and the same _make_clickable drill-down support as its neighbors. No legend to suppress. The histogram now reads "Funders named on a record" against "Records". Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
…ctions A check with no findings rendered three blocks: the heading, the paragraph explaining the check, and "Nothing found." Four of the eight checks are clean on current data, so half the page was explanations of things that had not happened, pushing the sections that do need attention down the screen. The heading stays. It is what makes the severity-band counts reconcile, and a count of zero is itself the useful statement: the check ran and found nothing. The paragraph does not stay - it explains what to do about a finding, which is moot when there are none. Nothing changes for a section that has findings. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
The card row carried one card per check, so half of it was cards reading zero whose link led to "Nothing found." The row is the at-a-glance summary of what needs attention; a zero belongs in it only if nothing else does. Current data: eight checks, four clean, so the row goes from eight cards to four. The section headings below still carry their zero, so a check that ran and found nothing is still visible - it just no longer competes with the findings for the top of the page. Guarded for the all-clean case, where the list is empty and stat_cards would otherwise render a bare row: that says "Every check is clean." Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
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.
Two unrelated UI fixes, three commits.
/funders — the histogram had no axis labels
dis_plotshas no single-series vertical bar chart. The only bar options arestacked_bar_chartandhbar_chart, which is horizontal — so the histogramwas drawn by stacking a single series. That renders correctly (
vbar_stackofone series is a plain
vbar), but it left the chart with nothing naming itsaxes.
The cause is that
stacked_bar_chartidentifies its series through a legend,so it never sets an axis label. Of its thirteen callers the funders histogram
is the only one passing
legend=False, and the only single-series one:having suppressed the legend it had no label of any kind left. The other twelve
are genuinely stacked, read fine from their legends, and are untouched.
Adds
bar_chart— the vertical counterpart tohbar_chart— takingx_labeland
y_labelthat default to the field names. Same color, grid, baseline andbackground as before, so the only visual change is the labels, and it carries
the same
_make_clickabledrill-down support as its neighbours. No legend tosuppress.
The histogram now reads Funders named on a record against Records.
/relation_integrity — clean checks were shouting
Eight checks run; four are clean on current data. Each clean one rendered a
heading, a paragraph explaining the check, and "Nothing found." — and got a
summary card at the top reading
0, linking down to that "Nothing found."Half the page, and half the card row, was about things that had not happened.
Two changes, both only affecting checks with no findings:
which is moot when there are none. The heading stays: it is what makes the
severity-band counts reconcile, and
(0)is itself the useful statement —the check ran and found nothing.
attention. Current data takes it from eight cards to four. The
(0)headingsbelow still show every check that ran, so nothing is hidden.
Guarded for the all-clean case, where the card list is empty and
stat_cardswould render a bare row: that reads "Every check is clean."
Nothing changes for a section that has findings.
Verification
Both pages checked against a running server.
The chart's rendered Bokeh payload carries both labels and no legend:
"axis_label":"Funders named on a record"
"axis_label":"Records"
"VBar" × 3 Legend × 0
/relation_integrityasserted per section — all 8 correct: the 4 clean onesheading-plus-"Nothing found." with no paragraph, the 4 with findings unchanged,
and 4 cards rendered rather than 8, none reading zero.
113 tests pass. No new lint messages — the
C0302ondis_plots.pywasalready present on main at 1185/1000; these 46 lines moved the number, not the
verdict.
🤖 Generated with Claude Code