pepkit / geofetch

Builds a PEP from SRA or GEO accessions
https://pep.databio.org/geofetch/
BSD 2-Clause "Simplified" License
45 stars 5 forks source link

Error while downloading project #98

Closed khoroshevskyi closed 1 year ago

khoroshevskyi commented 1 year ago

Error occured, when I tryed download GSE216814 raw project:

Traceback (most recent call last):
  File "/home/runner/work/geo_***/geo_***/geo_pipeline_script.py", line 127, in <module>
    sys.exit(main())
  File "/home/runner/work/geo_***/geo_***/geo_pipeline_script.py", line 115, in main
    upload_geo_projects(
  File "/home/runner/work/geo_***/geo_***/geo_pipeline_script.py", line 43, in upload_geo_projects
    project_dict = geofetcher_obj.get_projects(gse)
  File "/opt/hostedtoolcache/Python/3.10.8/x64/lib/python3.10/site-packages/geofetch/geofetch.py", line 318, in get_projects
    ser_dict = self.fetch_all(input=input)
  File "/opt/hostedtoolcache/Python/3.10.8/x64/lib/python3.10/site-packages/geofetch/geofetch.py", line 411, in fetch_all
    file_gsm_content = Accession(acc_GSE).fetch_metadata(
  File "/opt/hostedtoolcache/Python/3.10.8/x64/lib/python3.10/site-packages/geofetch/utils.py", line 205, in fetch_metadata
    result = requests.get(full_url)
  File "/opt/hostedtoolcache/Python/3.10.8/x64/lib/python3.10/site-packages/requests/api.py", line 73, in get
    return request("get", url, params=params, **kwargs)
  File "/opt/hostedtoolcache/Python/3.10.8/x64/lib/python3.10/site-packages/requests/api.py", line 59, in request
    return session.request(method=method, url=url, **kwargs)
  File "/opt/hostedtoolcache/Python/3.10.8/x64/lib/python3.10/site-packages/requests/sessions.py", line 587, in request
    resp = self.send(prep, **send_kwargs)
  File "/opt/hostedtoolcache/Python/3.10.8/x64/lib/python3.10/site-packages/requests/sessions.py", line 745, in send
    r.content
  File "/opt/hostedtoolcache/Python/3.10.8/x64/lib/python3.10/site-packages/requests/models.py", line 899, in content
    self._content = b"".join(self.iter_content(CONTENT_CHUNK_SIZE)) or b""
  File "/opt/hostedtoolcache/Python/3.10.8/x64/lib/python3.10/site-packages/requests/models.py", line 818, in generate
    raise ChunkedEncodingError(e)
requests.exceptions.ChunkedEncodingError: ("Connection broken: InvalidChunkLength(got length b'', 0 bytes read)", InvalidChunkLength(got length b'', 0 bytes read))
Error: Process completed with exit code 1.

We should fix this error , or add Exception Handling

khoroshevskyi commented 1 year ago

Update: This error is out of date, likely solved