MacAssistant icon indicating copy to clipboard operation
MacAssistant copied to clipboard

Crashes when building with different client secret

Open malonehedges opened this issue 7 years ago • 4 comments

Because of the rate limiting by Google, I built it using my own credentials from Google. It kept crashing until I deleted the stored data from before.

malonehedges avatar May 24 '17 18:05 malonehedges

@malonehedges do you have the crash log? XCode should display it directly if running from there, if not, use Console.app

agucova avatar May 24 '17 21:05 agucova

I don't. Fixed it and moved on. Was giving errors in Authenticator.swift though. Can reproduce by building the app with a different google_oauth.json.

malonehedges avatar May 25 '17 00:05 malonehedges

Ah yeah, that's probably happening because the refresh token is stored in UserDefaults, and when you swap out the google_oauth.json file, it associates the wrong client key with the refresh token. I'll look into fixing the crash that results from this situation

vanshg avatar May 25 '17 00:05 vanshg

Has this issue been fixed? I seem to be having a similar problem when building from source. I get this error: Thread 1: Fatal error: Unexpectedly found nil while unwrapping an Optional value in this line: let expiresIn = Date(timeInterval: TimeInterval(json["expires_in"].int!), since: Date()) in the Authenticator.swift file. Any suggestions?

mglev1n avatar Dec 19 '17 13:12 mglev1n