As of April 12th, you must go to Progress SupportLink to create new support cases or to access existing cases. Please, bookmark the SupportLink URL and use the new portal to contact the support team.
I am using createAutogeneratedUser when the app first launches if there is no active user or saved credentials. This user is basically a 'guest', but it is possible to update the user with email, name etc at a later date. If I quit the app without changing anything, it logs back in with the saved credentials as it should and I immediately have an activeUser. If I change the email, etc and quit the app, it still has saved credentials when it launches but it never resolves to an active user.
I read in another thread that changing the special attributes alters the auth token, but I can't find any way to refresh it. Even if I didn't use an auto-generated user at first, the user would need to be able to edit those fields.
Can anybody offer any insights as to what's happening, and if there's a solution.
It actually seems unable to use the saved credentials to log in again from any user that has been modified from the auto-generated user.
The basic auto-generated user seems to always work.
When I log in with an updated user or update the auto-generated user's data, the saved credentials no longer work when launching the app.
E
Ed Ragsdale
said
over 9 years ago
Could it have something to do with changing to a staging environment? I've changed back with no difference, but I could see it potentially causing trouble with the keychain. I really can't think of why a newly logged in user wouldn't be able to use saved credentials.
It's hard to troubleshoot this sort of thing since the Kinvey SDK is pretty opaque. Do you have any tips for how to proceed? Any thoughts on things that could be causing it?
M
Mike
said
over 9 years ago
Can you describe more about your use of environments? The tokens are different for each environment, even if you copy the user data between them; this means a user created in one environment cannot be used in another, at least not without log-out and re log-in.
E
Ed Ragsdale
said
over 9 years ago
We were initially using a development environment, which we cloned to a staging environment. I've tried both newly created and old users in both environments with the same results. Whenever the user is modified from the originally created user, the automatic login fails on launch. Whether a fresh login or modified after first login.
E
Ed Ragsdale
said
over 9 years ago
I think I've finally found the answer but I'm not sure I understand why it was causing the issue. After logging in or registering a new user I was clearing the data store cache like so.
[KCSLinkedAppdataStore clearCaches];
I was calling this method because old data was showing up when showing the logged-in interface and this fixed that issue. I would have preferred to clear out a specific instance of KCSLinkedAppdataStore for the data I needed to clear, but I couldn't find any way to do so. Regardless, I don't understand how the user is tied to the data store class. Can someone provide a little explanation as to why this would happen?
M
Mike
said
over 9 years ago
Clearing the caches also clears out the user cache which will mess up the active user. It is better to logout the active user, which should reset the app state.
E
Ed Ragsdale
said
over 9 years ago
So there is no supported method to clear data caches while logged in?
On a separate note, and I can start a new thread if necessary, but when I log out during data retrieval it crashes the app. Is there a way to suspend all data store queries before logging out?
Ed Ragsdale
I read in another thread that changing the special attributes alters the auth token, but I can't find any way to refresh it. Even if I didn't use an auto-generated user at first, the user would need to be able to edit those fields.
Can anybody offer any insights as to what's happening, and if there's a solution.