markdown-link-check icon indicating copy to clipboard operation
markdown-link-check copied to clipboard

Check failure with German characters in heading links

Open MikeMcC399 opened this issue 3 years ago • 4 comments

markdown-link-check version: 3.10.1 and 3.10.2

Problem description

Links to markdown document headings which contain German characters Umlaut and Eszett (äÄöÖüÜß) fail in the current markdown-link-check version 3.10.2 with a message similar to

ERROR: 1 dead links found!
  [✖] #%C3%BCbersicht → Status: 404

This is a regression from earlier versions. In markdown-link-check version 3.10.0 the link checks with German characters pass.

Steps to reproduce

Create document test.md with the following contents:

- [Übersicht](#übersicht)

# Übersicht

(The table of contents was produced using Visual Studio Code extension Markdown All in One and the command "Create Table of Contents".)

Execute npx markdown-link-check ./test.md

which fails showing

FILE: ./test.md
  [✖] #%C3%BCbersicht

  1 links checked.

  ERROR: 1 dead links found!
  [✖] #%C3%BCbersicht → Status: 404

Comparison to 3.10.0

$ npx markdown-link-check ./test.md

FILE: ./test.md
  [✓] #übersicht

  1 links checked.

MikeMcC399 avatar Jun 09 '22 06:06 MikeMcC399

If you need a working version you can use autoantwort-markdown-link-check as a temporary workaround (Original version with applied fixes).

autoantwort avatar Jul 04 '22 11:07 autoantwort

@autoantwort

If you need a working version you can use autoantwort-markdown-link-check as a temporary workaround (Original version with applied fixes).

  • Many thanks for the information. Currently I have pinned to using "markdown-link-check": "~3.8.7" due also to the regression https://github.com/tcort/markdown-link-check/issues/195. Did you by any chance also solve this issue in autoantwort-markdown-link-check?

MikeMcC399 avatar Jul 04 '22 12:07 MikeMcC399

No I don't think so. So it worked before https://github.com/tcort/markdown-link-check/commit/65221868bb1101bf211f9791037f304eacf908a2 ?

autoantwort avatar Jul 04 '22 13:07 autoantwort

@autoantwort

[email protected] passes checking the test file I provided in this issue 👍🏻

$ npx autoantwort-markdown-link-check ./test.md

FILE: ./test.md
  [✓] #übersicht

  1 links checked.

It does however fail checking a markdown file with an anchor embedded in HTML (see open issue #195):

[HTML list item](#html-list-item)

- <a name=html-list-item>HTML list item</a>
$ npx autoantwort-markdown-link-check ./anchor-in-html-test.md

FILE: ./anchor-in-html-test.md
  [✖] #html-list-item

  1 links checked.

  ERROR: 1 dead links found!
  [✖] #html-list-item → Status: 404

so I will stay with "markdown-link-check": "~3.8.7" for the time-being.

MikeMcC399 avatar Jul 04 '22 14:07 MikeMcC399

I can no longer reproduce the issue "Check failure with German characters in heading links" so I assume that it was caused (and fixed) by one of the dependencies.

[email protected]

$ npx markdown-link-check ./test.md

FILE: ./test.md
  [✓] #%C3%BCbersicht

  1 links checked.

MikeMcC399 avatar Dec 08 '22 19:12 MikeMcC399