Got that when hitting Ctrl-D('oh) instead of 'N'.
Transaction Summary
================================================================
Install 1 Package(s)
Update 0 Package(s)
Remove 0 Package(s)
Total download size: 1.2 M
Is this ok [y/N]: Traceback (most recent call last):
File "/usr/bin/yum", line 29, in ?
yummain.main(sys.argv[1:])
File "/usr/share/yum-cli/yummain.py", line 175, in main
base.doTransaction()
File "/usr/share/yum-cli/cli.py", line 655, in doTransaction
if not self.userconfirm():
File "/usr/share/yum-cli/output.py", line 117, in userconfirm
choice = raw_input('Is this ok [y/N]: ')
EOFError
Should this be fixed?: y
Thomas
Index: output.py
===================================================================
RCS file: /cvsroot/yum/cvs/yum/output.py,v
retrieving revision 1.76
diff -u -r1.76 output.py
--- output.py 21 Jan 2007 20:22:30 -0000 1.76
+++ output.py 24 Jan 2007 14:47:25 -0000
@@ -111,11 +111,14 @@
def userconfirm(self):
"""gets a yes or no from the user, defaults to No"""
- while True:
- choice = raw_input('Is this ok [y/N]: ')
- choice = choice.lower()
- if len(choice) == 0 or choice[0] in ['y', 'n']:
- break
+ while True:
+ try:
+ choice = raw_input('Is this ok [y/N]: ')
+ choice = choice.lower()
+ if len(choice) == 0 or choice[0] in ['y', 'n']:
+ break
+ except EOFError:
+ return False
if len(choice) == 0 or choice[0] != 'y':
return False
_______________________________________________
Yum-devel mailing list
[email protected]
https://lists.dulug.duke.edu/mailman/listinfo/yum-devel