-
Notifications
You must be signed in to change notification settings - Fork 2k
ci: fix markdown-link-check #2296
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
Conversation
|
This PR addresses |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
|
Responding in part to comments in PR #2297: The justification for excluding the following domains is found by examining recent failing GitHub workflow logs for https://github.com/nodejs/docker-node/actions/workflows/markdown-link-check.yml: Note that the failing results vary according to the response from the remote domains, so multiple workflow logs need to be checked: https://github.com/nodejs/docker-node/actions/runs/18569189662 shows: [✖] http://nodejs.org → Status: 403 https://github.com/nodejs/docker-node/actions/runs/18611871299 shows: [✖] https://www.npmjs.com/ → Status: 403 For consistency, http://nodejs.org in the README document is updated to use the Other use of http could also be migrated, however I suggest to implement this in a separate PR, since it is not related to resolving 403 errors. Similarly, the suggestion in #2297 to migrate from the npm package markdown-link-check to the GitHub Action tcort/github-action-markdown-link-check is not necessary to solve 403 errors. The action appears to be hardly used and does not track the npm package versions closely. Any migration should be a separate more detailed discussion. If one of the maintainers would like to enable the workflows awaiting approval, I would expect them to pass. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
Description
In .github/workflows/markdown-link-check.yml
In markdown_link_check_config.json
ignorePatternsforhttpHeadersforMotivation and Context
The workflow .github/workflows/markdown-link-check.yml is sporadically failing with HTTP 403 Forbidden errors for:
See workflow logs
The
httpHeadersconfig section is no longer needed. Link checking to https://docs.github.com works without it.See also the community post https://github.com/orgs/community/discussions/174098 for background on https://www.npmjs.com/ heightened security.
Testing Details
On Ubuntu
24.04.3LTS, with Node.js22.20.0LTSNo dead links should be reported.
Also tested in GitHub Actions https://github.com/MikeMcC399/docker-node/actions/workflows/markdown-link-check.yml
Example Output(if appropriate)
Types of changes
Checklist