A missing basedir should cause an error if we try to read the config. refs #1971

Signed-off-by: Daira Hopwood <david-sarah@jacaranda.org>
This commit is contained in:
Daira Hopwood 2013-05-17 20:47:42 +01:00 committed by Daira Hopwood
parent 11087d6dfa
commit 5800e5e5b2
1 changed files with 2 additions and 0 deletions

View File

@ -109,6 +109,8 @@ class ConfigMixin:
except EnvironmentError:
if os.path.exists(tahoe_cfg):
raise
if not os.path.isdir(self.basedir):
raise MissingConfigEntry("%s is missing or not a directory." % quote_output(self.basedir))
def error_about_old_config_files(self):
""" If any old configuration files are detected, raise OldConfigError. """