Skip to content

Commit

Permalink
Merge pull request #79 from casework/use_case_utils_from_pypi
Browse files Browse the repository at this point in the history
Use case-utils via PyPI, updating main validation to CASE 0.7.0
  • Loading branch information
kchason authored Jun 23, 2022
2 parents 22ef363 + cbf3214 commit 7138163
Show file tree
Hide file tree
Showing 6 changed files with 4 additions and 64 deletions.
3 changes: 0 additions & 3 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
[submodule "dependencies/CASE-Utilities-Python"]
path = dependencies/CASE-Utilities-Python
url = https://github.com/casework/CASE-Utilities-Python
[submodule "dependencies/UCO-unstable"]
path = dependencies/UCO-unstable
url = https://github.com/ucoProject/UCO-Archive.git
Expand Down
13 changes: 2 additions & 11 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -32,11 +32,6 @@ all: \
# for someone developing with different submodule pointers.
.git_submodule_init.done.log: \
.gitmodules
# CASE-Utilities-Python
test -r dependencies/CASE-Utilities-Python/README.md \
|| (git submodule init dependencies/CASE-Utilities-Python && git submodule update dependencies/CASE-Utilities-Python)
test -r dependencies/CASE-Utilities-Python/README.md \
|| (echo "ERROR:Makefile:CASE-Utilities-Python submodule README.md file not found, even though CASE-Utilities-Python submodule initialized." >&2 ; exit 2)
# CASE-develop
test -r dependencies/CASE-develop/README.md \
|| (git submodule init dependencies/CASE-develop && git submodule update dependencies/CASE-develop)
Expand All @@ -58,9 +53,8 @@ all: \
test -r dependencies/UCO-unstable/README.md \
|| (echo "ERROR:Makefile:UCO-unstable submodule README.md file not found, even though UCO-unstable submodule initialized." >&2 ; exit 2)
# Retrieve rdf-toolkit.jar.
# TODO - After release of CASE 0.7.0 and UCO 0.9.0, rdf-toolkit.jar references should adjust to UCO-develop.
$(MAKE) \
--directory dependencies/CASE-unstable \
--directory dependencies/UCO-develop \
.lib.done.log
touch $@

Expand Down Expand Up @@ -101,10 +95,7 @@ all: \
wheel
source venv/bin/activate \
&& pip install \
dependencies/CASE-Utilities-Python
source venv/bin/activate \
&& pip install \
--requirement requirements.txt
--requirement requirements.txt
touch $@

check: \
Expand Down
1 change: 0 additions & 1 deletion dependencies/CASE-Utilities-Python
Submodule CASE-Utilities-Python deleted from 152166
48 changes: 0 additions & 48 deletions examples/illustrations/Oresteia/Oresteia_validation.ttl
Original file line number Diff line number Diff line change
Expand Up @@ -317,54 +317,6 @@
sh:path observable:accountType ;
] ;
sh:value "Phone"^^vocabulary1:AccountTypeVocab ;
] ,
[
a sh:ValidationResult ;
sh:focusNode [
a observable:EmailMessageFacet ;
observable:body "To me, too, grant this boon-dark death to deal unto Aegisthus, and to 'scape my doom." ;
observable:from <http://example.org/kb/electra-emailaccount-uuid> ;
observable:messageID "CAKBqNfyKo+ZXtkz6DUjWpvHy6O82jTbkNA@mail.gmail.com" ;
observable:receivedTime "2017-06-21T13:44:23.400000+00:00"^^xsd:dateTime ;
observable:sentTime "2017-06-21T13:44:22.190000+00:00"^^xsd:dateTime ;
observable:subject "Revenge our father" ;
observable:to <http://example.org/kb/orestes-emailaccount-uuid> ;
] ;
sh:resultMessage "Less than 1 values on [ rdf:type uco-observable:EmailMessageFacet ; uco-observable:body Literal(\"To me, too, grant this boon-dark death to deal unto Aegisthus, and to 'scape my doom.\") ; uco-observable:from kb:electra-emailaccount-uuid ; uco-observable:messageID Literal(\"CAKBqNfyKo+ZXtkz6DUjWpvHy6O82jTbkNA@mail.gmail.com\") ; uco-observable:receivedTime Literal(\"2017-06-21T13:44:23.400000+00:00\" = 2017-06-21 13:44:23.400000+00:00, datatype=xsd:dateTime) ; uco-observable:sentTime Literal(\"2017-06-21T13:44:22.190000+00:00\" = 2017-06-21 13:44:22.190000+00:00, datatype=xsd:dateTime) ; uco-observable:subject Literal(\"Revenge our father\") ; uco-observable:to kb:orestes-emailaccount-uuid ]->observable:isMimeEncoded" ;
sh:resultPath observable:isMimeEncoded ;
sh:resultSeverity sh:Violation ;
sh:sourceConstraintComponent sh:MinCountConstraintComponent ;
sh:sourceShape [
sh:datatype xsd:boolean ;
sh:maxCount "1"^^xsd:integer ;
sh:minCount "1"^^xsd:integer ;
sh:nodeKind sh:Literal ;
sh:path observable:isMimeEncoded ;
] ;
] ,
[
a sh:ValidationResult ;
sh:focusNode [
a observable:EmailMessageFacet ;
observable:body "To me, too, grant this boon-dark death to deal unto Aegisthus, and to 'scape my doom." ;
observable:from <http://example.org/kb/electra-emailaccount-uuid> ;
observable:messageID "CAKBqNfyKo+ZXtkz6DUjWpvHy6O82jTbkNA@mail.gmail.com" ;
observable:receivedTime "2017-06-21T13:44:23.400000+00:00"^^xsd:dateTime ;
observable:sentTime "2017-06-21T13:44:22.190000+00:00"^^xsd:dateTime ;
observable:subject "Revenge our father" ;
observable:to <http://example.org/kb/orestes-emailaccount-uuid> ;
] ;
sh:resultMessage "Less than 1 values on [ rdf:type uco-observable:EmailMessageFacet ; uco-observable:body Literal(\"To me, too, grant this boon-dark death to deal unto Aegisthus, and to 'scape my doom.\") ; uco-observable:from kb:electra-emailaccount-uuid ; uco-observable:messageID Literal(\"CAKBqNfyKo+ZXtkz6DUjWpvHy6O82jTbkNA@mail.gmail.com\") ; uco-observable:receivedTime Literal(\"2017-06-21T13:44:23.400000+00:00\" = 2017-06-21 13:44:23.400000+00:00, datatype=xsd:dateTime) ; uco-observable:sentTime Literal(\"2017-06-21T13:44:22.190000+00:00\" = 2017-06-21 13:44:22.190000+00:00, datatype=xsd:dateTime) ; uco-observable:subject Literal(\"Revenge our father\") ; uco-observable:to kb:orestes-emailaccount-uuid ]->observable:isMultipart" ;
sh:resultPath observable:isMultipart ;
sh:resultSeverity sh:Violation ;
sh:sourceConstraintComponent sh:MinCountConstraintComponent ;
sh:sourceShape [
sh:datatype xsd:boolean ;
sh:maxCount "1"^^xsd:integer ;
sh:minCount "1"^^xsd:integer ;
sh:nodeKind sh:Literal ;
sh:path observable:isMultipart ;
] ;
]
;
.
Expand Down
2 changes: 1 addition & 1 deletion examples/illustrations/src/illustration-nosrc.mk
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ SHELL := /bin/bash
# The expected execution context is in any sibling directory of this Makefile's directory.
top_srcdir := $(shell cd ../../.. ; pwd)

RDF_TOOLKIT_JAR := $(top_srcdir)/dependencies/CASE-unstable/dependencies/UCO/lib/rdf-toolkit.jar
RDF_TOOLKIT_JAR := $(top_srcdir)/dependencies/UCO-develop/lib/rdf-toolkit.jar

example_name := $(shell basename $$PWD)

Expand Down
1 change: 1 addition & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
case-utils >=0.6.0,<0.7.0
pytest

0 comments on commit 7138163

Please sign in to comment.