A standardized browser-based spreadsheet editor and validator that can be run offline and locally, and which includes templates for SARS-CoV-2 and Monkeypox sampling data. This project, created by the Centre for Infectious Disease Genomics and One Health (CIDGOH), at Simon Fraser University, is now an open-source collaboration with contributions from the National Microbiome Data Collaborative (NMDC), the LinkML development team, and others.
MIT License
97
stars
27
forks
source link
Use existing todos conventions for min/max constraints #426
These changes update the Validator class to be consistent with existing conventions around storing minimum and maximum date values in todos with the >= and <= prefixes. It also allows enables the use of the convention of >={other slot name} or <={other slot name} in todos to indicate that the min/max value for one slot is dependent on the value of another slot.
I added cases to the unit test and did some basic interactive testing with the covid template. I think it's working as expected without any changes to the existing schema. But please give it a good test and let me know if you find any existing schemas that aren't being interpreted correctly!
These changes update the
Validator
class to be consistent with existing conventions around storing minimum and maximum date values intodos
with the>=
and<=
prefixes. It also allows enables the use of the convention of>={other slot name}
or<={other slot name}
intodos
to indicate that the min/max value for one slot is dependent on the value of another slot.I added cases to the unit test and did some basic interactive testing with the covid template. I think it's working as expected without any changes to the existing schema. But please give it a good test and let me know if you find any existing schemas that aren't being interpreted correctly!