Bug 517289

Summary: [PATCH] Fix virt-manager addhardware.py hostdev error handling
Product: [Fedora] Fedora Reporter: Paul W. Frields <stickster>
Component: virt-managerAssignee: Daniel Berrangé <berrange>
Status: CLOSED RAWHIDE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: high    
Version: 11CC: berrange, clalance, crobinso, hbrock, itamar, markmc, veillard, virt-maint
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2009-09-14 16:05:41 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 480594    
Attachments:
Description Flags
Patch for gettext problem none

Description Paul W. Frields 2009-08-13 11:48:26 UTC
Created attachment 357305 [details]
Patch for gettext problem

libvirt-0.6.2-13.fc11

When trying to add a piece of hardware that's invalid (such as an iPhone via USB), virt-manager generates a traceback instead of an error dialog.  The attached patch fixes the problem.

Traceback (most recent call last):
  File "/usr/share/virt-manager/virtManager/addhardware.py", line 288, in forward
    if(self.validate(notebook.get_current_page()) != True):
  File "/usr/share/virt-manager/virtManager/addhardware.py", line 966, in validate
    str(e)))
TypeError: gettext() takes exactly 2 arguments (3 given)

Comment 1 Daniel Veillard 2009-08-13 11:58:34 UTC
Thanks for the patch but it looks like a fix fir virt-manager :-)

Daniel

Comment 2 Mark McLoughlin 2009-08-14 18:45:56 UTC
Patch looks good to me and is needed upstream/F-12 as well as F-11

Comment 3 Cole Robinson 2009-09-14 16:05:41 UTC
Thanks for the patch, applied upstream:

http://hg.et.redhat.com/cgi-bin/hg-virt.cgi/applications/virt-manager--devel/rev/d34def55dbd7

Fixed in virt-manager-0.8.0-3.fc12