launchpad-reviewers team mailing list archive
-
launchpad-reviewers team
-
Mailing list archive
-
Message #01876
[Merge] lp:~stevenk/launchpad/move-ppaexception into lp:launchpad/devel
Steve Kowalik has proposed merging lp:~stevenk/launchpad/move-ppaexception into lp:launchpad/devel.
Requested reviews:
Launchpad code reviewers (launchpad-reviewers)
This branch shifts PPACreationError from lp.registry.interfaces.person into lp.registry.errors, and cleans up one piece of lint I noticed.
--
https://code.launchpad.net/~stevenk/launchpad/move-ppaexception/+merge/40408
Your team Launchpad code reviewers is requested to review the proposed merge of lp:~stevenk/launchpad/move-ppaexception into lp:launchpad/devel.
=== modified file 'lib/lp/registry/errors.py'
--- lib/lp/registry/errors.py 2010-10-20 15:51:16 +0000
+++ lib/lp/registry/errors.py 2010-11-09 07:14:44 +0000
@@ -13,6 +13,7 @@
'NameAlreadyTaken',
'NoSuchDistroSeries',
'NoSuchSourcePackageName',
+ 'PPACreationError',
'PrivatePersonLinkageError',
'TeamMembershipTransitionError',
'UserCannotChangeMembershipSilently',
@@ -120,3 +121,9 @@
class JoinNotAllowed(Exception):
"""User is not allowed to join a given team."""
webservice_error(httplib.BAD_REQUEST)
+
+
+class PPACreationError(Exception):
+ """Raised when there is an issue creating a new PPA."""
+
+ webservice_error(httplib.BAD_REQUEST)
=== modified file 'lib/lp/registry/interfaces/person.py'
--- lib/lp/registry/interfaces/person.py 2010-11-04 17:52:48 +0000
+++ lib/lp/registry/interfaces/person.py 2010-11-09 07:14:44 +0000
@@ -27,7 +27,6 @@
'ImmutableVisibilityError',
'InvalidName',
'NoSuchPerson',
- 'PPACreationError',
'PersonCreationRationale',
'PersonVisibility',
'PersonalStanding',
@@ -61,7 +60,6 @@
operation_returns_entry,
rename_parameters_as,
REQUEST_USER,
- webservice_error,
)
from lazr.restful.fields import (
CollectionField,
@@ -2207,11 +2205,6 @@
_message_prefix = "No such person"
-class PPACreationError(Exception):
- """Raised when there is an issue creating a new PPA."""
-
- webservice_error(400) # Bad Request
-
# Fix value_type.schema of IPersonViewRestricted attributes.
for name in [
'all_members_prepopulated',
=== modified file 'lib/lp/registry/model/person.py'
--- lib/lp/registry/model/person.py 2010-11-04 17:52:48 +0000
+++ lib/lp/registry/model/person.py 2010-11-09 07:14:44 +0000
@@ -181,7 +181,6 @@
)
from lp.bugs.model.bugtarget import HasBugsBase
from lp.bugs.model.bugtask import (
- BugTask,
get_related_bugtasks_search_params,
)
from lp.code.model.hasbranches import (
@@ -192,6 +191,7 @@
from lp.registry.errors import (
JoinNotAllowed,
NameAlreadyTaken,
+ PPACreationError,
)
from lp.registry.interfaces.codeofconduct import ISignedCodeOfConductSet
from lp.registry.interfaces.distribution import IDistribution
@@ -218,7 +218,6 @@
IPerson,
IPersonSet,
ITeam,
- PPACreationError,
PersonalStanding,
PersonCreationRationale,
PersonVisibility,