Python Forum

Full Version: pysftp pop-up 'Client forking'
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Running Python 2.7.15rc1 (default, Nov 12 2018, 14:31:15) on Linux Mint

I am trying to use pysftp, the test code
#!/usr/bin/python

# test_remote.py
# to test connections to a remote machine

import subprocess
import pysftp

with pysftp.Connection('pi', username='pi', password='raspberry') as sftp:
    out=sftp.execute('ls')
    print out
    
works but when it runs I get a pop-up
Client forking
Select the fork branch to follow
There is a drop down with options 'Parent Process' and 'Child Process'
What does it mean and how can I avoid this? My code will run in the background so I really don't want pop-up boxes.

Thanks
Mick
example shows different commands for execution (put and get):
mport pysftp

with pysftp.Connection('hostname', username='me', password='secret') as sftp:
    with sftp.cd('public'):             # temporarily chdir to public
        sftp.put('/my/local/filename')  # upload file to public/ on remote
        sftp.get('remote_file')         # get a remote file
I just tried you code and I still get the pop-up box. Why? Do you get the pop-up when you run it or is there something odd about my setup?
Quote:Why? Do you get the pop-up when you run it or is there something odd about my setup?
I cannot run it as I don't have it installed

The code is from the homepage: https://bitbucket.org/dundeemt/pysftp
and a cookbook here: https://pysftp.readthedocs.io/en/release...kbook.html

you of course have to substitute data pertinent to your application.
Yes I realise that, I did put my values it and it works, but when it runs I get the pop-up box first, hit enter and then I get the result. With the pop-up it is completely useless to me.

Does anyone use pysftp?
Only other suggestion I have is to look through issues list: https://bitbucket.org/dundeemt/pysftp/is...tatus=open