Closed RichardBruskiewich closed 2 years ago
SRI Testing currently simply relies directly on the reasoner-validator module which itself just relies on the jsonschema module validation of the TRAPI schema.
It would appear that the current iteration of TRAPI 1.3 (as of this date, 25-8-2022) has problematic validation. For example, the following error trace is thrown for the infores:sri-reference-kg
based on the current 1.3.0 TRAPI:
FAILED [ 58%][{'node_bindings': {'a': [{'id': 'MGI:1928401', 'query_id': None, 'attributes': None}], 'b': [{'id': 'GO:0035371', 'query_id': None, 'attributes': None, 'qnode_id': 'GO:0035371'}]}, 'edge_bindings': {'ab': [{'id': 'uuid:3aed51ea-d0a0-11ec-b00f-0242ac110002', 'attributes': None}]}, 'score': None},
...] is not of type 'object'
Failed validating 'type' in schema:
{'additionalProperties': True,
'components': {'schemas': {'AsyncQuery': {'additionalProperties': True,
'description': 'The AsyncQuery class is effectively the same as the Query class but it requires a callback property.',
'properties': {'callback': {'description': 'Upon completion, this server ...'
'format': 'uri',
'pattern': '^https?://',
'type': 'string'},
'log_level': {'oneOf': [{'allOf': [{'$ref': '#/components/schemas/LogLevel'}],
'description': 'The least critical level of logs to return'},
{'type': 'null'}]},
'message': {'$ref': '#/components/schemas/Message',
'description': 'The query Message is a serialization ...},
etc.
The back end reasoner-validator jsonschema validation is now patched to validate 1.3.0 with commit https://github.com/NCATSTranslator/reasoner-validator/commit/d566566f3389703d73f18cfef7908b16df2689d6 (but some TRAPI 1.4.0 remedial work needed in the future).
See https://github.com/NCATSTranslator/ReasonerAPI/tree/1.3
In particular, see the change log in https://github.com/NCATSTranslator/ReasonerAPI/pull/340