I'm using the Google Drive objective C SDK to find (among other things) the list of files in the root directory of users GDrive. The vast majority of the time, this works beautifully. However, for some small percentage of users, I seem to hit some mysterious 500 error. I turned on logging and got this:
Response: status 200
Response headers:
<set of regular-looking headers>
Response body: (35 bytes)
{
"id" : "gtl_1",
"error" : {
"code" : 500
}
}
The error I get back in code from the SDK is:
Error Domain=com.google.GTLJSONRPCErrorDomain Code=500 "The operation couldn’t be completed. (com.google.GTLJSONRPCErrorDomain error 500.)" UserInfo=0xd8aa3c0 {GTLStructuredError=GTLErrorObject 0xb7abba0: {code:500}}
This seems to happen more with Google Apps for Education accounts than with regular @gmail accounts. When asking for files in the root directory, I use q='root' in parents
, as Claudio suggests to do here. When I remove q='root' in parents
from my query, everything seems to work fine (except for the fact that I get back a list of all files, instead of just the files in root).
Is this an issue with Google Apps for Education and root directories? Is there a way I can get around or fix this issue, while still only asking Google Drive only for the list of files that I actually want?
This issue may be related to this?