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

Move most broken link checking to a daily job #4428

Merged
merged 3 commits into from Apr 9, 2024
Merged

Conversation

mguaypaq
Copy link
Member

@mguaypaq mguaypaq commented Apr 9, 2024

Fixes #4426.

I still kept a limited form of the link checker for PRs. It should only check added/modified lines, so that should catch typos in new/changed links. The daily job should catch websites that stop working.

For the daily run, I picked a scheduled time that's an hour before all the other tests (either 5am or 6am Montreal time, depending on daylight savings), to avoid resource bottlenecks.

It's a little too flaky to run on every PR, and besides the main
thing it's supposed to catch is when an external website changes,
so a daily task is sufficient.
This should catch broken links that are specifically touched by a PR,
which is usually no links at all, so it shouldn't be very flaky.
@mguaypaq mguaypaq added the CI category: TravisCI, GitHub Actions, etc. label Apr 9, 2024
@mguaypaq mguaypaq added this to the 6.3 milestone Apr 9, 2024
Copy link
Member

@joshuacwnewton joshuacwnewton left a comment

Choose a reason for hiding this comment

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

LGTM! Thank you for going beyond and adding a modified check to the PRs. :)

.github/workflows/check-broken-links.yml Outdated Show resolved Hide resolved
.github/workflows/check-code-quality.yml Show resolved Hide resolved
Since it's a daily job, there's no need to rush.

Co-authored-by: Joshua Newton <joshuacwnewton@gmail.com>
@mguaypaq mguaypaq merged commit f3e79f8 into master Apr 9, 2024
20 checks passed
@mguaypaq mguaypaq deleted the mgp/cron-links branch April 9, 2024 19:53
@mguaypaq mguaypaq mentioned this pull request Apr 9, 2024
mguaypaq added a commit that referenced this pull request Apr 9, 2024
Since `grep` no longer receives filenames, it no longer puts
`$FILENAME:` at the start of each line. But `check-url.sh` _does_ expect
a semicolon before the url to check. So we need to insert it, rather
than changing the colon after `https` into a semicolon.

Follow-up for #4428.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CI category: TravisCI, GitHub Actions, etc.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Only enable broken link checker on master, and not PRs
2 participants