Bug 955310 (TBf6c835f4) - TBf6c835f4 NCHardwareList.py:482:save:AttributeError: HwWireless instance has no attribute 'type'
Summary: TBf6c835f4 NCHardwareList.py:482:save:AttributeError: HwWireless instance has...
Keywords:
Status: CLOSED ERRATA
Alias: TBf6c835f4
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: system-config-network
Version: 5.9
Hardware: i686
OS: Unspecified
unspecified
urgent
Target Milestone: rc
: ---
Assignee: Harald Hoyer
QA Contact: Branislav Blaškovič
URL:
Whiteboard:
: 802100 803175 842423 1118594 (view as bug list)
Depends On:
Blocks: 1049888
TreeView+ depends on / blocked
 
Reported: 2013-04-22 18:35 UTC by AMBARNIL GHOSH
Modified: 2014-09-16 00:18 UTC (History)
8 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Due to a typo in the underlying source code, the system-config-network service was unable to configure anything else than Ethernet devices, which caused the service to terminate unexpectedly on any other hardware devices. With this update, the typo has been fixed and system-config-network no longer crashes in such a case.
Clone Of:
Environment:
Last Closed: 2014-09-16 00:18:13 UTC


Attachments (Terms of Use)
network config bug dump file ... from RHEL 5 (1.67 KB, text/plain)
2013-04-22 18:35 UTC, AMBARNIL GHOSH
no flags Details


Links
System ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2014:1195 normal SHIPPED_LIVE system-config-network bug fix update 2014-09-16 04:14:20 UTC

Description AMBARNIL GHOSH 2013-04-22 18:35:30 UTC
Created attachment 738615 [details]
network config bug dump file ... from RHEL 5

Description of problem:


Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1.
2.
3.
  
Actual results:


Expected results:


Additional info:

Comment 1 Harald Hoyer 2014-01-31 13:23:05 UTC
Component: system-config-network
Version: 1.3.99.21
Summary: TBf6c835f4 NCHardwareList.py:482:save:AttributeError: HwWireless instance has no attribute 'type'

Traceback (most recent call last):
  File "/usr/share/system-config-network/netconfpkg/gui/maindialog.py", line 696, in on_Dialog_delete_event
    self.save()
  File "/usr/share/system-config-network/netconfpkg/gui/maindialog.py", line 370, in save
    self.saveHardware()
  File "/usr/share/system-config-network/netconfpkg/gui/maindialog.py", line 398, in saveHardware
    hardwarelist.save()
  File "/usr/share/system-config-network/netconfpkg/NCHardwareList.py", line 482, in save
    if (hw.Type == ETHERNET or \
AttributeError: HwWireless instance has no attribute 'type'

Local variables in innermost frame:
self: HardwareList.Wireless.wlan0.Status=system
HardwareList.Wireless.wlan0.Name=wlan0
HardwareList.Wireless.wlan0.Type=Wireless
HardwareList.Wireless.wlan0.Card.ModuleName=rt61pci
HardwareList.Wireless.wlan0.Description=Ralink corp. RT2561/RT61 rev B 802.11g
HardwareList.Ethernet.eth0.Status=system
HardwareList.Ethernet.eth0.Name=eth0
HardwareList.Ethernet.eth0.Type=Ethernet
HardwareList.Ethernet.eth0.Card.ModuleName=forcedeth
HardwareList.Ethernet.eth0.Description=NVIDIA Corporation MCP51 Ethernet Controller

modules: <netconfpkg.NCHardwareList.MyConfModules instance at 0x95aab4c>
hw: Hardware.Status=system
Hardware.Name=wlan0
Hardware.Type=Wireless
Hardware.Card.ModuleName=rt61pci
Hardware.Description=Ralink corp. RT2561/RT61 rev B 802.11g

wvdial: <rhpl.ConfSMB.ConfSMB instance at 0x97c118c>
type: Ethernet
isdn: <netconfpkg.NCisdnhardware.ConfISDN instance at 0x97c104c>
mod: eth0

Comment 2 Harald Hoyer 2014-01-31 13:24:07 UTC
*** Bug 803175 has been marked as a duplicate of this bug. ***

Comment 3 Harald Hoyer 2014-01-31 13:24:18 UTC
*** Bug 842423 has been marked as a duplicate of this bug. ***

Comment 4 Harald Hoyer 2014-01-31 14:10:47 UTC
*** Bug 802100 has been marked as a duplicate of this bug. ***

Comment 8 Harald Hoyer 2014-03-12 10:39:39 UTC
Proposed fix for this typo.

diff --git a/src/netconfpkg/NCHardwareList.py b/src/netconfpkg/NCHardwareList.py
index 2f44162..8e3c42b 100644
--- a/src/netconfpkg/NCHardwareList.py
+++ b/src/netconfpkg/NCHardwareList.py
@@ -482,7 +482,7 @@ class HardwareList(HardwareList_base):
                 if (hw.Type == ETHERNET or \
                     hw.Type == TOKENRING or \
                         hw.Type == QETH or \
-                        hw.type == LCS) and \
+                        hw.Type == LCS) and \
                         hw.Name == mod:
                     break
             else:

Comment 11 Branislav Blaškovič 2014-05-14 13:23:48 UTC
I have not suitable HW.

But:

/usr/share/system-config-network/netconfpkg/NCHardwareList.py from line 482:

                if (hw.Type == ETHERNET or \
                    hw.Type == TOKENRING or \
                        hw.Type == QETH or \
                        hw.Type == LCS) and \
                        hw.Name == mod:
                    break

I can see upper case 'T' in 'Type' so it is fixed.

Testing with: system-config-network-tui-1.3.99.22-1.el5

Comment 12 Harald Hoyer 2014-08-18 08:50:01 UTC
*** Bug 1118594 has been marked as a duplicate of this bug. ***

Comment 14 errata-xmlrpc 2014-09-16 00:18:13 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHBA-2014-1195.html


Note You need to log in before you can comment on or make changes to this bug.