iiasa / message-ix-models

Tools for the MESSAGEix-GLOBIOM family of models
https://docs.messageix.org/models
Apache License 2.0
17 stars 33 forks source link

`snapshot.fetch()` errors since Zenodo migration #131

Closed khaeru closed 11 months ago

khaeru commented 11 months ago

On 2023-10-13, Zenono migrated to a new platform/backend. Since that time, test_snapshot.py::test_load[0] has failed. The symptoms vary:

  1. Here, pooch appears to get an response from Zenodo, but the response appears to be malformed, resulting in KeyError: 'key' within pooch. When this occurs, the Zenodo record URL also appears accessible through the browser.
  2. At other times, Zenodo record URLs (in particular https://zenodo.org/record/5793870) appear not to resolve. In a browser, this can manifest as:

    • 504 Gateway Time-out, displayed as a plain HTML page.
    • 503 Application Not Available, displayed as an error page that identifies a CERN "OKD" cluster.

    …in either case, this results in pooch raising ValueError: Archive with doi:10.5281/zenodo.5793870 not found (see https://zenodo.org/record/5793870). Is the DOI correct?

Currently:

Some combination of the following seems likely. Respectively with the symptoms above:

  1. Either:
    • A. Zenodo is operational, but the migration has resulted in unintended/unadvertised changes in its API responses that cause the pooch error. (Zenodo has What's changed? and What's new? pages describing the migration, but they don't indicate any API changes. Its API documentation doesn't indicate a new version.)
    • B. Zenodo is operational, and as part of its migration has well-defined changes to its API; pooch has not adapted to these. Compare fatiando/pooch#350, which suggests the new platform "InvenioRDM" has a distinct API that is not yet supported by pooch.
  2. Zenodo is not operational.

Mitigation

Fix

khaeru commented 11 months ago

Pooch 1.8.0 was released with a fix for the upstream bug; today, the scheduled pytest run gave XPASS for the test that was previously FAIL/XFAIL-ing.

So this is likely fixed, and the last step is to remove the XFAIL mark.

glatterf42 commented 11 months ago

The test in question is passing again, even though other tests on #137 are still failing at the moment. Thus, I'm going to close this issue.