crspybits / SharedImages

Neebla on the Apple App Store: Private and Self-Owned Social Media: This is *deprecated*: see http://github.com/SyncServerII/Neebla.git
https://crspybits.github.io/SyncServerII/
MIT License
12 stars 9 forks source link

Failures to register for push notifications #160

Open crspybits opened 5 years ago

crspybits commented 5 years ago

The scenario looks like this: 1) I've been installing dev versions of Neebla to my iPhone, which give (expectedly) failures registering for PN's-- because they're connecting to the prod server, and this will try to use the wrong certificate. 2)I install a production (app store) version of Neebla, and I get (unexpected) failures to register for PN's. This happens when the app launches and first goes to the Albums screen. 3) When I look at the logs in the server, I see a failure of authorization.

I think what's going on here is that: a) the cached auth token has been evicted on the server b) the auth token, on launch, is being refreshed c) but there is a race condition on getting the new auth token (through Google's SDK in the iOS app) and landing on the Albums screen-- and the new auth token doesn't get sent to the server.

HOWEVER, when I kill the app and and retry, several times, I still get the problem with registering for PN's. Perhaps I didn't let the app sit long enough to get the new auth token?