When subject data in the graph contains pipeline metadata, an aggregate mode query response for the dataset should include a non-empty dictionary for available_pipelines.
Current Behavior
available_pipelines is always an empty dictionary {}.
And so this is what is currently always returned in aggregate mode.
Error message
No response
Environment
OS:
Python/Node version:
How to reproduce
Install and launch the API from source, in aggregate mode, and point it to a graph containing data from fhttps://github.com/neurobagel/neurobagel_examples/tree/main/data-upload/pheno-bids-derivatives-output.
Is there an existing issue for this?
Expected Behavior
When subject data in the graph contains pipeline metadata, an aggregate mode query response for the dataset should include a non-empty dictionary for
available_pipelines
.Current Behavior
available_pipelines
is always an empty dictionary{}
.This is because the aggregation statement in the SPARQL query template has not yet been updated to return pipeline variables, and similarly, the API-side handling of the graph response for an aggregate query currently does not consider these variables. https://github.com/neurobagel/api/blob/c150b37c659ffd16fe3d38d982f09ccd5edf996c/app/api/utility.py#L306-L315
At the same time, the value of
available_pipelines
is always initialized as an empty dict: https://github.com/neurobagel/api/blob/c150b37c659ffd16fe3d38d982f09ccd5edf996c/app/api/crud.py#L171 https://github.com/neurobagel/api/blob/c150b37c659ffd16fe3d38d982f09ccd5edf996c/app/api/crud.py#L290And so this is what is currently always returned in aggregate mode.
Error message
No response
Environment
How to reproduce
Install and launch the API from source, in aggregate mode, and point it to a graph containing data from fhttps://github.com/neurobagel/neurobagel_examples/tree/main/data-upload/pheno-bids-derivatives-output.
Anything else?
No response