Part of lp.archiveuploader.uploadprocessor View In Hierarchy
Known subclasses: lp.archiveuploader.uploadprocessor.BuildUploadHandler, lp.archiveuploader.uploadprocessor.UserUploadHandler
Method | __init__ | Constructor. |
Static Method | forProcessor | Instantiate an UploadHandler subclass for a given upload. |
Method | locateChangesFiles | Locate .changes files in the upload directory. |
Method | processChangesFile | Process a single changes file. |
Method | removeUpload | Remove an upload that has succesfully been processed. |
Method | moveProcessedUpload | Move or remove the upload depending on the status of the upload. |
Method | moveUpload | Move the upload to the named subdir of the root, eg 'accepted'. |
Static Method | orderFilenames | Order filenames, sorting *_source.changes before others. |
Parameters | processor | The UploadProcessor that requested processing the
upload. |
fsroot | Path to the directory containing the upload directory | |
upload | Name of the directory containing the upload. |
Parameters | processor | The UploadProcessor that requested processing the
upload. |
fsroot | Path to the directory containing the upload directory | |
upload | Name of the directory containing the upload. | |
build | Optional; the build that produced the upload. |
Locate .changes files in the upload directory. Return .changes files sorted with *_source.changes first. This is important to us, as in an upload containing several changes files, it's possible the binary ones will depend on the source ones, so the source ones should always be considered first.
This is done by obtaining the appropriate upload policy (according to command-line options), creating a NascentUpload object and calling its process method.
We obtain the context for this processing from the relative path, within the upload folder, of this changes file. This influences our creation both of upload policy and the NascentUpload object.
See nascentupload.py for the gory details.
Returns a value from UploadStatusEnum, or re-raises an exception from NascentUpload.
Parameters | changes_file | filename of the changes file to process. |
logger | logger to use for processing. | |
Returns | an UploadStatusEnum value |
Parameters | logger | The logger to use for logging results. |
Parameters | destination | An UploadStatusEnum value. |
logger | The logger to use for logging results. |