Answer the question
In order to leave comments, you need to log in
GoogleDrive API. Exception if app is signed with production key?
Hello!
I am using the Google Drive API in an application. Everything worked fine when the app was signed with a development key (debug.keystore). But when I signed the production key, a very strange problem arose.
This is the code to find and create folders on the drive:
com.google.api.services.drive.Drive.Files.List request =
service.files().list()
.setQ("'" + folderId + "' in parents " +
"and mimeType='application/vnd.google-apps.folder' " +
"and trashed=false " +
"and title='" + title + "'");
FileList files = request.execute();
if (files.getItems().size() == 0) {
ParentReference parentReference = new ParentReference();
parentReference.setId(folderId);
parent.add(parentReference);
File body = new File();
body.setTitle(title);
body.setMimeType("application/vnd.google-apps.folder");
body.setParents(parent);
File file = service.files().insert(body).execute();
folderId = file.getId();
} else {
folderId = files.getItems().get(0).getId();
}
java.lang.IllegalArgumentException: unable to create new instance of class com.google.abaae because it has no accessible default constructor
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question