issue importer: list issues that are *not* closed when finding existing issues

Turns out also, you cannot set the queue to 0 with any success. So we
really should just like, prevent notifications in forgejo itself.

Filed a bug for that:
lix-project/web-services#38

Change-Id: Ib96749f3159659182904963cab7b2ef88fc64442
This commit is contained in:
jade 2024-03-18 18:13:36 -07:00
parent b3599166ad
commit 81be5eb7c6

View file

@ -96,7 +96,7 @@ def issues_to_import():
yield from paginate('GET', '/repos/nixos/nix/issues?state=open&labels=lix-import') yield from paginate('GET', '/repos/nixos/nix/issues?state=open&labels=lix-import')
def issues_already_imported(): def issues_already_imported():
yield from paginate('GET', '/repos/lix-project/lix/issues?state=open&labels=imported') yield from paginate('GET', '/repos/lix-project/lix/issues?state=all&labels=imported')
UPSTREAM_ISSUE_RE = re.compile(r'^Upstream-Issue: https://git\.lix\.systems/NixOS/nix/issues/(\d+)$', re.MULTILINE) UPSTREAM_ISSUE_RE = re.compile(r'^Upstream-Issue: https://git\.lix\.systems/NixOS/nix/issues/(\d+)$', re.MULTILINE)
@ -139,7 +139,7 @@ def import_issue(iss: Issue):
new_issue(new_title, new_body, new_labels) new_issue(new_title, new_body, new_labels)
def go(): def go():
print('Have you turned off the forgejo mailer or limited the queue workers to 0 (assuming that works)? Enter "We have" if so:') print('Have you turned off the forgejo mailer? Enter "We have" if so:')
answer = input('> ') answer = input('> ')
if answer != 'We have': if answer != 'We have':
return return