Skip to content

feat: Add action summary to push view#1446

Open
andypols wants to merge 10 commits intofinos:mainfrom
qube-rt:display-git-push-actions
Open

feat: Add action summary to push view#1446
andypols wants to merge 10 commits intofinos:mainfrom
qube-rt:display-git-push-actions

Conversation

@andypols
Copy link
Contributor

@andypols andypols commented Mar 5, 2026

Summary

It can be hard to understand why a push was rejected. This PR adds a view of each step involved in a push, making it easier to identify failures. It also fixes #1387 and prevents the UI from crashing when a push fails before a diff is generated.

We use "steps" instead of actions in the UI, since “actions” was confusing for users.

Solution

  • Introduces a tabbed view for push data, including Commits, Diff, and Steps. This reduces scrolling and provides a foundation for future additions, such as an AI-generated change summary (future PR).
CleanShot 2026-03-06 at 08 38 11@2x
  • Adds dedicated components for each tab.
  • Extended CustomTabs to support an optional badge.
  • Calculates the total error count across steps and displays it as a badge to make failures more visible.
  • Sums the error count from the steps and displays an error count as a badge to highlight there are errors.
  • Adds a StepsTimeline component featuring an accordion layout, status chips, and log output to better surface errors, blocked steps, and successful execution.
CleanShot 2026-03-06 at 08 39 41@2x
  • Clicking on an accordion step the info about that action
CleanShot 2026-03-06 at 08 42 19@2x
  • Prevents large step payloads from being rendered.

@andypols andypols requested a review from a team as a code owner March 5, 2026 23:36
@netlify
Copy link

netlify bot commented Mar 5, 2026

Deploy Preview for endearing-brigadeiros-63f9d0 canceled.

Name Link
🔨 Latest commit 17dc7f2
🔍 Latest deploy log https://app.netlify.com/projects/endearing-brigadeiros-63f9d0/deploys/69b29607159ddd000885a8d4

@codecov
Copy link

codecov bot commented Mar 6, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 89.71%. Comparing base (90df884) to head (17dc7f2).
⚠️ Report is 70 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1446      +/-   ##
==========================================
- Coverage   90.01%   89.71%   -0.31%     
==========================================
  Files          67       68       +1     
  Lines        4769     4880     +111     
  Branches      885      888       +3     
==========================================
+ Hits         4293     4378      +85     
- Misses        458      484      +26     
  Partials       18       18              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Copy link

@re-vlad re-vlad left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lets couple of non-blocking suggestions

{
tabName: 'Steps',
tabIcon: TimelineIcon,
tabContent: <StepsTimeline steps={push.steps} />,
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we pass steps={push.steps ?? []} into StepsTimeline so the component never receives undefined

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also noticed that StepsTimeline already has an expandStepId prop that auto-expands a specific accordion, but it's never passed from PushDetails. If we calculate the first failing step, we can auto-expand it when the user opens the Steps tab:
const firstErrorStep = (push.steps ?? []).find((step) => step.error);

tabContent: <StepsTimeline steps={push.steps ?? []} expandStepId={firstErrorStep?.id} />

This way errors are immediately visible without the user having to manually click the failing step.

Copy link
Contributor Author

@andypols andypols Mar 11, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@fabiovincenzi auto-opening the steps with errors is a nice idea, but feels strange passing firstErrorStep in when StepsTimeline has all the information to do itself?

if (isError) throw new Error(message || 'Something went wrong ...');
if (!push) return <div>No push data found</div>;

const errorCount = push.steps.filter((step) => step.error).length;
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Small non-blocking suggestion: if push.steps is ever undefined (e.g. old API shape or malformed response), this throws. As for me, optional is more appropriate, something like this: const errorCount = push.steps?.filter((step) => step.error).length ?? 0

</TableRow>
</TableHead>
<TableBody>
{commitData.map((c) => (
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When commitData is empty, the table renders only headers with no body rows. Can you add an explicit empty state (e.g. a single row with colSpan and "No commits" or a short message)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Pushes in the 'error' category don't render in the admin UI unless a diff was produced

3 participants