Troubleshooting external link failures #3443
Closed
MikeMcC399
started this conversation in
Show and tell
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
It is not unusual for link checking to fail on external links. Troubleshooting should try to identify if this is a soft error, which recovers on its own (perhaps due to activities on a third-party server being tested or because the server was rate-limiting access), or if it is a hard error which does not disappear after re-trying or waiting a day or two.
Examine the logs and find which link is failing.
When the test is run locally with
npm run test:links
, logging information is output to the terminal window which started the test. In addition, if the tested link responds with an HTTP error code, there will be a corresponding entry in the filecypress/logs/broken_links_result.txt
. The GitHub workflow test-check_links.yml saves files from the logs directory as an artifact in the action log if there is a failure. The corresponding zip file can be downloaded from GitHub and examined.If it is determined that the server cannot be tested reliably with automatic checking, it can be removed from the checks. The
hostname
, which in some cases can be found in thebroken_links_result.txt
log file, can be added to the listnoCheckHosts
in cypress/e2e/hybrid/check_links.cy.js to avoid testing this site.Beta Was this translation helpful? Give feedback.
All reactions