Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 101897 - installer-dialog goes boom when selecting packages to install
Summary: installer-dialog goes boom when selecting packages to install
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Release Media
Classification: Unclassified
Component: Installer (show other bugs)
Hardware: x86 Linux
: High normal
Assignee: Gentoo Linux Installer
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-08-09 13:02 UTC by Simon Stelling (RETIRED)
Modified: 2006-03-24 13:46 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
installer.log (installer.log,2.90 KB, text/plain)
2005-08-09 13:03 UTC, Simon Stelling (RETIRED)
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Simon Stelling (RETIRED) gentoo-dev 2005-08-09 13:02:43 UTC
when playing around with installer-dialog (on the livecd), it crashed in the
dialog "choose from the listed packages" i did it twice, and it didn't crash the
first time

Traceback (most recent call last):
  File "./gli-dialog.py", line 215, in ?
    gen_install_profile = Setup_InstallProfile(client_profile, install_profile,
local_install, advanced_mode)
  File "./gli-dialog.py", line 48, in __init__
    self.set_extra_packages()
  File "/opt/installer/GLIGenDialog.py", line 1001, in set_extra_packages
    install_packages.append(package)
AttributeError: 'str' object has no attribute 'append'

i'll attach installer.log
Comment 1 Simon Stelling (RETIRED) gentoo-dev 2005-08-09 13:03:27 UTC
Created attachment 65552 [details]
installer.log
Comment 2 Simon Stelling (RETIRED) gentoo-dev 2005-08-09 13:09:29 UTC
Comment on attachment 65552 [details]
installer.log

sorry, it's not related to this bug
Comment 3 Andrew Gaffney (RETIRED) gentoo-dev 2005-08-09 13:18:02 UTC
fixed in cvs
Comment 4 Preston Cody (RETIRED) gentoo-dev 2005-08-09 16:12:30 UTC
Thx fer the fix while I'm on vacation Andrew. :) much appreciated.  now back 
to my rum and sunset.  Can you send me an email telling me how serious this 
bug actually was and what the details causing it were?
Comment 5 Andrew Gaffney (RETIRED) gentoo-dev 2005-08-09 17:23:55 UTC
The first fix was for pulling existing values from the IP. You were pulling it
as a string but operating on it like it was a list. I added:

 			install_packages = self._install_profile.get_install_packages()
+			if isinstance(install_packages, (list, tuple)):
+				install_packages = install_packages.split()

I just found another problem with that function when testing the first fix. In
the "Manual" section, you don't check the value of 'code' and you assign the
return value from checklist() directly to install_packages. I changed it to use
a temp variable to grab the return and then assign that to install_packages in
an if block.

 			elif submenu == _(u"Manual"):
-				code, install_packages = self._d.inputbox(_(u"Enter a space-separated list
of extra packages to install on the system"), init=string.join(install_packages,
' '), width=70) 
+				code, tmp_install_packages = self._d.inputbox(_(u"Enter a space-separated
list of extra packages to install on the system"),
init=string.join(install_packages, ' '), width=70)
+				if code == self._DLG_OK:
+					install_packages = tmp_install_packages.split()
 				continue
Comment 6 Andrew Gaffney (RETIRED) gentoo-dev 2005-08-09 17:27:02 UTC
Actually, that first fix was wrong. It should check for
isinstance(install_packages, str). *Now* it works :)
Comment 7 Jeffrey Forman (RETIRED) gentoo-dev 2006-03-24 13:46:30 UTC
Moving to Release Media/Installer.