helpdesk-validator icon indicating copy to clipboard operation
helpdesk-validator copied to clipboard

GetCapabilities is valid but the Inspire Validator says its invalid

Open Jonazabal opened this issue 4 years ago • 4 comments

I am trying to make an Inspire compatible WMS accessible from the Inspire Geoportal, currently it is not. The test result I get when using the Inspire validator against the GetCapabilities XML contains many errors including that the XML is invalid.

When I validate the xml myself against the schema as is It is also invalid, but if I change the relative path to common.xsd in https://inspire.ec.europa.eu/schemas/inspire_vs/1.0/inspire_vs.xsd to its URL: https://inspire.ec.europa.eu/schemas/common/1.0/common.xsd then the xml validates. So the xml is valid against the schema.

The GetCapabilities I am validating: https://geodata.socialstyrelsen.se/cgi/mapserv.exe?map=/ms4w/maps/sos-ska-wms.map&service=wms&request=GetCapabilities

Jonazabal avatar Mar 23 '22 08:03 Jonazabal

Dear @Jonazabal, reported issue is related to the INSPIRE Validator, therefore I am moving it to the Validator Helpdesk issue tracker.

sMorrone avatar Mar 23 '22 15:03 sMorrone

Dear @Jonazabal,

I tried to validate your GetCapabilities document, with oXygen, using the schemas declared in the schemaLocation attribute and it validates. What tool did you use?

Regarding the error in the validator related to the schema (see screenshot below), it seems that the additional schema declared in the schemaLocation attribute (https://geodata.socialstyrelsen.se/cgi/mapserv.exe?MAP=/ms4w/maps/sos-ska-wms.map&language=swe&service=WMS&version=1.3.0&request=GetSchemaExtension) responds in HTML format.

image

On the contrary, trying to remove the "amp;" characters (https://geodata.socialstyrelsen.se/cgi/mapserv.exe?MAP=/ms4w/maps/sos-ska-wms.map&language=swe&service=WMS&version=1.3.0&request=GetSchemaExtension) it responds in XML format.

This could be the source of the error message, are you able to do this change in the URL above mentioned?

fabiovinci avatar Mar 29 '22 17:03 fabiovinci

Ok, we used our own tool for validating and also som online validator but ok, then the XML is valid.

I found an error in the mapfile's wms_onlineresource value where we had written & instead of ampersand but we still get the errors in the INSPIRE Validator with this fixed. Here is a link using another mapfile that does not have that error: https://geodata.socialstyrelsen.se/cgi/mapserv.exe?map=/ms4w/maps/sos-dod-wms.map&service=wms&request=GetCapabilities

The url added to schemaLocations is added by MapServer so I cannot easily change that.

Jonazabal avatar Apr 07 '22 10:04 Jonazabal

Dear @Jonazabal,

we will investigate why the validator is not able to use one of the schemas (https://geodata.socialstyrelsen.se/cgi/mapserv.exe?MAP=/ms4w/maps/sos-dod-wms.map&language=swe&service=WMS&version=1.3.0&request=GetSchemaExtension) declared in the schemaLocation attribute to validate the service.

fabiovinci avatar Feb 14 '23 17:02 fabiovinci