gjtorikian / html-proofer

Test your rendered HTML files to make sure they're accurate.
MIT License
1.57k stars 199 forks source link

4.3.1 Ignoring options #748

Closed plaindocs closed 2 years ago

plaindocs commented 2 years ago

With 4.3.1 we're finding that options like--disable-external=true aren't working at all:

htmlproofer --ignore-files "/404/,/2013/,/2014/,/2015/,/2016/,/2017/,/videos/,/search\/index.html/" --allow-hash-href --enforce-https=false --ignore-missing-alt --disable-external=true docs/_build/html
Running 3 checks (Images, Links, Scripts) in ["docs/_build/html"] on *.html files...

Checking 2633 external links
Checking 4874 internal links

I've not dug in too deeply, but there is a little discussion here https://github.com/writethedocs/www/issues/1774

Reverting to 4.2 does fix things.

riccardoporreca commented 2 years ago

@plaindocs, @gjtorikian, this is another instance of the CLI args issues, see https://github.com/gjtorikian/html-proofer/issues/745#issuecomment-1201725978 for a similar issue and relevant pointers, but you ultimately have to make sure to specify =true/false for all boolean options.

In your specific case:

--allow-hash-href=true --enforce-https=false --ignore-missing-alt=true --disable-external=true 

should do the job

plaindocs commented 2 years ago

Thanks @riccardoporreca ! <3

And thanks @gjtorikian for continued work on htmlproofer! <3