I am having the same issue, the process exits with code 1 or 3.
This is what I currently have
WinSCP Version 5.13.1 (Build 8265) (OS 6.1.7601 Service Pack 1 - Windows Server 2008 R2 Datacenter)
I am getting directly connection failed with no extra information about why it is failing.
Things I have tried
-Restarted the application
-run from command line with the same parameters(THIS WORKS)
I assume that when you run the script "from command line", you are using a different local account. Make sure that the account "xxxx\xxxx$" (from the log) has network connectivity allowed.