launchpad-reviewers team mailing list archive
-
launchpad-reviewers team
-
Mailing list archive
-
Message #06288
[Merge] lp:~rharding/launchpad/ec2_land_928853 into lp:launchpad
Richard Harding has proposed merging lp:~rharding/launchpad/ec2_land_928853 into lp:launchpad.
Requested reviews:
Launchpad code reviewers (launchpad-reviewers)
Related bugs:
Bug #928853 in Launchpad itself: "ec2 land fails if there is no None value in the stakeholder email set"
https://bugs.launchpad.net/launchpad/+bug/928853
For more details, see:
https://code.launchpad.net/~rharding/launchpad/ec2_land_928853/+merge/92033
= Summary =
Landing via ec2 land throws a keyerorr exception when it attempts to build the list of notification emails.
== Proposed Fix ==
The code there blindly runs a set.remove(None) when None might not be in the set. Per docs, that raises a keyerror. Add a check to see if None is in the set first, then remove if that's the case.
== Demo and Q/A ==
ec2 land should work
--
https://code.launchpad.net/~rharding/launchpad/ec2_land_928853/+merge/92033
Your team Launchpad code reviewers is requested to review the proposed merge of lp:~rharding/launchpad/ec2_land_928853 into lp:launchpad.
=== modified file 'lib/devscripts/autoland.py'
--- lib/devscripts/autoland.py 2012-02-08 08:24:41 +0000
+++ lib/devscripts/autoland.py 2012-02-08 14:02:26 +0000
@@ -128,7 +128,8 @@
emails = set(
map(get_email,
[self._mp.source_branch.owner, self._launchpad.me]))
- emails.remove(None)
+ if None in emails:
+ emails.remove(None)
return emails
def get_reviews(self):