Skip to content

Unrecognised escape sequence (\/) #663

@wolf99

Description

@wolf99

I am trying to add a .lycheeignore file that will ignore https://www.godaddy.com/. (Because it returns infinite HTTP 302s as it tries to redirect to a localized page).

I'd like to be able to ignore even if the trailing sforward slash is present or not.
So I construct the following regex:

godaddy\.com(\/)?$

git-ecosystem/git-credential-manager@e848ba8

However, lychee appears to barf on this regex:

+ eval lychee --format markdown --output /tmp/lychee/out.md --user-agent '"Mozilla/5.0' '(Windows' NT '10.0;' 'Win64;' 'x64)' AppleWebKit/[53](https://github.com/GitCredentialManager/git-credential-manager/runs/7055448925?check_suite_focus=true#step:3:56)7.36 '(KHTML,' like 'Gecko)' Chrome/100.0.4896.75 'Safari/537.36"' --no-progress .
++ lychee --format markdown --output /tmp/lychee/out.md --user-agent 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/100.0.4896.75 Safari/537.36' --no-progress .
Error: regex parse error:
    godaddy\.com(\/)?$
                 ^^
error: unrecognized escape sequence
+ exit_code=1

I've stared at this for about 30 mins on regex101.com, but I cannot see how this is wrong regex.

See: https://regex101.com/r/P1B4wT/1

image

I tried with a non-capturing group also, but no change: git-ecosystem/git-credential-manager@bc76c6e

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions