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

violation triggered as observations are omitted #168

Open
Rdataflow opened this issue Apr 15, 2024 · 2 comments
Open

violation triggered as observations are omitted #168

Rdataflow opened this issue Apr 15, 2024 · 2 comments

Comments

@Rdataflow
Copy link
Contributor

Rdataflow commented Apr 15, 2024

context
fetch-metadata omits the observations (intentially) but unfortunately this leads to a violation down the line applying check-metadata. the fetch & check pipe is expected to behave consistently.

message
Violation of NodeConstraintComponent: "cube:Cube needs an observationSet" with path https://cube.link/observationSet at focus node https://environment.ld.admin.ch/foen/besch_holz_inst_einheit_weniger4/20 (source: _:b88_b710)
Violation of MinCountConstraintComponent: "cube:Cube needs at least one observation" with path https://cube.link/observation at focus node https://environment.ld.admin.ch/foen/besch_holz_inst_einheit_weniger4/20/observation/ (source: _:b88_b712)

steps to reproduce

npx barnard59 cube fetch-metadata \
  --cube https://environment.ld.admin.ch/foen/besch_holz_inst_einheit_weniger4/20 \
  --endpoint https://int.lindas.admin.ch/query \
| npx barnard59 cube check-metadata \
  --profile https://cube.link/latest/shape/profile-visualize \
| npx barnard59 shacl report-summary

cc @giacomociti

@giacomociti
Copy link
Contributor

this is not a surprise, see also #146. Besides turning the violation into a warning (which is my preferred option, simple and effective), other options to address the issue are:

  • removing the constraint
  • retrieving the observation set and a single observation in fetch-metadata
  • deactivating the shape when running check-metadata

@tpluscode
Copy link
Contributor

👍 for making this a warning and also fetching a single observation with fetch-metadata

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants