def update(args: argparse.Namespace) -> None:
v = Verification()
config = configparser.ConfigParser()
- exprs = {}
+ exprs: Dict[str, str] = {}
configs = [read_config(filename) for filename in args.channels_file]
for config in configs:
for section in config.sections():
ensure_git_rev_available(v, channel)
tarball = git_get_tarball(v, channel)
+ if section in exprs:
+ raise Exception('Duplicate channel "%s"' % section)
exprs[section] = (
'f: f { name = "%s"; channelName = "%%s"; src = builtins.storePath "%s"; }' %
(config[section]['release_name'], tarball))
for config in configs:
for section in config.sections():
if 'alias_of' in config[section]:
+ if section in exprs:
+ raise Exception('Duplicate channel "%s"' % section)
exprs[section] = exprs[str(config[section]['alias_of'])]
command = [