Red Hat Bugzilla – Bug 139462
yum doesnt fail gracefully on early user cancel
Last modified: 2014-01-21 17:50:46 EST
Description of problem:
I start a package installation through yum and cancel it immediately.
It fails with traceback
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. yum install package.
2. cancel using control+c immediately
yum -y gnome-panel
Traceback (most recent call last):
File "/usr/bin/yum", line 6, in ?
File "/usr/share/yum-cli/yummain.py", line 23, in ?
File "/usr/lib/python2.3/site-packages/yum/__init__.py", line 35, in ?
File "/usr/lib/python2.3/site-packages/yum/depsolve.py", line 30, in ?
File "/usr/lib/python2.3/site-packages/yum/packages.py", line 18, in ?
output: exit on user cancel
It does this correctly if cancelled after a minute or so
the main yum handler that captures the keyboard interrupt isn't loaded
at that time.
There's not much I can do.
I have no idea on the actual code but perhaps trying to load the
keyboard handing module or something as early as possible might help
I load it in /usr/bin/yum, now.
if you ctrl-c at that point it will try to catch it.
beyond that, not a lot I can do.
This is fixed in yum 2.1.12