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

Misplaced diagnostic for cvc-elt.3.1 #241

Closed
fbricon opened this issue Nov 29, 2018 · 1 comment
Closed

Misplaced diagnostic for cvc-elt.3.1 #241

fbricon opened this issue Nov 29, 2018 · 1 comment
Assignees
Labels
bug Something isn't working validation XSD
Milestone

Comments

@fbricon
Copy link
Contributor

fbricon commented Nov 29, 2018

Given this wrong schema:

<?xml version="1.0"?>
<xs:schema elementFormDefault="qualified" xmlns:xs="http://www.w3.org/2001/XMLSchema" 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
>
    <xs:complexType name="property" xsi:nil="true">
    </xs:complexType>
</xs:schema>

the closing bracket after xsi:nil="true" is underlined in red:

screen shot 2018-11-29 at 6 39 12 pm

See the diagnostic data:

{
	"resource": "/Users/fbricon/Downloads/sample-resources 5/foo.xsd",
	"owner": "_generated_diagnostic_collection_name_#0",
	"code": "cvc-elt.3.1",
	"severity": 8,
	"message": "cvc-elt.3.1: Attribute 'http://www.w3.org/2001/XMLSchema-instance,nil' must not appear on element 'xs:complexType', because the {nillable} property of 'xs:complexType' is false.",
	"source": "xml",
	"startLineNumber": 5,
	"startColumn": 52,
	"endLineNumber": 5,
	"endColumn": 52
}
@fbricon fbricon added bug Something isn't working validation XSD labels Nov 29, 2018
@angelozerr angelozerr added this to the v0.0.3 milestone Nov 30, 2018
@angelozerr angelozerr self-assigned this Nov 30, 2018
@angelozerr
Copy link
Contributor

Fixed with test too

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working validation XSD
Projects
None yet
Development

No branches or pull requests

2 participants