Skip to content

Commit

Permalink
Accomodate default db_url in upgrade-master
Browse files Browse the repository at this point in the history
Fixes #1960.
  • Loading branch information
djmitche committed May 14, 2011
1 parent 992cd82 commit 05218fb
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion master/buildbot/scripts/runner.py
Expand Up @@ -379,7 +379,8 @@ def check_master_cfg(self, expected_db_url=None):
d = defer.maybeDeferred(lambda :
m.loadConfig(open(master_cfg, "r"), checkOnly=True))
def check_db_url(config):
if expected_db_url and config['db_url'] != expected_db_url:
if (expected_db_url and
config.get('db_url', 'sqlite:///state.sqlite') != expected_db_url):
raise ValueError("c['db_url'] in the config file ('%s') does"
" not match '%s'; please edit the configuration"
" file before upgrading." %
Expand Down

0 comments on commit 05218fb

Please sign in to comment.