Hi All,
There are some files put in a ftp location.
I am able to connect, see the files and download in local successfully with below code written in Python3.6-
But I am not able to find a way to achieve this.
Can anyone please help me how to do it?
Thanks!
There are some files put in a ftp location.
I am able to connect, see the files and download in local successfully with below code written in Python3.6-
import ftplib server = ftplib.FTP() server.connect('HOST', PORT) server.login('USER_NAME','PASSWORD') server.dir() server.retrbinary("RETR " + 'xyz.csv' ,open('xyz.csv', 'wb').write) server.quit()I need to know the last modified time of a file in that ftp location so that if file is updated I can proceed with my other code.
But I am not able to find a way to achieve this.
Can anyone please help me how to do it?
Thanks!