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

Handle IndexError: list index out of range from study = results[0] from gold_client.py line 162, in fetch_study #133

Open
turbomam opened this issue Jan 14, 2025 · 1 comment · May be fixed by #139

Comments

@turbomam
Copy link
Member

turbomam commented Jan 14, 2025

The GOLD to MongoDB process can't"just be restarted" after an error like this without removing the offending identifier from the input file


2025-01-10 07:49:57,990 - WARNING - Duplicate key error for Gs0110165
2025-01-10 07:49:57,990 - INFO - Processing study Gs0110166...
2025-01-10 07:49:57,990 - INFO - Fetching study: Gs0110166

Traceback (most recent call last):
File "/home/mark/gitrepos/sample-annotator/sample_annotator/gold_to_mongo.py", line 160, in
main()
File "/home/mark/.cache/pypoetry/virtualenvs/sample-annotator-O-SG-H46-py3.10/lib/python3.10/site-packages/click/core.py", line 1161, in call
return self.main(*args, **kwargs)
File "/home/mark/.cache/pypoetry/virtualenvs/sample-annotator-O-SG-H46-py3.10/lib/python3.10/site-packages/click/core.py", line 1082, in main
rv = self.invoke(ctx)
File "/home/mark/.cache/pypoetry/virtualenvs/sample-annotator-O-SG-H46-py3.10/lib/python3.10/site-packages/click/core.py", line 1443, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/home/mark/.cache/pypoetry/virtualenvs/sample-annotator-O-SG-H46-py3.10/lib/python3.10/site-packages/click/core.py", line 788, in invoke
return __callback(*args, **kwargs)
File "/home/mark/gitrepos/sample-annotator/sample_annotator/gold_to_mongo.py", line 128, in main
study = gc.fetch_study(study_id, **args)
File "/home/mark/gitrepos/sample-annotator/sample_annotator/clients/gold_client.py", line 162, in fetch_study
study = results[0]
IndexError: list index out of range
make: *** [make-gold-cache.Makefile:39: load-gold-biosamples-into-mongo] Error 1

Originally posted by @turbomam in #125 (comment)

@turbomam turbomam changed the title Another error, but this one can't just be restarted Handle IndexError: list index out of range from study = results[0] from gold_client.py line 162, in fetch_study Jan 14, 2025
@turbomam
Copy link
Member Author

image

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