Hiya,
I've been using this program for about a week, to slowly housekeep smaller and smaller attachments, it works great.
As far as I am aware absolutely nothing has changed, but I have started to just get the following message.
I went back in to the google api project and created a new credentials.json - but still the same error.
Any ideas?
C:\Program Files\Java\jre-1.8\bin>java -jar GmailAttachmentsExtractor.jar larger:5m
May 22, 2024 2:47:35 PM com.google.api.client.util.store.FileDataStoreFactory setPermissionsToOwnerOnly
WARNING: unable to change permissions for everybody: C:\Program Files\Java\jre-1.8\bin\tokens
May 22, 2024 2:47:35 PM com.google.api.client.util.store.FileDataStoreFactory setPermissionsToOwnerOnly
WARNING: unable to change permissions for owner: C:\Program Files\Java\jre-1.8\bin\tokens
Starting Gmail Attachments Extractor v1.0.3
Parameters:
Query string: larger:5m
Output directory: C:\Program Files\Java\jre-1.8\bin\Gmail Extracted Attachments
Output labels prefix: Cleanup
com.google.api.client.auth.oauth2.TokenResponseException: 400 Bad Request
{
"error" : "invalid_grant",
"error_description" : "Token has been expired or revoked."
}
at com.google.api.client.auth.oauth2.TokenResponseException.from(TokenResponseException.java:105)
at com.google.api.client.auth.oauth2.TokenRequest.executeUnparsed(TokenRequest.java:287)
at com.google.api.client.auth.oauth2.TokenRequest.execute(TokenRequest.java:307)
at com.google.api.client.auth.oauth2.Credential.executeRefreshToken(Credential.java:570)
at com.google.api.client.auth.oauth2.Credential.refreshToken(Credential.java:489)
at com.google.api.client.auth.oauth2.Credential.intercept(Credential.java:217)
at com.google.api.client.http.HttpRequest.execute(HttpRequest.java:868)
at com.google.api.client.googleapis.services.AbstractGoogleClientRequest.executeUnparsed(AbstractGoogleClientRequest.java:419)
at com.google.api.client.googleapis.services.AbstractGoogleClientRequest.executeUnparsed(AbstractGoogleClientRequest.java:352)
at com.google.api.client.googleapis.services.AbstractGoogleClientRequest.execute(AbstractGoogleClientRequest.java:469)
at pl.geek.tewu.gmail_attachments_extractor.GmailAttachmentsExtractor.getGmailMessagesPage(GmailAttachmentsExtractor.java:307)
at pl.geek.tewu.gmail_attachments_extractor.GmailAttachmentsExtractor.extractAttachments(GmailAttachmentsExtractor.java:77)
at pl.geek.tewu.gmail_attachments_extractor.Main.call(Main.java:45)
at pl.geek.tewu.gmail_attachments_extractor.Main.call(Main.java:14)
at picocli.CommandLine.executeUserObject(CommandLine.java:1783)
at picocli.CommandLine.access$900(CommandLine.java:145)
at picocli.CommandLine$RunLast.executeUserObjectOfLastSubcommandWithSameParent(CommandLine.java:2150)
at picocli.CommandLine$RunLast.handle(CommandLine.java:2144)
at picocli.CommandLine$RunLast.handle(CommandLine.java:2108)
at picocli.CommandLine$AbstractParseResultHandler.execute(CommandLine.java:1975)
at picocli.CommandLine.execute(CommandLine.java:1904)
at pl.geek.tewu.gmail_attachments_extractor.Main.main(Main.java:29)
Hiya,
I've been using this program for about a week, to slowly housekeep smaller and smaller attachments, it works great.
As far as I am aware absolutely nothing has changed, but I have started to just get the following message.
I went back in to the google api project and created a new credentials.json - but still the same error.
Any ideas?
C:\Program Files\Java\jre-1.8\bin>java -jar GmailAttachmentsExtractor.jar larger:5m
May 22, 2024 2:47:35 PM com.google.api.client.util.store.FileDataStoreFactory setPermissionsToOwnerOnly
WARNING: unable to change permissions for everybody: C:\Program Files\Java\jre-1.8\bin\tokens
May 22, 2024 2:47:35 PM com.google.api.client.util.store.FileDataStoreFactory setPermissionsToOwnerOnly
WARNING: unable to change permissions for owner: C:\Program Files\Java\jre-1.8\bin\tokens
Starting Gmail Attachments Extractor v1.0.3
Parameters:
Query string: larger:5m
Output directory: C:\Program Files\Java\jre-1.8\bin\Gmail Extracted Attachments
Output labels prefix: Cleanup
com.google.api.client.auth.oauth2.TokenResponseException: 400 Bad Request
{
"error" : "invalid_grant",
"error_description" : "Token has been expired or revoked."
}
at com.google.api.client.auth.oauth2.TokenResponseException.from(TokenResponseException.java:105)
at com.google.api.client.auth.oauth2.TokenRequest.executeUnparsed(TokenRequest.java:287)
at com.google.api.client.auth.oauth2.TokenRequest.execute(TokenRequest.java:307)
at com.google.api.client.auth.oauth2.Credential.executeRefreshToken(Credential.java:570)
at com.google.api.client.auth.oauth2.Credential.refreshToken(Credential.java:489)
at com.google.api.client.auth.oauth2.Credential.intercept(Credential.java:217)
at com.google.api.client.http.HttpRequest.execute(HttpRequest.java:868)
at com.google.api.client.googleapis.services.AbstractGoogleClientRequest.executeUnparsed(AbstractGoogleClientRequest.java:419)
at com.google.api.client.googleapis.services.AbstractGoogleClientRequest.executeUnparsed(AbstractGoogleClientRequest.java:352)
at com.google.api.client.googleapis.services.AbstractGoogleClientRequest.execute(AbstractGoogleClientRequest.java:469)
at pl.geek.tewu.gmail_attachments_extractor.GmailAttachmentsExtractor.getGmailMessagesPage(GmailAttachmentsExtractor.java:307)
at pl.geek.tewu.gmail_attachments_extractor.GmailAttachmentsExtractor.extractAttachments(GmailAttachmentsExtractor.java:77)
at pl.geek.tewu.gmail_attachments_extractor.Main.call(Main.java:45)
at pl.geek.tewu.gmail_attachments_extractor.Main.call(Main.java:14)
at picocli.CommandLine.executeUserObject(CommandLine.java:1783)
at picocli.CommandLine.access$900(CommandLine.java:145)
at picocli.CommandLine$RunLast.executeUserObjectOfLastSubcommandWithSameParent(CommandLine.java:2150)
at picocli.CommandLine$RunLast.handle(CommandLine.java:2144)
at picocli.CommandLine$RunLast.handle(CommandLine.java:2108)
at picocli.CommandLine$AbstractParseResultHandler.execute(CommandLine.java:1975)
at picocli.CommandLine.execute(CommandLine.java:1904)
at pl.geek.tewu.gmail_attachments_extractor.Main.main(Main.java:29)