Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Save linkcheck cache always #2030

Merged
merged 2 commits into from
Jan 9, 2025
Merged

Save linkcheck cache always #2030

merged 2 commits into from
Jan 9, 2025

Conversation

marxin
Copy link
Contributor

@marxin marxin commented Jul 28, 2024

This PR always stores the linkcheck cache when being run as part of the scheduled CI job. Note the normal PRs ignore the cache and check only the modified files. I also extended the cache expiration time so that the Nighly job can face the congressional limit from Github.com ("Server returned 429 Too Many Requests").

Hopefully, it's a viable solution.
@camelid

@marxin marxin marked this pull request as draft July 28, 2024 19:35
@jieyouxu jieyouxu added the S-waiting-on-review Status: this PR is waiting for a reviewer to verify its content label Oct 13, 2024
@jieyouxu jieyouxu added C-CI Category: CI for this repo A-linkcheck Area: linkcheck WG-rustc-dev-guide Working group: rustc-dev-guide labels Nov 4, 2024
@marxin marxin force-pushed the ci-cache branch 2 times, most recently from d97f06e to ca98813 Compare December 29, 2024 21:21
@marxin marxin marked this pull request as ready for review December 29, 2024 21:47
@Kobzol
Copy link
Contributor

Kobzol commented Jan 5, 2025

Sorry, due to me messing up a git operation, we sadly had to force-push the whole commit history of rustc-dev-guide :( If you'd like to update this pull request, you will have to rebase it in a special way onto the new commit history (the new master):

git fetch origin --all
git checkout <pr-branch>
git rebase --onto origin/master origin/master-old
git push --force-with-lease

More context can be found here.

Copy link
Member

@camelid camelid left a comment

Choose a reason for hiding this comment

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

I'm a little confused about what this change is accomplishing. Wouldn't making the cron job run every other day accomplish exactly the same thing?

@camelid
Copy link
Member

camelid commented Jan 6, 2025

I'm a little confused about what this change is accomplishing. Wouldn't making the cron job run every other day accomplish exactly the same thing?

Never mind, I just realized that the difference is that the cache will allow us to check new links without rechecking old links. Not sure why I didn't think of that 😅

@marxin
Copy link
Contributor Author

marxin commented Jan 8, 2025

Not sure why I didn't think of that 😅

Yeah, the main goal of the cache expiration is to at least partially reuse some of the GH links from the cache as one can't check all of them unless the "Server returned 429 Too Many Requests" message is hit.

@marxin marxin requested a review from camelid January 8, 2025 16:10
Copy link
Member

@camelid camelid left a comment

Choose a reason for hiding this comment

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

Thanks for doing this!

@camelid camelid merged commit 610e80b into rust-lang:master Jan 9, 2025
1 check passed
@marxin
Copy link
Contributor Author

marxin commented Jan 10, 2025

Thanks for the fix and the CI fix you landed just after my change!

@marxin marxin deleted the ci-cache branch January 10, 2025 06:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-linkcheck Area: linkcheck C-CI Category: CI for this repo S-waiting-on-review Status: this PR is waiting for a reviewer to verify its content WG-rustc-dev-guide Working group: rustc-dev-guide
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants