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

Validate opil.SampleSet template when loading from an opil file #171

Open
tramyn opened this issue Mar 24, 2021 · 1 comment
Open

Validate opil.SampleSet template when loading from an opil file #171

tramyn opened this issue Mar 24, 2021 · 1 comment

Comments

@tramyn
Copy link

tramyn commented Mar 24, 2021

Similar to issue #170, opil==1.0b3.post2 does not validate that an SampleSet must have its template field set. This will be valuable to know when reading in an opil file that this type of condition is satisfied.

@bbartley
Copy link
Collaborator

There are a couple ways we might prevent this from happening.

  1. Prevent users from constructing invalid objects. This would necessitate checking that a user has specified required parameters in the constructor call. I believe pySBOL does this type of checking in constructors but OPIL currently does not. This should be slated for the b5 release.
  2. Add SHACL rules in the validation of the OPIL Document. In fact, I believe SHACL already checks that cardinality requirements for a property are fulfilled. However, there is a possible failure mode in which the pySBOL3 serializer inserts dummy values, and this is not currently checked.

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

2 participants