HTTP Error 502: Bad Gateway -- when downloading form data

We are currently getting HTTP Error 502: Bad Gateway errors when trying to download form data.

For example:

  • The “DATA” tab in Kobo Toolbox shows an error message.
    https://kobo.humanitarianresponse.info/#/forms/aWjXzx8av32uJaDrnHEj8G/data/report
  • We see a similar error when using the JSON API at https://kobo.humanitarianresponse.info/api/v2/assets/aWjXzx8av32uJaDrnHEj8G/data.json?limit=100&start=0

Both of these methods have worked well before. My last successful download was on November 25. At this time there were 389417 entries. My first failed download was yesterday December 8. The failures are still occurring today.

This might be similar to this recently reported issue: Error message while viewing DATA>Table

We’d appreciate your help. Thanks in advance!

Welcome to the community @Sjlver! Would you mind trying to download your data by first making your data public. Kindly please let us know what happens.

Thanks for looking into this, @Kal_Lam. I’ve responded privately regarding the permission settings.

OK, would you mind trying out one more try by downloading your data using the API when you are still logged into your account.

Sure! I’ve just tried again, and I am getting the same error despite being logged in on the browser. Note also that I’m seeing the 502 error both when using the API and when being logged in. Here’s a screenshot:

I’ve also just verified that the auth token of the API is valid (from https://kobo.humanitarianresponse.info/token/?format=json). No changes here. I believe this isn’t a permission issue. If it were, I would probably see a 403 permission denied error or similar.

1 Like

Oh, i now see. It’s an issue recently identified which has already been flagged to the developers. Will reach you back once it’s solved.

FYI, some users are facing this when they have a lot of data in their user account.

2 Likes

The download worked just now (with some intermittent failures; retrying helped)

This looks like a server capacity issue. Maybe preparing a batch of data takes too much time under high server load, and hits a timeout?

2 Likes