I need to find the latest created file in a FTP folder. However the FTP server is not returning full timestamps for files with the LIST command (missing the year):
drwxr-xr-x 2 owner group 0 Nov 9 17:29 archive
drwxr-xr-x 2 owner group 0 Nov 9 17:35 category
drwxr-xr-x 2 owner group 0 Jan 9 07:21 images
And the MLSD command is not supported.
So currently I check the timestamp of each file with the MDTM command. Is there a more efficient way?
I am using the ftplib wrapper.