Skip to content
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

[BUG] Anchors are not checked after following redirects #132

Open
stefano-ottolenghi opened this issue Feb 21, 2024 · 1 comment
Open

[BUG] Anchors are not checked after following redirects #132

stefano-ottolenghi opened this issue Feb 21, 2024 · 1 comment

Comments

@stefano-ottolenghi
Copy link

Hi! I would expect that, when running with --check-anchors --show-redirects, linkcheck would emit a warning if a page has a redirect and the destination lacks the anchor (ex. a#b redirects to c, but b is not an anchor on c).

That doesn't seem to be the case.

Do we agree that this is a bug? I've seen you're swamped @filiph , and I'm happy to attempt to fix this given some starting pointers :)

@filiph
Copy link
Owner

filiph commented Feb 22, 2024

Hi @stefano-ottolenghi, thanks for the issue and yes, I'd be happy for a pull request.

I'm guessing you want to start somewhere here: https://github.com/filiph/linkcheck/blob/master/lib/src/parsers/html.dart#L100-L106

If I were you, I'd add a new test case first: https://github.com/filiph/linkcheck/tree/master/test, and try to fix it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants