Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 106004 - catalyst handles --livecd/empty config option incorrectly
Summary: catalyst handles --livecd/empty config option incorrectly
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Gentoo Catalyst Developers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-09-14 14:18 UTC by Jason Pepas
Modified: 2005-12-20 09:16 UTC (History)
0 users

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jason Pepas 2005-09-14 14:18:37 UTC
In livecd_stage2_target.py, in the clean function, it appears the function is
expecting self.settings["livecd/empty"] to be a string consisting of only one
path, or to already be a python list of strings representing paths.  However,
nothing else comes in the chain of events previous to this point which would
convert the string to a python list.

Reproducible: Always
Steps to Reproduce:
1. catalyst --cli --livecd/empty="/usr/share/info /usr/share/man"

Actual Results:  
the following output:

/usr/share/info /usr/share/man not a directory or does not exist, skipping
'empty' operation.


The fix is simple.  When detecting if the value is a string, the resulting
action should be to split the string into a list of strings, rather than simply
convert it to a list of one string.

Change line 152 of livecd_stage2_target.py to the following:

self.settings["livecd/empty"]=self.settings["livecd/empty"].split()
Comment 1 Chris Gianelloni (RETIRED) gentoo-dev 2005-09-15 05:22:05 UTC
Catalyst in CVS is quite a bit different from catalyst 1.x, so I'll need to
locate where this actually is and make the changes.  It looks like it is in
generic_stage_target.py, since both livecd-stage2 and the stage4 target can
perform an empty operation.

rocket:  What do you think?
Comment 2 Eric Edgar (RETIRED) gentoo-dev 2005-11-17 14:55:39 UTC
catalyst2 -a -f /2.6.14-new/specs_and_scripts/ppc64-livecd-stage2-minimal.spec -
-cli livecd/empty="/usr/share/info /usr/share/man"

Running action sequence: empty
Emptying directory /usr/share/info
Emptying directory /usr/share/man


This works in catalyst2
Comment 3 Chris Gianelloni (RETIRED) gentoo-dev 2005-12-20 09:16:43 UTC
Since the catalyst 2.0_rc* series is no longer in package.mask, I am marking this one as RESOLVED...