-
Notifications
You must be signed in to change notification settings - Fork 5
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
Need to handle failed uploads #5
Comments
@lindemann09 wanted to make sure you're aware of this issue, in the interests of not losing files! :-) |
The key problem is around line 245 of sync.py :
At the end of sync this is assuming that sync was successful and sets the |
Thanks for the update. I didn't have the problem yet, but I'll keep an eye on it. |
I am having the same problem: pyosf wants to delete files on my local machine following failed uploads which occur frequently out here on the fringes of the net (I live on Guam). As a workaround to prevent data loss, I always do print(changes) to examine proposed changes prior to executing changes.apply(). If the proposed changes indicate that local files are to be deleted, I execute changes = proj.get_changes() and print(changes) again. pyosf is a great tool and I hope this bug can be fixed. |
I find relatively often that uploading files is resulting in a requests timeout I don't know whether that's an issue with the OSF.io server or whether it's a problem with pyosf code.
What is definitely a problem currently with pyosf is that when this occurs the local database still thinks the file was successfully sent. When it then discovers that the file isn't there remotely it thinks the file has been deleted at the server and deletes the local copy too! This is obviously bad. We need to fix by:
The text was updated successfully, but these errors were encountered: