Bug 209407 - mock doesn't honour use_cache in a config file
mock doesn't honour use_cache in a config file
Status: CLOSED NEXTRELEASE
Product: Fedora Hosted Projects
Classification: Retired
Component: mock (Show other bugs)
unspecified
All Linux
medium Severity medium
: ---
: ---
Assigned To: Clark Williams
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2006-10-05 05:11 EDT by Matthew Booth
Modified: 2013-01-09 23:06 EST (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2006-11-21 15:21:12 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 Matthew Booth 2006-10-05 05:11:45 EDT
Description of problem:
Put the following line in a configuration file:

config_opts['use_cache'] = True

Run 'mock init'

Note that mock didn't use the cache.

My python is very weak, but to my untrained eye it looks like the default value
of False for the --autocache command line option overrides the config file even
when it's not specified.

Version-Release number of selected component (if applicable):
mock-0.6.5-1
Comment 1 Clark Williams 2006-10-05 11:33:04 EDT
I believe you are correct (that the command line option default is overriding
the config file). It may be that we need to default things like this to None, so
that we don't override something that didn't have a command line value. 

Comment 2 Clark Williams 2006-11-21 15:21:12 EST
modified set_config_opts_per_cmdline() to be more intelligent about overriding
defaults with commandline values. 

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