0

I have a Python script which is called to download certain data from database. I have a download button, when pressed a cmd window uses Plink opens up and show the progress and status inside this cmd window. After sometime the cmd window closes off very quickly automatically. How to stop it from closing (want this cmd window to be open until we close it) so that we can see the current status of download operation.

Martin Prikryl
  • 188,800
  • 56
  • 490
  • 992
Arun
  • 3
  • 6

1 Answers1

0

Run something in the console window that pauses at the end.

Most trivial approach is to replace the direct plink call with cmd call that runs plink and pause:

cmd /c plink user@host command & pause

For ultimate control, do run your own Python script in the new console window. That way you can implement any kind of pause you want. You can even replace the plink call with native SSH Python code:
Perform commands over ssh with Python

Martin Prikryl
  • 188,800
  • 56
  • 490
  • 992