Open DnlRKorn opened 1 year ago
The following query failed with the attached 500 error (I'm not 100% sure we care about supporting this type of query in general, it isn't critical for any process I'm doing right now, but this definitely looks like a bug and not a rejection)
Query: { "message": { "query_graph": { "nodes": { "chemical": { "ids": [ "PUBCHEM.COMPOUND:23925" ] }, "disease": { "ids": null, "categories": [ "biolink:Disease" ] } }, "edges": { "t_edge": { "object": "disease", "subject": "chemical", "predicates": [ "biolink:treats" ], "knowledge_type": "inferred" } } } } }
{ "message": { "query_graph": { "nodes": { "chemical": { "ids": [ "PUBCHEM.COMPOUND:23925" ] }, "disease": { "ids": null, "categories": [ "biolink:Disease" ] } }, "edges": { "t_edge": { "object": "disease", "subject": "chemical", "predicates": [ "biolink:treats" ], "knowledge_type": "inferred" } } } } }
Response: { "message": { "query_graph": { "nodes": { "chemical": { "ids": [ "PUBCHEM.COMPOUND:23925" ] }, "disease": { "ids": null, "categories": [ "biolink:Disease" ] } }, "edges": { "t_edge": { "subject": "chemical", "object": "disease", "knowledge_type": "inferred", "predicates": [ "biolink:treats" ] } } } }, "logs": [ { "timestamp": "2023-01-10T15:08:59.836518", "level": "INFO", "message": "pid: 5226fefa8d95", "code": null }, { "timestamp": "2023-01-10T15:08:59.838912", "level": "ERROR", "message": "Exception 'NoneType' object is not subscriptable", "code": null } ], "pid": "5226fefa8d95" }
{ "message": { "query_graph": { "nodes": { "chemical": { "ids": [ "PUBCHEM.COMPOUND:23925" ] }, "disease": { "ids": null, "categories": [ "biolink:Disease" ] } }, "edges": { "t_edge": { "subject": "chemical", "object": "disease", "knowledge_type": "inferred", "predicates": [ "biolink:treats" ] } } } }, "logs": [ { "timestamp": "2023-01-10T15:08:59.836518", "level": "INFO", "message": "pid: 5226fefa8d95", "code": null }, { "timestamp": "2023-01-10T15:08:59.838912", "level": "ERROR", "message": "Exception 'NoneType' object is not subscriptable", "code": null } ], "pid": "5226fefa8d95" }
This function addresses this issue
https://github.com/ranking-agent/aragorn/blob/250b32a47827049f82fe1d804fba9171d478ae7c/src/service_aggregator.py#L584
This should be fixed on the renci deployments. @DnlRKorn can you confirm?
The following query failed with the attached 500 error (I'm not 100% sure we care about supporting this type of query in general, it isn't critical for any process I'm doing right now, but this definitely looks like a bug and not a rejection)
Query:
{ "message": { "query_graph": { "nodes": { "chemical": { "ids": [ "PUBCHEM.COMPOUND:23925" ] }, "disease": { "ids": null, "categories": [ "biolink:Disease" ] } }, "edges": { "t_edge": { "object": "disease", "subject": "chemical", "predicates": [ "biolink:treats" ], "knowledge_type": "inferred" } } } } }
Response:
{ "message": { "query_graph": { "nodes": { "chemical": { "ids": [ "PUBCHEM.COMPOUND:23925" ] }, "disease": { "ids": null, "categories": [ "biolink:Disease" ] } }, "edges": { "t_edge": { "subject": "chemical", "object": "disease", "knowledge_type": "inferred", "predicates": [ "biolink:treats" ] } } } }, "logs": [ { "timestamp": "2023-01-10T15:08:59.836518", "level": "INFO", "message": "pid: 5226fefa8d95", "code": null }, { "timestamp": "2023-01-10T15:08:59.838912", "level": "ERROR", "message": "Exception 'NoneType' object is not subscriptable", "code": null } ], "pid": "5226fefa8d95" }