Dec-23-2021, 12:22 PM
Hello,
I have a stange problem
I'm using this simple code:
O get this error:
the file is test.txt size 1 kb , there is more then 100MB free in the remote device
what could be the reason for the error? why the file isn't been upload ?
I have a stange problem
I'm using this simple code:
ftp = FTP('10.0.0.1', timeout=60) try: ftp.login(user='user', passwd='pass') except error_perm as msg: print(f"FTP error: {msg}") # return "Wrong User or Password" except Exception as e1: print(e1) print("Error in FTP Login!") # return "Unknown Error" else: try: file_to_upload = open(filename, 'rb') ftp.storbinary('STOR test.txt', file_to_upload) UploadOk = "OK" return "FTP success" except Exception as e: print('my error') print(e) UploadOk = "Problem" return "FTP Error " + str(e) finally: print("status " + UploadOk) file_to_upload.close() ftp.close()I can see a FTP session is made , but the file won't uplaod
O get this error:
FTP Error [WinError 10060] A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respondwhen I ty to upload to another device (the same file, same code) everything is working - so I know the code\file is OK
the file is test.txt size 1 kb , there is more then 100MB free in the remote device
what could be the reason for the error? why the file isn't been upload ?