Bug 623151 - Cancel in stage 2 network enablement dialog leads to traceback
Cancel in stage 2 network enablement dialog leads to traceback
Status: CLOSED CURRENTRELEASE
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: anaconda (Show other bugs)
6.0
All Linux
low Severity medium
: rc
: ---
Assigned To: Radek Vykydal
Release Test Team
: RHELNAK
Depends On: 623017
Blocks:
  Show dependency treegraph
 
Reported: 2010-08-11 09:12 EDT by Radek Vykydal
Modified: 2010-11-10 14:52 EST (History)
8 users (show)

See Also:
Fixed In Version: anaconda-13.21.75-1
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: 623017
Environment:
Last Closed: 2010-11-10 14:52:53 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Radek Vykydal 2010-08-11 09:12:42 EDT
+++ This bug was initially created as a clone of Bug #623017 +++

Description of problem:
If in Fedora 14 Alpha RC2 x86_64 you try to activate additional repositories you're asked to setup a network connection. I tried wlan0 first and failed (probably PEBKAC), then tried eth0 and failed (probably HW issue). So I canceled setting up the network and ended with an error popup which let me exit or debug. That got me the following message:
/usr/lib64/python2.7/site-packages/pyanaconda/iw/network_gui.py(194)selectInstallNetDeviceDialog()


Version-Release number of selected component (if applicable):
- anaconda 14.15
- whatever is on the F14 Alpha RC2 DVD

How reproducible:
Not tried

Steps to Reproduce:
1. Go through the installation
2. Select the update repo
3. Try to activate wlan0 and fail (like wrong WPA2 passphrase) and cancel that
4. Try to activate eth0 and fail (like no cable or no ip from dhcp) and cancel that
5. Cancel network activation
  
Actual results:
Error popup to exit or debug

Expected results:
Updates repo deselected, being able to continue installation

Additional info:
After I chose debug and got that message in the tty, I was able to continue the installation.

--- Additional comment from rvykydal@redhat.com on 2010-08-11 07:22:13 EDT ---

Created an attachment (id=438160)
screenshot of the traceback

--- Additional comment from rvykydal@redhat.com on 2010-08-11 07:45:08 EDT ---

Created an attachment (id=438165)
cancel -> traceback

Thanks for the report.

The bug (traceback) can occurs when choosing [Cancel] in device selection dialog of stage 2 network enablement (see the screenshot).

Sending patch for review.

--- Additional comment from rvykydal@redhat.com on 2010-08-11 08:48:56 EDT ---

Created an attachment (id=438179)
the second traceback

After fixing the first traceback, second one (attached) occurs. This one is caused by the fact that we don't disable/remove temporarily added repo after failed network enablement, so next try ([Ok] in Edir Repository dialog) leads to duplicate repos error which manifests itself with the traceback instead of error message because bug #623080.

I am going to send a patch fixing also this issue in scope of this bug to anaconda-devel-list.
Comment 2 RHEL Product and Program Management 2010-08-11 09:38:32 EDT
This issue has been proposed when we are only considering blocker
issues in the current Red Hat Enterprise Linux release.

** If you would still like this issue considered for the current
release, ask your support representative to file as a blocker on
your behalf. Otherwise ask that it be considered for the next
Red Hat Enterprise Linux release. **
Comment 3 Radek Vykydal 2010-08-11 10:58:25 EDT
For rhel, I want to address the two issues from original bug separately, so only the first traceback is relevant for this bug. The issue is:

Selecting [Cancel] in stage 2 network enablement dialog causes traceback

And this is the fix - should be safe and isolated:

diff --git a/iw/network_gui.py b/iw/network_gui.py
index ecd010b..4188cc5 100644
--- a/iw/network_gui.py
+++ b/iw/network_gui.py
@@ -185,7 +185,7 @@ def selectInstallNetDeviceDialog(network, devices = None):
     rc = dialog.run()
 
     if rc in [gtk.RESPONSE_CANCEL, gtk.RESPONSE_DELETE_EVENT]:
-        retval = None
+        install_device = None
     else:
         active = combo.get_active_iter()
         install_device = combo.get_model().get_value(active, 1)
Comment 5 Radek Vykydal 2010-08-12 10:38:38 EDT
Thanks Bill, should be fixed in anaconda-13.21.75-1.
Comment 7 Alexander Todorov 2010-08-20 06:56:34 EDT
Trying to reproduce this with the 0730.5 tree I did the following:

1) Start an install from http
2) After stage2 has started switch to tty2 and do
  - ifconfig eth0 down
  - rm /etc/sysconfig/network-scripts/ifcfg-eth0
3) Proceed with installation
4) Just before package selection anaconda pops up a dialog telling you that you have to activate networking and eth0 is preselected in this dialog.
5) Click Cancel on this dialog without trying to activate the network. The traceback below happens:

anaconda 13.21.66 exception report
Traceback (most recent call first):
  File "/usr/lib/anaconda/iw/network_gui.py", line 194, in selectInstallNetDeviceDialog
    return install_device
  File "/usr/lib/anaconda/gui.py", line 979, in enableNetwork
    nm_controlled_devices)
  File "/usr/lib/anaconda/yuminstall.py", line 1232, in doBackendSetup
    if not anaconda.intf.enableNetwork():
  File "/usr/lib/anaconda/backend.py", line 285, in doBackendSetup
    if anaconda.backend.doBackendSetup(anaconda) == DISPATCH_BACK:
  File "/usr/lib/anaconda/dispatch.py", line 208, in moveStep
    rc = stepFunc(self.anaconda)
  File "/usr/lib/anaconda/dispatch.py", line 126, in gotoNext
    self.moveStep()
  File "/usr/lib/anaconda/gui.py", line 1426, in setScreen
    self.anaconda.dispatch.gotoNext()
  File "/usr/lib/anaconda/gui.py", line 1339, in nextClicked
    self.setScreen ()
  File "/usr/lib/anaconda/gui.py", line 1476, in keyRelease
    self.nextClicked()
UnboundLocalError: local variable 'install_device' referenced before assignment
Comment 8 Alexander Todorov 2010-08-20 07:02:17 EDT
Just to clarify the traceback from comment #7 is the same as on the screenshot from the original bug report.

Now trying the same steps to reproduce with the 0818.0 tree I got the network activation dialog again. After clicking Cancel there's an error dialog:

Some of your repositories require networking, 
but there was an error enabling the network on your
system.

                 Exit Installer


Moving to VERIFIED.
Comment 9 releng-rhel@redhat.com 2010-11-10 14:52:53 EST
Red Hat Enterprise Linux 6.0 is now available and should resolve
the problem described in this bug report. This report is therefore being closed
with a resolution of CURRENTRELEASE. You may reopen this bug report if the
solution does not work for you.

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