Closed StevenMaude closed 2 years ago
Status | Count |
---|---|
🔍 Total | 434 |
✅ Successful | 409 |
⏳ Timeouts | 0 |
🔀 Redirected | 0 |
👻 Excluded | 0 |
❓ Unknown | 0 |
🚫 Errors | 25 |
https://www.closer.ac.uk/wp-content/uploads/CLOSER-resource-Understanding-HES.pdf
.md
files. For example, the file:///github/workspace/opensafely-cli
failure. We could just make these .md
.https://fonts.gstatic.com
is a preconnect
link, but gives a 404 error if you visit it.https://github.com/opensafely/research-template/generate
bennett@phc.ox.ac.uk
. It could be some firewall restriction within GitHub's runner. Therefore the number of errors listed is lower than in the count.This has found some genuinely broken links as listed in #709.
I think this approach is useful. The limitation, as mentioned at the outset, is that a small percentage (about 3%) of links would need periodic manual review.
It might also be one to use for other sites we maintain.
Things to do if implementing:
--exclude-mail
--require-https
— this flags HTTP links that are available as HTTPS --include-verbatim
to check in pre
and code
blocks (default behaviour in 0.9.0; need to add this in a future release)~With an exclude file in my own fork, we're now at:
Status | Count |
---|---|
🔍 Total | 452 |
✅ Successful | 419 |
⏳ Timeouts | 0 |
🔀 Redirected | 0 |
👻 Excluded | 33 |
❓ Unknown | 0 |
🚫 Errors | 0 |
Looking around at other organisations using a "docs as code" approach, a link checker is a fairly standard piece of validation.
There may be other software around, but lychee looks like it could be a good contender. lychee's README also has a list of other competing software.
There may be occasionally private links that we have to skip over. These should be few in number.