diff options
author | Fred Drake <fdrake@acm.org> | 2001-12-05 22:37:21 (GMT) |
---|---|---|
committer | Fred Drake <fdrake@acm.org> | 2001-12-05 22:37:21 (GMT) |
commit | a16433b14edc4d4c08c97262609a3e8821ff1f6e (patch) | |
tree | 943d75b5f167216b72f6db6f7a506cec4482b7d5 /Lib | |
parent | 3127c28b3fa0239900b5c56f42139f1b60dac631 (diff) | |
download | cpython-a16433b14edc4d4c08c97262609a3e8821ff1f6e.zip cpython-a16433b14edc4d4c08c97262609a3e8821ff1f6e.tar.gz cpython-a16433b14edc4d4c08c97262609a3e8821ff1f6e.tar.bz2 |
Re-enabled debugging prints in poplib & documented the set_debuglevel()
method.
This closes SF patch #486079.
Diffstat (limited to 'Lib')
-rw-r--r-- | Lib/poplib.py | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/Lib/poplib.py b/Lib/poplib.py index cb3e004..23c0b46 100644 --- a/Lib/poplib.py +++ b/Lib/poplib.py @@ -96,14 +96,14 @@ class POP3: def _putline(self, line): - #if self._debugging > 1: print '*put*', `line` + if self._debugging > 1: print '*put*', `line` self.sock.send('%s%s' % (line, CRLF)) # Internal: send one command to the server (through _putline()) def _putcmd(self, line): - #if self._debugging: print '*cmd*', `line` + if self._debugging: print '*cmd*', `line` self._putline(line) @@ -113,7 +113,7 @@ class POP3: def _getline(self): line = self.file.readline() - #if self._debugging > 1: print '*get*', `line` + if self._debugging > 1: print '*get*', `line` if not line: raise error_proto('-ERR EOF') octets = len(line) # server can send any combination of CR & LF @@ -131,7 +131,7 @@ class POP3: def _getresp(self): resp, o = self._getline() - #if self._debugging > 1: print '*resp*', `resp` + if self._debugging > 1: print '*resp*', `resp` c = resp[:1] if c != '+': raise error_proto(resp) @@ -205,7 +205,7 @@ class POP3: """ retval = self._shortcmd('STAT') rets = retval.split() - #if self._debugging: print '*stat*', `rets` + if self._debugging: print '*stat*', `rets` numMessages = int(rets[1]) sizeMessages = int(rets[2]) return (numMessages, sizeMessages) |