ucoProject / UCO

This repository is for development of the Unified Cyber Ontology.
Apache License 2.0
76 stars 34 forks source link

SHACL property shapes for action:actionStatus on action:ActionLifecycle are incorrect #442

Closed sbarnum closed 2 years ago

sbarnum commented 2 years ago

Bug description

The current SHACL property shape for action:actionStatus on action:ActionLifecycle is

[
    sh:datatype vocabulary:ActionStatusTypeVocab ;
    sh:maxCount "0"^^xsd:integer ;
    sh:nodeKind sh:Literal ;
    sh:path action:actionStatus ;
]

This is the old style. It should be the following like it is on action:Action

[
    sh:datatype vocabulary:ActionStatusTypeVocab ;
    sh:message "Value is outside the default vocabulary ActionStatusTypeVocab." ;
    sh:path action:actionStatus ;
    sh:severity sh:Info ;
] ,
[
    sh:maxCount "1"^^xsd:integer ;
    sh:nodeKind sh:Literal ;
    sh:or (
        [
            sh:datatype vocabulary:ActionStatusTypeVocab ;
        ]
        [
            sh:datatype xsd:string ;
        ]
    ) ;
    sh:path action:actionStatus ;
] ,
[
    sh:message "Value is not member of the vocabulary ActionStatusTypeVocab." ;
    sh:or (
        [
            sh:datatype vocabulary:ActionStatusTypeVocab ;
            sh:in vocabulary:ActionStatusTypeVocab-members ;
        ]
        [
            sh:datatype xsd:string ;
        ]
    ) ;
    sh:path action:actionStatus ;
]

Steps to reproduce

Any use of action:actionStatus on action:ActionLifecyle that is not a valid string member of ActionStatusTypeVocab should demonstrate the bug.

Coordination