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

Annex III - Natural risk zones (NZ) - Dataset validation #1075

Closed
lukastemberga opened this issue May 3, 2024 · 2 comments
Closed

Annex III - Natural risk zones (NZ) - Dataset validation #1075

lukastemberga opened this issue May 3, 2024 · 2 comments
Labels
user-fixed Problem solved on user side

Comments

@lukastemberga
Copy link

Hi,

I'm trying to validate dataset for theme Natural risk zones (NZ) - Annex III. I'm able to pass all automatic tests except for:
Conformance class: GML application schemas, Natural Risk Zones -> Basic test -> nz-gml.a.1: Feature in dataset
link

The test returns an error stating:

The XML documents representing the spatial data set do not contain a feature of any of the spatial object types in the 'Natural Risk Zones' application schemas. Therefore, the spatial data set cannot conform to this conformance class. If you have expected to find spatial objects from the application schema in the data set, please consult the statistics information to see the spatial object types that have been found.

I'm pretty sure my GML file contains proper feature of type nz-core:RiskZone. Also, looking at the statistics there are 20 features present and all are of RiskZone type.

Looking at the test condition for the test:

let $featuresFromAppSchema := $features[descendant-or-self::nz-core:ExposedElement 
| descendant-or-self::nz-core:HazardArea 
| descendant-or-self::nz-core:ObservedEvent 
| descendant-or-self::nz-core:RiskZone    /* This shall make it true ? */
| descendant-or-self::nz-core:ExposedElementCoverage 
| descendant-or-self::nz-core:HazardCoverage 
| descendant-or-self::nz-core:ObservedEventCoverage 
| descendant-or-self::nz-core:RiskCoverage]
return
	(if ($featuresFromAppSchema) then 'PASSED' else 'FAILED',
	if (not($featuresFromAppSchema)) then local:addMessage('TR.noFeature', map { 'theme': 'Natural Risk Zones' }) else ())

To my understanding descendant-or-self::nz-core:RiskZone shall be tested positive against XML tag <nz-core:RiskZone gml:id="NZ_FloodRisk.5"> ...

Is there a problem with my dataset or is this an validator error?
I have tried comparing this dataset against other datasets (other themes) that do pass validation without problems and I can't seem to find some major difference.
Thanks for your help in advance!

Test dataset and validation result:
validation.zip

@fabiovinci
Copy link
Collaborator

Dear @lukastemberga,

this type of error occurs, now, for data themes that were updated to major version 5.0, such as NZ.
We are investigating why the error appears.

In the meantime, the error disappears if you update your dataset to the new version 5.

Please find in the screenshot below the changes I introduced in your test dataset:

image

In your case, the changes are related only to the namespaces since there are no attributes for which the datatype was changed (i.e. attributes for which the datatype changed from enumeration to codelist).

Attached are the modified dataset and the validation report: test_v5.zip

@fabiovinci fabiovinci added the user-to-fix Problem is present on user side label May 3, 2024
@lukastemberga
Copy link
Author

@fabiovinci thank you for your help, I have adjusted schema URLs to what you suggested. It all works fine now.

@fabiovinci fabiovinci added user-fixed Problem solved on user side and removed user-to-fix Problem is present on user side labels May 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
user-fixed Problem solved on user side
Projects
None yet
Development

No branches or pull requests

2 participants