Skip to content

fix(penpal): propagate git log errors and show retry in timeline - #537

Merged
matt2e merged 2 commits into
mainfrom
empty-projects-without-wifi
Mar 30, 2026
Merged

fix(penpal): propagate git log errors and show retry in timeline#537
matt2e merged 2 commits into
mainfrom
empty-projects-without-wifi

Conversation

@matt2e

@matt2e matt2e commented Mar 30, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Propagate git log errors for remote branches instead of silently swallowing them, so the UI can surface meaningful feedback
  • Show an error state with a retry button in the timeline when commit loading fails
  • Add a load-error row type to TimelineRow and wire retry callbacks through BranchTimeline

Test plan

  • Simulate a git log failure (e.g. disconnect network for a remote branch) and verify the error row appears in the timeline
  • Click the retry button and verify it re-attempts loading
  • Verify normal timeline loading still works without regressions

🤖 Generated with Claude Code

matt2e and others added 2 commits March 30, 2026 10:14
…ding fails

When loading commits fails (network error, git command failure, etc.),
display a load-error row at the bottom of the timeline with a Retry
button. For the initial-load case where no cached data exists, add a
retry button next to the error message. The standalone revalidation-error
div is removed since errors now render inside the timeline itself.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…swallowing them

When fetching commits for a remote branch, build_branch_timeline() used
`if let Ok(output)` to silently ignore git log failures (e.g. network
errors when offline). This caused the frontend to receive an empty but
valid BranchTimeline, making the project appear empty with no error UI.

Replace the `if let Ok(output)` pattern with `.map_err(...)?` so that
git log failures are propagated as errors to the caller. The frontend's
existing error handling (added in the previous commit) will now correctly
display the error state with a retry button.

The merge-base call still uses graceful fallback since it's less critical
and has a reasonable default (the raw base branch ref).
@matt2e
matt2e requested review from baxen and wesbillman as code owners March 30, 2026 00:07
@matt2e
matt2e merged commit d43a6bf into main Mar 30, 2026
4 checks passed
@matt2e
matt2e deleted the empty-projects-without-wifi branch March 30, 2026 00:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant