praveenvijayan / grunt-html-validation

W3C html validaton grunt plugin. Validate all files in a directory automatically.
MIT License
75 stars 39 forks source link

Validation service changed #76

Open lawlesscreation opened 9 years ago

lawlesscreation commented 9 years ago

Looks like the W3C are throwing a new warning out when using their service:

1=> "This interface to HTML5 document checking is deprecated. Use the Nu Html Checker at https://validator.w3.org/nu/ directly instead." Line no: undefined
No of errors: 1

Might be a good idea to update the plugin to use https://validator.w3.org/nu/

witrin commented 9 years ago

:+1:

danielmohacsi commented 9 years ago

:+1:

sideshowbarker commented 9 years ago

Looks like the W3C are throwing a new warning out when using their service:

1=> "This interface to HTML5 document checking is deprecated. Use the Nu Html Checker at https://validator.w3.org/nu/ directly instead." Line no: undefined

Yeah, I just pushed that warning to the checker's XML-format output facet a few hours ago.

Might be a good idea to update the plugin to use https://validator.w3.org/nu/

Yup. If there's any problem with the warning that's creating issues for users I could revert it temporarily. But it's there for a reason.

retan commented 9 years ago

It is a problem. It's driving me crazy for half a day. Getting errors (with a loud beep) for no particular reason every time I change a few lines is not helping productivity. Tumbs up for any, even temporary solution, ASAP pleas!!!

embpdaniel commented 9 years ago

This error is keeping my project from building. I tried changing the 'serverUrl' option to https://validator.w3.org/nu/ but then I get a network error. Am I supposed to use this url to remove the error, or is there something else I need to do? heeelp :/

lawlesscreation commented 9 years ago

It's not a long term solution, but you can add the error to relaxerrors:

relaxerror: [
            'This interface to HTML5 document checking is deprecated.'
        ]

Like I say, not a long term solution.

embpdaniel commented 9 years ago

@lawlesscreation Thank you, this will do the trick for now. It works :)

retan commented 9 years ago

@lawlesscreation Thank you.

witrin commented 9 years ago

I've switched to grunt-html. With this plugin there is no need to be online and it uses the new validator.

sideshowbarker commented 9 years ago

I've switched to grunt-html. With this plugin there is no need to be online and it uses the new validator.

Aha. Actually I had misread the name of the repo this issue tracker is for. I had thought this actually was the grunt-html repo, which I already knew used the standalone vnu.jar release of the checker. So I had been wondering why emitting the new warning message was causing problems for the grunt-html. Now I understand that this issue is in a tracker for different repo, grunt-html-validator.

So I think the solution here for everybody is to for everybody who wants HTML checker integration with grunt to just use the grunt-html tool, which as far as I can is a superior solution to grunt-html-validator in pretty much every way. For one thing, given that is repo hasn't an substantive updates in a year, and there are no comments here in this issue from the grunt-html-validator maintainer @praveenvijayan.

markusfalk commented 9 years ago

I tried the relaxerror option or using a different URL but in any combination I get a network error.

I suspect a timeout? large files? any idea?

validation: {
      options: {
        reportpath: false,
        reset: true,
        serverURL: 'https://validator.w3.org/nu/',
        relaxerror: [
          'This interface to HTML5 document checking is deprecated.'
        ]
      },
      files: {
        src: ["build/**/*.html", "!build/**/ajax-*"]
      }
    }