This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author blueyed
Recipients Segev Finer, blueyed
Date 2019-05-16.10:11:02
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1558001462.41.0.124903539602.issue31078@roundup.psfhosted.org>
In-reply-to
Content
It was added in 477c8d5e702 (a huge svn merge commit), with this reference:


      r45955 | georg.brandl | 2006-05-10 19:13:20 +0200 (Wed, 10 May 2006) | 4 lines

      Patch #721464: pdb.Pdb instances can now be given explicit stdin and
      stdout arguments, making it possible to redirect input and output
      for remote debugging.

I think a good alternative patch might be:

```diff
 Lib/pdb.py | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git i/Lib/pdb.py w/Lib/pdb.py
index f5d33c27fc..daf49b3629 100755
--- i/Lib/pdb.py
+++ w/Lib/pdb.py
@@ -141,7 +141,9 @@ def __init__(self, completekey='tab', stdin=None, stdout=None, skip=None,
                  nosigint=False, readrc=True):
         bdb.Bdb.__init__(self, skip=skip)
         cmd.Cmd.__init__(self, completekey, stdin, stdout)
-        if stdout:
+        if stdout and stdout is not sys.stdout:
+            # stdout gets passed with do_debug for example, but should usually
+            # not disable using raw input then.
             self.use_rawinput = 0
         self.prompt = '(Pdb) '
         self.aliases = {}
```
History
Date User Action Args
2019-05-16 10:11:02blueyedsetrecipients: + blueyed, Segev Finer
2019-05-16 10:11:02blueyedsetmessageid: <1558001462.41.0.124903539602.issue31078@roundup.psfhosted.org>
2019-05-16 10:11:02blueyedlinkissue31078 messages
2019-05-16 10:11:02blueyedcreate