l.b.m.c.AffectsEmailCommand(EmailCommand) : class documentation

Part of lp.bugs.mail.commands View In Hierarchy

Either creates a new task, or edits an existing task.
Class Method getBugTarget Return the IBugTarget with the given path.
Method execute See IEmailCommand.
Class Method _splitPath Split the path part into two.
Class Method _normalizePath Normalize the path.
Method _targetBug Try to target the bug the given distroseries.
Method _create_bug_task Creates a new bug task with bug_target as the target.

Inherited from EmailCommand:

Method __init__ Undocumented
Method convertArguments Converts the string argument to Python objects.
Method __str__ See IEmailCommand.
Method _ensureNumberOfArguments Check that the number of arguments is correct.
@classmethod
def _splitPath(cls, path):
Split the path part into two.

The first part is the part before any slash, and the other is the part behind the slash.

@classmethod
def _normalizePath(cls, path):
Normalize the path.

Previously the path had to start with either /distros/ or /products/. Simply remove any such prefixes to stay backward compatible.

@classmethod
def getBugTarget(cls, path):

Return the IBugTarget with the given path.

Path should be in any of the following forms:

$product $product/$product_series $distribution $distribution/$source_package $distribution/$distro_series $distribution/$distro_series/$source_package
def execute(self, bug, bug_event):
See IEmailCommand.
def _targetBug(self, user, bug, target):
Try to target the bug the given distroseries.

If the user doesn't have permission to target the bug directly, only a nomination will be created.

def _create_bug_task(self, bug, bug_target):
Creates a new bug task with bug_target as the target.
API Documentation for Launchpad, generated by pydoctor at 2022-06-16 00:00:12.