Add a bit more feedback for missing lists

This commit is contained in:
Adam Goldsmith 2022-12-25 02:12:08 -05:00
parent 056a2993de
commit 2daf2c00b8

View File

@ -42,9 +42,11 @@ def main(mailman_bin: Path, api: str, token: str, list_suffix: str):
).stdout.split(b"\n") ).stdout.split(b"\n")
certification_lists = r.json() certification_lists = r.json()
for name, members in certification_lists.items(): for name, members in certification_lists.items():
print(name, "\n".join(members)) list_name = name + list_suffix
if name + list_suffix in existing_lists: if list_name in existing_lists:
sync_members(mailman_bin, name, members) sync_members(mailman_bin, name, members)
else:
print(f"Skipping {list_name}, as it does not exist in Mailman")
if __name__ == "__main__": if __name__ == "__main__":