merlimat opened a new pull request, #4910:
URL: https://github.com/apache/bookkeeper/pull/4910

   ## Problem
   
   The "Dead link checker" workflow 
(`.github/workflows/dead-link-checker.yaml`) fails on every PR or push that 
touches a `.md` file. The only dead link it reports is 
`https://help.ubuntu.com/community/Kerberos`. It does not block merging 
(`.asf.yaml` requires only "BookKeeper CI checks completed"), but it adds a red 
check to unrelated PRs and to dependabot branches.
   
   The URL went dead through a redirect chain:
   
   ```
   https://help.ubuntu.com/community/Kerberos
     -> 301 https://wiki.ubuntu.com/Kerberos
     -> 404
   ```
   
   ## Example
   
   `site3/website/docs/security/sasl.md`:
   
   ```md
   for `Kerberos` and a short guide on how to install and configure it 
([Ubuntu](https://help.ubuntu.com/community/Kerberos),
   ```
   
   ```
   $ markdown-link-check -c .dlc.json -q site3/website/docs/security/sasl.md
     ERROR: 1 dead links found
     [x] https://help.ubuntu.com/community/Kerberos -> Status: 404
   ```
   
   The same link is in 15 files: the current `sasl.md` and the copies under 
`site3/website/versioned_docs/version-*/security/`.
   
   ## Change
   
   Replace the link with the Ubuntu Server documentation page "Install a 
Kerberos server", which matches the sentence ("a short guide on how to install 
and configure it"):
   
   ```md
   
([Ubuntu](https://ubuntu.com/server/docs/how-to/kerberos/install-a-kerberos-server/),
   ```
   
   This is the final URL after 
`documentation.ubuntu.com/server/how-to/kerberos/install-a-kerberos-server/` 
redirects, so it returns 200 with no redirect. Using the final URL means the 
link doesn't depend on that redirect. No `.dlc.json` ignore entry was needed. 
Only the URL changes (15 lines).
   
   ## Testing
   
   - `curl -s -o /dev/null -w "%{http_code} redirects=%{num_redirects}"` on the 
new URL: `200 redirects=0`.
   - `npx [email protected] -c .dlc.json -q <file>` (same tool and 
version as CI) exits 0 on all 15 changed files.
   - Negative control: the same command on a file with the old URL exits 1 with 
`Status: 404`.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to