Skip to content

Commit 0082c27

Browse files
committed
bubble up error for missing .readthedocs.yml if explicitly configured
1 parent e963fb0 commit 0082c27

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

readthedocs/config/config.py

+3-1
Original file line numberDiff line numberDiff line change
@@ -1380,7 +1380,9 @@ def load(path, env_config, config_file=None):
13801380
if config_file is None or config_file == '':
13811381
filename = find_one(path, CONFIG_FILENAME_REGEX)
13821382
else:
1383-
filename = "/".join([path, config_file])
1383+
filename = os.path.join(path, config_file)
1384+
if not os.path.exists(filename):
1385+
raise ConfigError(f".readthedocs.yml not found at {config_file}", CONFIG_FILE_REQUIRED)
13841386

13851387
if not filename:
13861388
raise ConfigFileNotFound(path)

0 commit comments

Comments
 (0)