Skip to content

Commit

Permalink
Merge 451b448 into 6d2939a
Browse files Browse the repository at this point in the history
  • Loading branch information
sphuber committed Nov 26, 2019
2 parents 6d2939a + 451b448 commit 30b3034
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions aiida/manage/configuration/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,12 +86,14 @@ def load_config(create=False):
from .config import Config
from .settings import AIIDA_CONFIG_FOLDER, DEFAULT_CONFIG_FILE_NAME

filepath = os.path.join(AIIDA_CONFIG_FOLDER, DEFAULT_CONFIG_FILE_NAME)

if IN_RT_DOC_MODE:
# The following is a dummy config.json configuration that it is used for the
# proper compilation of the documentation on readthedocs.
from aiida.manage.external.postgres import DEFAULT_DBINFO
return Config(
'/dev/null', {
filepath, {
'default_profile': 'default',
'profiles': {
'default': {
Expand All @@ -110,8 +112,6 @@ def load_config(create=False):
}
)

filepath = os.path.join(AIIDA_CONFIG_FOLDER, DEFAULT_CONFIG_FILE_NAME)

if not os.path.isfile(filepath) and not create:
raise exceptions.MissingConfigurationError('configuration file {} does not exist'.format(filepath))

Expand Down

0 comments on commit 30b3034

Please sign in to comment.