-
Notifications
You must be signed in to change notification settings - Fork 1
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
Download data gives error HTTP code: 500 for large files. #5
Comments
While using the
|
Thanks so much for the helpful bug report!🙏
On the surface of things, the 500 code would point to an unspecified problem with the server rather than the client (i.e., your script). With that in mind, I wonder if it would be possible to investigate the resource usage of the server at or around the time of the 500 code. On that same theme, do you experience any issues downloading the files through the UI? Given that this is likely a server load/capacity/performance issue, I'm wondering how best to handle it. Perhaps we could introduce a user-specified wait period between requests (e.g., wait 20 seconds between requesting v1 and v2) or segments of the download process (e.g., wait N seconds between the file being complete and an attempt to download it). Perhaps there's also a way to query whether the file has been placed in the export folder for download. With large file sizes, perhaps it takes some time to copy or write large files even after the export process is signalled as complete, and download requests in that period will result in a 500 code. Ideally, we'd find a way for this to just work. And I can do some research on how to improve the process. But if there's no way to improve on this situation, what would be your preferred outcome:
In practice, I think it will be the first bullet plus the second or third bullet. Even if we retry, there's no guarantee that the request will succeed. |
I tried using the I tried to simplify the function. This function worked as expected.
Then, I added a two second |
The survey solutions logs has this when the I get the 500 error.
|
We have a questionnaire with 4 versions. Ver 1 and 2 have 99 an 177 interviews respectively, while version 3 and version 4 have large no of interviews (~14000 and ~20000 respectively).
While downloading data using
download_data()
ordownload_matching()
functions, the export process breaks for questionnaire version that have large no of interviews. The function downloads files for the first 2 versions but I getHTTP code: 500
for version 3 and 4. The size of the files generated is ~12MB for ver 1 and 2, while ~30MB for ver 3 and 4.Pls get back if you need additional help troubleshooting.
The text was updated successfully, but these errors were encountered: