Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 231202 - yum shell crashes with 'config exclude'
Summary: yum shell crashes with 'config exclude'
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: yum
Version: 6
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Jeremy Katz
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2007-03-06 19:02 UTC by Carl Roth
Modified: 2014-01-21 22:57 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2007-03-07 22:09:05 UTC


Attachments (Terms of Use)

Description Carl Roth 2007-03-06 19:02:17 UTC
Description of problem:

If you use the 'config exclude' command after the yum shell has initialized (via
'install' or 'exclude) then the yum shell process crashes:

See the following command trace:

[1.2] (roth@theo:pts/7) $ sudo yum shell
...
Setting up Yum Shell
> upgrade
Setting up Upgrade Process
Setting up repositories
...
> config exclude kernel*
Traceback (most recent call last):
  File "/usr/bin/yum", line 29, in ?
    yummain.main(sys.argv[1:])
  File "/usr/share/yum-cli/yummain.py", line 94, in main
    result, resultmsgs = base.doCommands()
  File "/usr/share/yum-cli/cli.py", line 356, in doCommands
    return self.yum_cli_commands[self.basecmd].doCommand(self, self.basecmd,
self.extcmds)
  File "/usr/share/yum-cli/yumcommands.py", line 397, in doCommand
    return base.doShell()
  File "/usr/share/yum-cli/cli.py", line 334, in doShell
    yumshell.cmdloop()
  File "/usr/lib/python2.4/cmd.py", line 142, in cmdloop
    stop = self.onecmd(line)
  File "/usr/lib/python2.4/cmd.py", line 219, in onecmd
    return func(arg)
  File "/usr/share/yum-cli/shell.py", line 227, in do_config
    self.base.repos._selectSackType()
AttributeError: RepoStorage instance has no attribute '_selectSackType'

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

yum-3.0.3-1.fc6

How reproducible:

always

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


Expected results:


Additional info:

The 'config exclude' command works as long as it's invoked *before* the
'upgrade' command.  This is somewhat annoying, since a common use case for 'yum
shell' is as follows:

  > upgrade
  > ts list
  OOPS, I don't want that package to be updated
  > ts reset
  > config exclude SOME-PACKAGE
  > upgrade
  > ts run

Comment 1 Jeremy Katz 2007-03-07 22:09:05 UTC
Wow, that's been broken for a while and no one had noticed before now.  You can
fix it by just removing the calls to _selectSackType in
/usr/share/yum-cli/shell.py.  And I've committed the fix to upstream CVS


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