lbl-srg / BuildingsPy

Python modules for automating Modelica simulations and for running unit test for the Buildings library
81 stars 46 forks source link

HTML tidy does not find all errors #52

Open thorade opened 9 years ago

thorade commented 9 years ago

Not sure what can be done: HTML tidy does not find all errors.

To find more warnings and errors, you can use Dymola -> Export ->HTML together with Atom.io editor and linter package and htmlhint package

thorade commented 9 years ago

Here are just two examples from Annex60 that tidy did not find (and that can be fixed using search&replace):

Values should have double quotes (and Modelica wants the double quotes to be escaped)

<table border=\"1\" cellspacing=0 cellpadding=2
<table border=\"1\" cellspacing=\"0\" cellpadding=\"2\"

All tags need closing tags

<ul>
<li>the function is defined and monotone increasing for all <i>x</i>.
<li><i>dy/dx</i> is bounded and continuous everywhere (for <i>n &lt; 1</i>).
</ul>
<ul>
<li>the function is defined and monotone increasing for all <i>x</i>.</li>
<li><i>dy/dx</i> is bounded and continuous everywhere (for <i>n &lt; 1</i>).</li>
</ul>

Also, there are a lot of paragraphs that do not have closing tags. I have fixed these in BuildingSystems and will also fix in Annex60 next week.

thorade commented 9 years ago

Maybe it is possible to use HTMLHint additionally or alternatively? http://htmlhint.com/

Or, even more strict, the W3C validator: https://github.com/validator/validator http://validator.w3.org/

thorade commented 9 years ago

Looks like some people started to develop new versions of HTML tidy: http://www.html-tidy.org/ http://www.htacg.org/ https://github.com/htacg/tidy-html5

Especially see https://github.com/htacg/tidy-html5/issues/521

thorade commented 6 years ago

Tidy 5.6.0 has been released https://github.com/htacg/tidy-html5/releases That release contains the fix for https://github.com/htacg/tidy-html5/issues/521