This is an archived snapshot of W3C's public bugzilla bug tracker, decommissioned in April 2019. Please see the home page for more details.
Ville is tracking a bug in v0.8.4 of the validator whereby doctype override to any document type without System Identifier (HTML 2 and 3.2) fails with the following symptoms: 1) Warning (about undefined value being used IIRC) in server error log, 2) Incorrect doctype declaration inserted ("<!DOCTYPE html>") (show source), 3) Validator goes to HTML5 (!) mode and uses the HTML5 checker. This patch: http://www.w3.org/mid/E1L3mUf-0002d8-RA@lionel-hutz.w3.org seems to get rid of the symptoms, but there may be some underlying bug with doctype override and the changes made to doctype detection when we added HTML5 support. Worth an in-depth look at some point, before we can consider the case closed.
I think these changes are sufficient to consider the case closed: http://www.w3.org/mid/E1LJDde-0002hk-Kh%40lionel-hutz.w3.org http://www.w3.org/mid/E1LJDeq-0002kq-M1%40lionel-hutz.w3.org The first is a generic fix for doctype override construction (works if either or both or neither of pubid/sysid are not available), and the second removes a bogus public id for HTML5 (types are keyed by public id so _something_ must be there for all types, and empty string seems to me the most logical choice for HTML5). Actually I do not know how the HTML5 override could have worked properly without the latter patch (it inserted "<!DOCTYPE html PUBLIC "HTML5"> for me which to me seems exactly what was coded), but it did on validator.w3.org (inserted "<!DOCTYPE html>"). Maybe v.w.o wasn't using the types.conf that was in CVS but a version similarly altered as the 2nd patch above?
Spoke too soon it seems. There are now/still issues with doctypeless documents: http://qa-dev.w3.org/wmvs/HEAD/check?uri=http%3A%2F%2Fqa-dev.w3.org%2Fwmvs%2FHEAD%2Fdev%2Ftests%2Fxhtml1-missing-doctype-and-xmlns.html&charset=(detect+automatically)&doctype=Inline&group=0&user-agent=W3C_Validator%2F1.623 - Detected doctype: HTML5 - Warning displayed: "No DOCTYPE found! Checking with default HTML 4.01 Transitional Document Type." - Errors out: "no document type declaration; implying "<!DOCTYPE HTML SYSTEM>"." - The HTML5 interface is apparently not invoked This is otherwise the correct behavior as far as I can tell, but the doctype should not be detected to be HTML5.
Should be fixed (again) in CVS.
*** Bug 6448 has been marked as a duplicate of this bug. ***
(In reply to comment #4) > *** Bug 6448 has been marked as a duplicate of this bug. *** Additional note: This flaw also applies to ISO/IEC 15445:2000 ("ISO HTML") as well as HTML 2.0 and 3.2 (I checked them all; these are the only three document override settings this occurs for). As I see the bug still operative using v0.8.4, and a Target Milestone of 0.8.5 I assume that means that the fix should be operational when 0.8.5 becomes the current version of the validator?
Yes, and ISO-HTML is taken care of as well. You can use http://qa-dev.w3.org/wmvs/HEAD/ to test/verify the fix, but be aware that although efforts are made to keep it stable and running, it is a bleeding edge development instance which means it can have other issues not present in released versions.
*** Bug 6526 has been marked as a duplicate of this bug. ***