Skip to content

Handle push errors to avoid broken sync #60

@wonder-sk

Description

@wonder-sk

Sometimes it may happen that pushing a new version of a project fails for some reason (e.g. a network issue or a temporary server problem). Currently if that happens, the local directory is left with modifications - so the next time the daemon wakes up to do pull+push, the pull stage does not like the fact there are some pending changes, and the whole sync breaks.

If push fails, we should clean up the local directory - there's already a to-do left in the code:
https://github.com/lutraconsulting/mergin-db-sync/blob/master/dbsync.py#L486

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions