FluentFTP: 39.0.1 regression: AutoConnect fails with Azure FTP servers
FTP OS: Windows
FTP Server: Azure
Computer OS: Windows 10
FluentFTP Version: 39.0.1
Framework: .NET 6
Using AutoConnect to connect to Azure App Service FTP servers (*.ftp.p.azurewebsites.windows.net) has started failing with 39.0.1 – times out. Guessing it’s related to the timeout changes?
Logs :
39.0.0:
# AutoConnectAsync()
# AutoDetectAsync(True, False)
# ConnectAsync()
Status: Connecting to ***:21
# ConnectAsync()
Status: Connecting to ***:990
Status: FTPS Authentication Successful
Status: Time to activate encryption: 0h 0m 0s. Total Seconds: 0.1797745.
Response: 220 Microsoft FTP Service
Status: Detected FTP server: WindowsServerIIS
39.0.1:
# AutoConnectAsync()
# AutoDetectAsync(True, False)
# ConnectAsync()
Status: Connecting to ***:21
System.TimeoutException: Timed out trying to connect!
This exception was originally thrown at this call stack:
FluentFTP.FtpSocketStream.ConnectAsync(string, int, FluentFTP.FtpIpVersion, System.Threading.CancellationToken)
System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(System.Threading.Tasks.Task)
System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(System.Threading.Tasks.Task)
FluentFTP.FtpClient.ConnectAsync(FluentFTP.FtpSocketStream, System.Threading.CancellationToken)
System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(System.Threading.Tasks.Task)
System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(System.Threading.Tasks.Task)
FluentFTP.FtpClient.ConnectAsync(System.Threading.CancellationToken)
System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
...
[Call Stack Truncated]
# Dispose()
Status: Disposing FtpClient object...
Status: Disposing FtpSocketStream...
About this issue
- Original URL
- State: closed
- Created 2 years ago
- Comments: 17 (11 by maintainers)
We have a winner!
Thanks for your help!
Thanks! It got much further, however it appears that it’s skipping calling ConnectAsync:
My exact code:
Your file attachment doesn’t appear to have uploaded fully?
Now complaining about profile.Credentials being null:
Looking at the code, it appears that both Credentials and Encoding are required but aren’t currently being set either.
Makes sense! I get a different exception with 39.0.2-beta1:
Looking at the code, that makes sense since GetWorkingProfileFromHost, which is now returning not-null for me due to your change, doesn’t set profile.Host. Unclear how that would have worked in the past for others though.