Re: sync timing issue
There's generally no way to detect that a file has not been finished uploading yet.
This article discusses the issue from an uploader's perspective:
https://winscp.net/eng/docs/script_locking_files_while_uploading
Gotcha, thanks for the information.