ERROR 138: Sync interrupted

Problem

During an initial sync or catch-up sync, the sync process is interrupted if the user switches to another app or puts the device to sleep. Disconnected or dropped internet connections also result in interrupted sync.

In the log, this shows as Sync interrupted (138).

Example

In this example, the user’s debug log shows an Error 138, and that the sync was interrupted.

[23-08-07 18:17:02][INFO ][0x16f37b000] - Sync interrupted (138) [23-08-07 18:17:02][ERROR][0x16f37b000] - syncQueryModifiedWave failed (138) [23-08-07 18:17:02][ERROR][0x16f37b000] - doRelationshipSync failed (138) [23-08-07 18:17:02][ERROR][0x16f37b000] - syncQueryModifiedIfNecessary (Relationship Sync) failed (138) [23-08-07 18:17:02][INFO ][0x16f37b000] - integrateAfterSync called [23-08-07 18:17:02][INFO ][0x16f37b000] - copyVarsToOtherInstance called [23-08-07 18:17:02][INFO ][0x16f37b000] - copyVarsToOtherInstance complete [23-08-07 18:17:02][INFO ][0x16f37b000] - integrateAfterSync: skipped due to sync failure (138) [23-08-07 18:17:02][ERROR][0x16f37b000] - sfsub->sync() failed (138) . . [23-08-07 18:17:02][INFO ][0x16f37b000] - last sync was interrupted, requesting a continuing sync

Later, when the user logs in again, the sync is resumed.

[23-08-07 18:17:04][INFO ][0x16f51f000] - interrupted sync is now being resumed, clearing interrupted state

Solution

Pulsar requires that the application stays open during the sync process. Users should be trained to let the sync process complete without interruptions. This means that the user cannot use other apps on the device until they see the process is complete. The user should also ensure the internet connection remains for the entire sync process.

Instruct users to attempt the sync again while ensuring the app is in the foreground with internet connectivity.