Fix validation for definition configs

This commit is contained in:
Anna Scholtz 2022-10-19 11:54:14 -07:00
Родитель a45df5b20b
Коммит 2919589b0f
1 изменённых файлов: 3 добавлений и 2 удалений

Просмотреть файл

@ -425,8 +425,9 @@ def validate_config(path: Iterable[os.PathLike], config_repos, private_config_re
experiment = experiments.with_slug(entity.slug)
monitor_entire_population = False
if "project" in entity.spec and entity.spec.project and entity.spec.project.population:
monitor_entire_population = entity.spec.project.population.monitor_entire_population
if config_file.parent.name != DEFINITIONS_DIR:
if entity.spec.project and entity.spec.project.population:
monitor_entire_population = entity.spec.project.population.monitor_entire_population
if config_file.parent.name != DEFINITIONS_DIR and config_file.parent.name != DEFAULTS_DIR:
if experiment is None and monitor_entire_population is False: