Skip to content

Do not upload files because parent folder have same timestamp #110

@obook

Description

@obook

Hello.
The UploadSynchronizer don't upload for new files because the remote parent folder retains the same date.

How can I work around this issue?

I have tried the force option without success. I am using pyftpsync in a Python script on GitLab.

Thank you for your help.

@b.

import os
from ftpsync.targets import FsTarget
from ftpsync.ftp_target import FTPTarget
from ftpsync.synchronizers import UploadSynchronizer

host = os.environ['FTP_ADDRESS']
user = os.environ['FTP_USER']
passwd = os.environ['FTP_PASSWORD']

local = FsTarget("/builds/xxxxxxxx/xxxxxxxx/public")

remote = FTPTarget("/gitlab/mathematiques-2e", host, username=user, password=passwd)
opts = {"force": True, "delete_unmatched": True, "verbose": 5}
s = UploadSynchronizer(local, remote, opts)
s.run()

Log

INFO:pyftpsync:EQUAL             =  [P1-Nombres_et_calculs]  # P1-Nombres_et_calculs contain updated files

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions