Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Some RMA queries never return all results #98

Open
Stannislav opened this issue Dec 10, 2021 · 0 comments · May be fixed by #99
Open

Some RMA queries never return all results #98

Stannislav opened this issue Dec 10, 2021 · 0 comments · May be fixed by #99
Assignees

Comments

@Stannislav
Copy link
Contributor

Stannislav commented Dec 10, 2021

The following code snippet sends a particular RMA query, for which the number of results returned by the server is always consistently smaller than the total number of results reported in the status part of the reponse:

from atldld.requests import RMAParameters, rma_all

rma_parameters = RMAParameters(
    "SectionDataSet",
    criteria={
        "specimen": {"donor": {"age": {"days": 56}}},
        "probes": {"orientation": {"name": "Antisense"}}
    },
)

msg = rma_all(rma_parameters)
  • Number of results reported: 50476
  • Number of results received: 50274

This leads to rma_all raising a RuntimeError:

Downloading the metadata for all results...
Traceback (most recent call last):
  File "/Users/sschmidt/Code/BlueBrain/atldld/x.py", line 17, in <module>
    msg = rma_all(rma_parameters)
  File "/Users/sschmidt/Code/BlueBrain/atldld/src/atldld/requests.py", line 187, in rma_all
    raise RuntimeError("No data received")
RuntimeError: No data received

Given that the behaviour of not returning all results reported is reproducible we should probably not raise but only print a warning and still return the results received.

@Stannislav Stannislav self-assigned this Dec 10, 2021
@Stannislav Stannislav linked a pull request Dec 10, 2021 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant