-
Notifications
You must be signed in to change notification settings - Fork 65
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
Validator runtime error #40
Comments
Hi @JoelBender The Honestly I'm surprised this is the first time I've come across this issue. And I'm surprised there isn't an example of this in the Standard SHACL Test-Suite. We'll have to decide what to do about it, and it may be fixed in a future pySHACL release. |
Thank you. I suspect that they didn't want to include tests that would break implementations in an effort to encourage adoption, maybe this will turn out to be an O(n ** n) problem...heh! In the mean time, I'll remove the |
Fixed badly-formatted dates in the changelog Added ability for pySHACL to track and monitor its evaluation path during validation - This allows for the validator to detect two different scenarios: - A recursive shape has triggered an infinitely-recursive validation, back out - Evaluation Path too deep (error generated, prevents python recursion depth errors) Added a test for Issue #40
Hi @JoelBender I have added three new features:
I've released a new version (0.11.4), I've verified it now works with your example files above. Note: It does spit out some pretty verbose warnings when it encounters a recursion loop, and it appears to find the same loop multiple times in different ways during execution. However the validation result it returns is correct, despite the warnings. |
A final note, |
@JoelBender something else I was thinking... Did you have a tool generate the 03-Network.ttl SHACL Shape file or did you write it by hand? I ask that, because I realized why I've never seen this issue come up before. Normally you wouldn't use the (aside, the use of the term "Node" both as a type of constraint in SHACL, and as a class type in your Network topology ontology makes this more confusing, but bare with me). All of the
with simple class-type checks, like this:
This makes the validation simpler, and removes the Shape Recursion. However you lose the ability to put anonymous blank nodes on Another observation, with patterns like this:
You don't need |
Yep, written by hand until the bugs are worked out, then I take the pattern and auto-generate lots of them, usually from another schema "language". I started including The use of |
Thats fair, keeping the explicit The reason you need to use both When you expand your data graph using "rdfs" or "owlrl" inferencing, the reasoner will ignore the shacl graph passed in as In your case, the SHACL shapes file and the OWL/RDFS relationships ontology file are the same file, thats why you need to pass it to both
I don't think I follow what you mean there. There is no reasoner ever applied to the SHACL Shapes Graph during any pyshacl run. |
closing as resolved |
Validator says there is a runtime error, no additional details turning on debug:
Info:
Turtle files attached as text files.
03-Network.ttl.txt
sample-network.ttl.txt
The text was updated successfully, but these errors were encountered: