Skip to content

[WIP] an actions cache cleanup workflow that runs when PRs close#5023

Closed
christianvogt wants to merge 2 commits intoopendatahub-io:mainfrom
christianvogt:clean-actions-cache
Closed

[WIP] an actions cache cleanup workflow that runs when PRs close#5023
christianvogt wants to merge 2 commits intoopendatahub-io:mainfrom
christianvogt:clean-actions-cache

Conversation

@christianvogt
Copy link
Collaborator

@christianvogt christianvogt commented Sep 26, 2025

Description

How Has This Been Tested?

Test Impact

Request review criteria:

Self checklist (all need to be checked):

  • The developer has manually tested the changes and verified that the changes work
  • Testing instructions have been added in the PR body (for PRs involving changes that are not immediately obvious).
  • The developer has added tests or explained why testing cannot be added (unit or cypress tests for related changes)
  • The code follows our Best Practices (React coding standards, PatternFly usage, performance considerations)

If you have UI changes:

  • Included any necessary screenshots or gifs if it was a UI change.
  • Included tags to the UX team if it was a UI/UX change.

After the PR is posted & before it merges:

  • The developer has tested their solution on a cluster by using the image produced by the PR to main

Summary by CodeRabbit

  • Chores
    • Added an automated workflow to clean up pull request caches when PRs are closed, reclaiming storage and reducing CI clutter.
  • Tests
    • Improved CI reliability and speed by unifying cache keys, broadening Turbo cache paths, and running setup/install steps unconditionally for consistent builds.

@openshift-ci openshift-ci bot added the do-not-merge/work-in-progress This PR is in WIP state label Sep 26, 2025
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Sep 26, 2025

Caution

Review failed

The pull request is closed.

📝 Walkthrough

Walkthrough

Added a new GitHub Actions workflow (.github/workflows/pr-cache-cleanup.yml) that runs on pull_request closed, uses the gh CLI to list PR-specific cache keys and delete them, and sets GH_TOKEN, GH_REPO, and a BRANCH env derived from the PR number; deletions continue on error and progress is logged. Updated .github/workflows/test.yml to remove lookup-only: true, run Node setup and dependency install unconditionally, switch cache keys to use needs.Setup.outputs.modules-cache-key instead of hashFiles-based keys, and normalize Turbo cache paths from github.workspace/.turbo to a glob **/.turbo across restore/save steps.

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~45 minutes

Pre-merge checks

❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Description Check ⚠️ Warning The pull request description includes the template structure but has no actual content in the Description, How Has This Been Tested, or Test Impact sections and the checklist items remain unchecked, so it does not fulfill the required template requirements. Please fill in the Description, How Has This Been Tested, and Test Impact sections with detailed explanations of the changes, your testing procedures, and their effects. Reference any related issue tickets if relevant. Finally, mark the checklist items to confirm testing and adherence to best practices before merging.
✅ Passed checks (2 passed)
Check name Status Explanation
Title Check ✅ Passed The title clearly summarizes the core change of adding a GitHub Actions cache cleanup workflow that triggers when pull requests are closed, which aligns with the main purpose of the changeset.
Docstring Coverage ✅ Passed No functions found in the changes. Docstring coverage check skipped.

📜 Recent review details

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 9db03c1 and 30a8324.

📒 Files selected for processing (2)
  • .github/workflows/pr-cache-cleanup.yml (1 hunks)
  • .github/workflows/test.yml (3 hunks)

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Sep 26, 2025

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign lucferbux for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

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

Labels

do-not-merge/work-in-progress This PR is in WIP state

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant