summaryrefslogtreecommitdiff
path: root/client/src/leap/soledad
diff options
context:
space:
mode:
authordrebs <drebs@leap.se>2015-05-12 18:07:27 -0300
committerdrebs <drebs@leap.se>2015-05-20 10:16:46 -0300
commitd1c39d389737ee844f42c5ed3dfc97c8ddf24250 (patch)
tree787cd131ea8d7bccb358c5c3cd06460db460e3e2 /client/src/leap/soledad
parent67f17cd30d01696ab24407b907bb55ae0fddacad (diff)
[bug] remove unused pending documents exception
When we started implementing the sync db, one of the ideas was to reuse the data in the database in the case of a sync interruption. We don't do that now and thus the pending documents exception is unneeded. This commit removes that exception from the code.
Diffstat (limited to 'client/src/leap/soledad')
-rw-r--r--client/src/leap/soledad/client/sqlcipher.py6
-rw-r--r--client/src/leap/soledad/client/target.py4
2 files changed, 0 insertions, 10 deletions
diff --git a/client/src/leap/soledad/client/sqlcipher.py b/client/src/leap/soledad/client/sqlcipher.py
index d3b3d01b..39d5dd0e 100644
--- a/client/src/leap/soledad/client/sqlcipher.py
+++ b/client/src/leap/soledad/client/sqlcipher.py
@@ -68,7 +68,6 @@ from twisted.enterprise import adbapi
from leap.soledad.client import encdecpool
from leap.soledad.client.target import SoledadSyncTarget
-from leap.soledad.client.target import PendingReceivedDocsSyncError
from leap.soledad.client.sync import SoledadSynchronizer
from leap.soledad.client import pragmas
@@ -636,17 +635,12 @@ class SQLCipherU1DBSync(SQLCipherDatabase):
log.msg('syncer sync...')
res = syncer.sync(autocreate=autocreate,
defer_decryption=defer_decryption)
-
- except PendingReceivedDocsSyncError:
- logger.warning("Local sync db is not clear, skipping sync...")
- return
except CannotSendRequest:
logger.warning("Connection with sync target couldn't be "
"established. Resetting connection...")
# closing the connection it will be recreated in the next try
syncer.sync_target.close()
return
-
return res
def stop_sync(self):
diff --git a/client/src/leap/soledad/client/target.py b/client/src/leap/soledad/client/target.py
index 17ce718f..f2415218 100644
--- a/client/src/leap/soledad/client/target.py
+++ b/client/src/leap/soledad/client/target.py
@@ -71,10 +71,6 @@ def _gunzip(data):
return data
-class PendingReceivedDocsSyncError(Exception):
- pass
-
-
class DocumentSyncerThread(threading.Thread):
"""
A thread that knowns how to either send or receive a document during the