Very good point.
The error I am getting when debug is on is that it can't open the remote directory to write to it. -- This is puzzling, because I can sftp to the directory and send the files by hand.
I am logged in locally to the machine to look at it. I have tried opening the directory with $sftp->open($path) but nothing from a remote standpoint seems to work.
I didn't know about the psftp but will try it. Thanks.