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

3.17.1 broke something #595

Closed
iBobik opened this issue Nov 23, 2020 · 7 comments
Closed

3.17.1 broke something #595

iBobik opened this issue Nov 23, 2020 · 7 comments

Comments

@iBobik
Copy link
Contributor

iBobik commented Nov 23, 2020

When html proofer was updates from 3.17.0 to 3.17.1 today in my CI tests started failing on internal linking (, , …). External links are checked correctly.

Executing it like this:

htmlproofer \
        --empty-alt-ignore \
        --url-ignore "/www.facebook.com/" \
        --url-swap "https?\:\/\/(www\.example\.com):" \
        dist

in Docker image klakegg/html-proofer

@gjtorikian
Copy link
Owner

Can you show me the some of the source files? What the internal link looks like, or the directory structure?

3.17.1 did change how internal links are checked (cf #587) but the test suite passed, so it's possible some other behavior was not being tested.

@tisba
Copy link
Contributor

tisba commented Nov 23, 2020

We're running into the same problem with 3.17.1.

We execute HTML proofer via Ruby like this:

  HTMLProofer.check_directory("build/", {
    url_ignore: url_ignore,
    trace: true,
    typhoeus: {
      headers: {
        "Accept-Encoding" => "gzip, deflate",
        "User-Agent" => "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/52.0.2743.82 Safari/537.36"
      }
    },
    cache: {
      timeframe: "2w",
      storage_dir: ENV["HTML_PROOFER_CACHE_DIR"]
    }
  }).run

Same observable problem: Internal links are reported as broken, external ones appear okay.

To check out our directory structure, it's a 1:1 copy from our website: https://stormforger.com

@gjtorikian
Copy link
Owner

@tisba Same question: can you please cat or otherwise show what the HTML of a broken link on a page looks like, followed by the directory structure? I'm looking to set up a test file a la https://github.com/gjtorikian/html-proofer/blob/main/spec/html-proofer/fixtures/links/broken_internal_link.html

@gjtorikian
Copy link
Owner

Ok. I was able to recreate the problem. Working on a fix.

@gjtorikian
Copy link
Owner

#597 should sort this; waiting for CI and will release 3.17.2 right after.

bvhme pushed a commit to publiccodenet/about that referenced this issue Nov 23, 2020
Version 3.17.1 broke internal links.
This is a temporary fix until that is fixed.
gjtorikian/html-proofer#595
@gjtorikian
Copy link
Owner

If I could get external confirmation that this fixed this issue, please let me know!

PS If you or your company are finding this tool useful, please consider sponsoring it. ✌️

@tisba
Copy link
Contributor

tisba commented Nov 24, 2020

I can confirm, 3.17.2 has resolved the issue 👍

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

3 participants