-
Notifications
You must be signed in to change notification settings - Fork 61
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to reset all Sync data to get a clean whole store upload? #87
Comments
I'm asking to get a workaround for my users. |
If you remove all the data from Dropbox you should be getting errors returned through the ApplicationSyncManagerDelegate and DocumentSyncManagerDelegate methods. Specifically, once your know that syncing has been set up, if you get a callback from: - (void)applicationSyncManagerDidPauseRegistrationToAskWhetherToUseEncryptionForFirstTimeRegistration:(TICDSApplicationSyncManager *)applicationSyncManager then you know that something has gone sideways on Dropbox. Similarly you can handle remote file structure changes through these DocumentSyncManagerDelegate methods: - (void)documentSyncManager:(TICDSDocumentSyncManager *)documentSyncManager didPauseRegistrationAsRemoteFileStructureDoesNotExistForDocumentWithIdentifier:(NSString *)anIdentifier description:(NSString *)aDescription userInfo:(NSDictionary *)userInfo;
- (void)documentSyncManager:(TICDSDocumentSyncManager *)documentSyncManager didPauseRegistrationAsRemoteFileStructureWasDeletedForDocumentWithIdentifier:(NSString *)anIdentifier description:(NSString *)aDescription userInfo:(NSDictionary *)userInfo;
- (void)documentSyncManager:(TICDSDocumentSyncManager *)documentSyncManager didFailToSynchronizeWithError:(NSError *)error;
For that last one just check if the error code is Hope this helps! |
Hi, I will check the callback methods you mentioned this evening to get a better feeling what's going wrong.
May you want to check the logs? |
Assuming that your apps are properly handling the delegate methods I mentioned above, if you remove all the sync data from Dropbox and then push up a fresh baseline from one client, all your other clients should detect that the sync setup has changed and give the user appropriate options. For instance, in MoneyWell, if we detect that the sync data on Dropbox has changed we let the user know and prompt them to setup syncing again. As they go through that process the sync setup classes that we've written handle allowing them to upload their document or download one that another user has posted. |
Ok if I delete the sync data from Dropbox will my App detect that via the It even fails if I uninstall all copies of my App but from one device and delete the App-Folder on Dropbox. |
It's possible that you're getting caught by some leftover files from a previous sync. You can stand up a temporary DocumentSyncManager to clean out the local files as well: - (void)teardownLocalSetup
{
NSError *fileCleanupError = nil;
TICDSDocumentSyncManager *documentSyncManager = [[TICDSDocumentSyncManager alloc] init];
[documentSyncManager removeLocalHelperFiles:&fileCleanupError];
if (fileCleanupError != nil) {
NSLog(@"%s %@", __PRETTY_FUNCTION__, fileCleanupError);
}
} |
I'm experiencing a few problems after updating my CoreData model (Issue #86). Even if I delete the remote dropbox folder and remove the app from all device but the one with latest data and doing a "upload whole store", new device doesn't get this latest data.
Maybe its related to some change sets on the device which is uploading the latest data, so I'm wondering if it is possible the erase all remaining sync sets? After that the whole store upload should contain the content of the sqlite store?
@MrRooni What do you say?
The text was updated successfully, but these errors were encountered: