[yum-cvs] 3 commits - output.py
James Antill
james at linux.duke.edu
Thu Nov 29 17:00:38 UTC 2007
output.py | 13 ++++++++++++-
1 file changed, 12 insertions(+), 1 deletion(-)
New commits:
commit 8303d754bc727a070a2dcdc7a66d7da496508891
Merge: 0cfbfe3... cd19883...
Author: James Antill <james at and.org>
Date: Thu Nov 29 12:00:31 2007 -0500
Merge branch 'master' of ssh://login.linux.duke.edu/home/groups/yum/git/yum
* 'master' of ssh://login.linux.duke.edu/home/groups/yum/git/yum:
Fix copy/paste error
Packages that are to be removed can't be local packages.
Work around unreliable result of .update()
Add some remove test cases
Fix PackageSack.getProvides to also return files
Add ObsoletesChain and ObsoletesCircle test cases
Make the Update i386,x86_64 -> i386/x86_64 tests stop complaining
set default values for the FakePackage constructor
Move SimpleUpdateTests into an own module
Move SimpleObsoletesTests into an own module
Read test modules from file systeRead test modules from file systemm
Do arch checks for versioned obsoletes, too
commit 0cfbfe367c56dda4b8b22c2cff6efe50a38deca5
Author: James Antill <james at and.org>
Date: Thu Nov 29 12:00:14 2007 -0500
Give message on first C-c, so new user knows what is happening
diff --git a/output.py b/output.py
index 7073b89..af77759 100644
--- a/output.py
+++ b/output.py
@@ -558,8 +558,19 @@ Remove %5.5s Package(s)
@param cbobj: urlgrabber callback obj
'''
+ delta_exit_chk = 2.0 # Delta between C-c's so we treat as exit
+ delta_exit_str = "two" # Human readable version of above
+
now = time.time()
- if hasattr(self, '_last_interrupt') and now - self._last_interrupt < 2:
+
+ if not hasattr(self, '_last_interrupt'):
+ hibeg = self.term.MODE['bold']
+ hiend = self.term.MODE['normal']
+ msg = """
+ Current download cancelled, %sinterupt again%s within %s%s%s seconds to exit.
+""" % (hibeg, hiend, hibeg, delta_exit_str, hiend)
+ self.verbose_logger.log(logginglevels.INFO_2, msg)
+ elif now - self._last_interrupt < delta_exit_chk:
# Two quick CTRL-C's, quit
raise KeyboardInterrupt
commit 60564de9b02b70c957a1c8b27ca4ebdff8141025
Author: James Antill <james at and.org>
Date: Thu Nov 29 11:49:08 2007 -0500
Alter C-c urlgrabber mirror timeout to 2 seconds
diff --git a/output.py b/output.py
index a18ab96..7073b89 100644
--- a/output.py
+++ b/output.py
@@ -559,7 +559,7 @@ Remove %5.5s Package(s)
@param cbobj: urlgrabber callback obj
'''
now = time.time()
- if hasattr(self, '_last_interrupt') and now - self._last_interrupt < 0.2:
+ if hasattr(self, '_last_interrupt') and now - self._last_interrupt < 2:
# Two quick CTRL-C's, quit
raise KeyboardInterrupt
More information about the Yum-cvs-commits
mailing list