Skip to content

Commit c0c3d68

Browse files
sfc-gh-bniscoclaude
andcommitted
docs(interrupt-rotation): correct parallel-fragment docstrings
The two action-item fragment docstrings claimed the snapshot was "grouped into a single parallel fragment so it is fetched once", but the snapshot is actually read from two separate fragments. Clarify that the fetch-once guarantee comes from st.cache_data memoization, and document why the split into two fragments exists: it preserves the original page order (issue tables at the top, PR tables at the bottom, independent-source sections in between) so a future reader does not collapse it and reorder the page. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
1 parent 4b96939 commit c0c3d68

1 file changed

Lines changed: 18 additions & 8 deletions

File tree

app/interrupt_rotation.py

Lines changed: 18 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -124,10 +124,14 @@ def render_ci_metrics(selected_since: date, selected_refresh_nonce: int) -> None
124124

125125
@st.fragment(parallel=True)
126126
def render_issue_action_items(selected_since: date, selected_refresh_nonce: int) -> None:
127-
"""Render the issue-focused action-item tables from the shared snapshot.
128-
129-
Grouped into a single parallel fragment so the (cached) issue/PR snapshot is
130-
fetched once and overlaps with the other parallel fragments during a full rerun.
127+
"""Render the issue-focused action-item tables (top of the Action Items list).
128+
129+
This is one of two parallel fragments that read the shared action-items
130+
snapshot; this one renders the issue tables and render_community_pr_action_items
131+
renders the PR tables lower on the page. build_interrupt_action_items is memoized
132+
by st.cache_data, so it is computed once and the sibling fragment's call is a
133+
cache hit rather than a second fetch. Running as a parallel fragment lets the
134+
snapshot fetch overlap with the other parallel fragments during a full rerun.
131135
"""
132136
with st.skeleton(height=600):
133137
action_items = build_interrupt_action_items(
@@ -575,10 +579,16 @@ def render_reported_bugs(selected_since: date, selected_refresh_nonce: int) -> N
575579

576580
@st.fragment(parallel=True)
577581
def render_community_pr_action_items(selected_since: date, selected_refresh_nonce: int) -> None:
578-
"""Render the community-PR action-item tables from the shared snapshot.
579-
580-
Grouped into a single parallel fragment so the (cached) issue/PR snapshot is
581-
fetched once and overlaps with the other parallel fragments during a full rerun.
582+
"""Render the community-PR action-item tables (bottom of the Action Items list).
583+
584+
This is one of two parallel fragments that read the shared action-items
585+
snapshot; render_issue_action_items renders the issue tables higher on the page
586+
and this one renders the PR tables. build_interrupt_action_items is memoized by
587+
st.cache_data, so it is computed once and this fragment's call is a cache hit
588+
rather than a second fetch. Splitting the tables across two fragments keeps the
589+
original page order (issue tables at the top, PR tables at the bottom, with the
590+
independent-source sections in between) while still overlapping the snapshot
591+
fetch with the other parallel fragments.
582592
"""
583593
with st.skeleton(height=400):
584594
action_items = build_interrupt_action_items(

0 commit comments

Comments
 (0)