diff options
| author | Michael Vogt <michael.vogt@ubuntu.com> | 2009-05-05 11:09:26 +0200 |
|---|---|---|
| committer | Michael Vogt <michael.vogt@ubuntu.com> | 2009-05-05 11:09:26 +0200 |
| commit | 51c60cb3447247188bb8bf5c82b53e5199878b36 (patch) | |
| tree | 5f3d6ff39d06199a0423913284149fb6e59436d5 /doc/examples/progress.py | |
| parent | b08e026fea9ed453d2cbaaa402fe1bd17c6242dd (diff) | |
| parent | 23d29169c30b2f05a0c2943832a7cf7288ff5802 (diff) | |
| download | python-apt-51c60cb3447247188bb8bf5c82b53e5199878b36.tar.gz | |
merge from the debian-unstable tree
Diffstat (limited to 'doc/examples/progress.py')
| -rw-r--r-- | doc/examples/progress.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/doc/examples/progress.py b/doc/examples/progress.py index 304bd117..2231001f 100644 --- a/doc/examples/progress.py +++ b/doc/examples/progress.py @@ -40,7 +40,7 @@ class TextFetchProgress(apt.FetchProgress): def pulse(self): print "Pulse: CPS: %s/s; Bytes: %s/%s; Item: %s/%s" % ( - apt.SizeToStr(self.currentCPS), SizeToStr(self.currentBytes), + apt.SizeToStr(self.currentCPS), apt.SizeToStr(self.currentBytes), apt.SizeToStr(self.totalBytes), self.currentItems, self.totalItems) return True @@ -81,12 +81,12 @@ class TextCdromProgress(apt.CdromProgress): def update(self, text, step): # check if we actually have some text to display if text != "": - print "Update: %s %s" % (string.strip(text), step) + print "Update: %s %s" % (text.strip(), step) def askCdromName(self): print "Please enter cd-name: ", cd_name = sys.stdin.readline() - return (True, string.strip(cd_name)) + return (True, cd_name.strip()) def changeCdrom(self): print "Please insert cdrom and press <ENTER>" |
