Closed Kirill888 closed 1 week ago
mv ~/.datacube.conf datacube.conf.bk touch ~/.datacube.conf datacube system check
datacube system check fails with traceback.
datacube system check
in the notebook, traceback is more clear, self.raw_config is None but is being iterated over.
self.raw_config is None
File ~/.envs/emit/lib/python3.10/site-packages/datacube/cfg/api.py:121, in ODCConfig.__init__(self, paths, raw_dict, text) 118 self.raw_config = parse_text(cast(str, self.raw_text)) 120 self._aliases: dict[str, str] = {} --> 121 self.known_environments: dict[str, ODCEnvironment] = { 122 section: ODCEnvironment(self, section, self.raw_config[section], self.allow_envvar_overrides) 123 for section in self.raw_config 124 } 125 self.canonical_names: dict[str, list[str]] = {} 126 for alias, canonical in self._aliases.items(): TypeError: 'NoneType' object is not iterable
that's on develop-1.9 branch, just create .datacube.conf file without any data in it.
develop-1.9
.datacube.conf
Ah, yes. A blank config should parse as an empty dict {} - good catch.
{}
Expected behaviour
Actual behaviour
datacube system check
fails with traceback.in the notebook, traceback is more clear,
self.raw_config is None
but is being iterated over.Steps to reproduce the behaviour
that's on
develop-1.9
branch, just create.datacube.conf
file without any data in it.