恢复代码

This commit is contained in:
gqh
2023-01-29 16:05:00 +08:00
parent a26d1ca2ba
commit a7edb142c8
8 changed files with 208 additions and 27 deletions

View File

@@ -45,6 +45,9 @@ class FtpController:
self.port = port
self.username = username
self.password = password
# 测试
print("==============================================")
print(self.username, self.port, self.host, self.password)
ftp = FTP_P()
# self.ftp.set_debuglevel(2) #打开调试级别2显示详细信息
ftp.set_pasv(0) # 0主动模式 1 #被动模式
@@ -68,7 +71,7 @@ class FtpController:
:param localpath:
:return:
"""
bufsize = 1024
bufsize = 8192
# fp = open(localpath, 'rb')
# self.ftp.storbinary('STOR ' + remotepath, fp, bufsize)
# fp.close()