commit: d6d711507391e634da4dbfe6ae787aef17c4f6f2 Author: Thomas Bracht Laumann Jespersen <t <AT> laumann <DOT> xyz> AuthorDate: Mon Mar 16 05:19:04 2026 +0000 Commit: Michał Górny <mgorny <AT> gentoo <DOT> org> CommitDate: Mon Mar 16 11:28:48 2026 +0000 URL: https://gitweb.gentoo.org/proj/assign-pull-requests.git/commit/?id=d6d71150
codeberg: handle empty user names The dev_mapping dict may contain entries that map to "". This comes from devs.json that contains entries for all developers and have empty strings for developers that do not have (registered) Codeberg accounts. Signed-off-by: Thomas Bracht Laumann Jespersen <t <AT> laumann.xyz> Part-of: https://github.com/gentoo/assign-pull-requests/pull/16 Closes: https://github.com/gentoo/assign-pull-requests/pull/16 Signed-off-by: Michał Górny <mgorny <AT> gentoo.org> assign-pull-requests-codeberg.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/assign-pull-requests-codeberg.py b/assign-pull-requests-codeberg.py index 67e3c41..193ebb8 100644 --- a/assign-pull-requests-codeberg.py +++ b/assign-pull-requests-codeberg.py @@ -256,8 +256,8 @@ def assign_one( team_reviewers.add(team) else: ms = map_dev(memail, dev_mapping) - u = dev_mapping.get(memail.lower()) - if u not in (None, pr_submitter): + u = dev_mapping.get(memail.lower(), "") + if u not in ("", pr_submitter): reviewers.add(u) for subm in m:
