API client to access some of the MMODA resources: INTEGRAL, POLAR, ANTARES, LIGO/Virgo, SDSS
2
stars
2
forks
source link
Think of using "duck type compatibility" in `ontology_helper._get_datatype_restriction()` #254
Open
dsavchenko opened 6 months ago
Example: Restricting Percentage to integer values.
Maybe return
xsd:Integer
instead of throwing "Ambiguous datatype" when possible. This will in principle follow PEP https://peps.python.org/pep-0484/#the-numeric-towerBut to check with dispatcher. Do we have a way to restrict
Float
class?But: Doesn't we produce inconsistent ontology (xsd:integer is not a subclass of xsd:float)? Maybe there are better ways?