Repository: lycheeverse/lychee

Issue #1457: bug: anchor/fragment detection doesn't appear to work
Created: 2024-06-24T19:11:52Z
When checking https://docs.boundaryml.com, muffet detects when an anchor doesn't exist
https://docs.boundaryml.com/docs/syntax/client/client
        400     https://mintlify.com?utm_campaign=poweredBy&utm_medium=docs&utm_source=docs.boundaryml.com
        403     https://platform.openai.com/docs/models
        431     https://twitter.com/boundaryml
        id #L20 not found       https://github.com/anthropics/anthropic-sdk-python/blob/fc90c357176b67cfe3a8152bbbf07df0f12ce27c/src/anthropic/types/completion_create_params.py#L20
        id #L28 not found       https://github.com/openai/openai-python/blob/9e6e1a284eeb2c20c05a03831e5566a4e9eaba50/src/openai/types/chat/completion_create_params.py#L28
        id #generate-a-chat-completion not found        https://github.com/ollama/ollama/blob/main/docs/api.md#generate-a-chat-completion

but lychee does not, even with fragment detection explicitly specified (presumably it's on by default):

boundary-website on  sam/new-language-pt1 via  v20.14.0 | [2] took 1s at 12:09:40
❯ lychee --include-fragments https://docs.boundaryml.com/docs/syntax/client/client
  64/64 ━━━━━━━━━━━━━━━━━━━━ Finished extracting links                                                                                                                            Issues found in 1 input. Find details below.

[https://docs.boundaryml.com/docs/syntax/client/client]:
✗ [403] https://platform.openai.com/docs/models | Failed: Network error: Forbidden
✗ [403] https://mintlify.s3-us-west-1.amazonaws.com/gloo/_generated/favicon/browserconfig.xml?v=3 | Failed: Network error: Forbidden

🔍 64 Total (in 0s) ✅ 60 OK 🚫 2 Errors 💤 2 Excluded

boundary-website on  sam/new-language-pt1 via  v20.14.0 | [2] took 833ms at 12:09:50
❯ lychee --include-fragments https://docs.boundaryml.com/docs/
  68/68 ━━━━━━━━━━━━━━━━━━━━ Finished extracting links                                                                                                                            Issues found in 1 input. Find details below.

[https://docs.boundaryml.com/docs/]:
✗ [403] https://mintlify.s3-us-west-1.amazonaws.com/gloo/_generated/favicon/browserconfig.xml?v=3 | Failed: Network error: Forbidden
✗ [404] https://github.com/BoundaryML/baml-examples/tree/main/fastapi-starter | Failed: Network error: Not Found

🔍 68 Total (in 1s) ✅ 64 OK 🚫 2 Errors 💤 2 Excluded
💡 There were issues with GitHub URLs. You could try setting a GitHub token and running lychee again.%

Duplicate issue #1591: Failures with #anchors: file not found
Created: 2024-12-18T16:10:59Z
I have a website with this in the HTML:
<h2 id="outcomes" class="heading"> <a href="#outcomes"> Outcomes </a> </h2>
Using lychee main (1780aa0, v0.18.0) or lychee v0.17.0, and calling it like this:
lychee --threads 1 --cache --config ./lychee.prod.toml --verbose --base "$(realpath ./dist)" ./dist

and a lychee.prod.toml containing:
cache = true
include_mail = true
max_cache_age = "1w"
max_redirects = 5

exclude = [
# a few unrelated entries...
]
I get this error:
[ERROR] file:///Users/grahamc/src/github.com/DeterminateSystems/website/dist/%23outcomes | Cannot find file

Closing comment (2024-12-18T16:23:26Z): Can you try 0.16.0? Might be a duplicate of #1457, #1577, #1574. I basically broke anchors/fragments. 😬