Part of lp.archivepublisher.scripts.processaccepted View In Hierarchy
Given a distribution to run on, obtains all the queue items for the distribution and then gets on and deals with any accepted items, preparing them for publishing as appropriate.
Method | lockfilename | See LaunchpadScript . |
Method | add_my_options | Command line options for this script. |
Method | validateArguments | Validate command-line arguments. |
Method | getTargetArchives | Find archives to target based on given options. |
Method | processQueueItem | Attempt to process queue_item . |
Method | processForDistro | Process all queue items for a distribution. |
Method | main | Entry point for a LaunchpadScript. |
Inherited from PublisherScript:
Method | addDistroOptions | Undocumented |
Method | findSelectedDistro | Find the Distribution named by the --distribution option. |
Method | findDerivedDistros | Find all Ubuntu-derived distributions. |
Method | findDistros | Find the selected distribution(s). |
Inherited from LaunchpadCronScript (via PublisherScript):
Method | __init__ | Construct new LaunchpadScript. |
Method | get_last_activity | Return the last activity, if any. |
Method | record_activity | Record the successful completion of the script. |
Inherited from LaunchpadScript (via PublisherScript, LaunchpadCronScript):
Method | handle_options | Undocumented |
Method | name | Enable subclasses to override with command-line arguments. |
Method | dbuser | Enable subclasses to override with command-line arguments. |
Method | login | Super-convenience method that avoids the import. |
Method | lockfilepath | Undocumented |
Method | setup_lock | Create lockfile. |
Method | lock_or_die | Attempt to lock, and sys.exit(1) if the lock's already taken. |
Method | unlock | Release the lock. Do this before going home. |
Method | run | Actually run the script, executing zcml and initZopeless. |
Method | lock_and_run | Call lock_or_die(), and then run() the script. |
Method | _init_zca | Initialize the ZCA, this can be overridden for testing purposes. |
Method | _init_db | Initialize the database transaction. |
queue_item
.
This method swallows exceptions that occur while processing the item.
Parameters | queue_item | A PackageUpload to process. |
Returns | True on success, or False on failure. |
Commits between items.
Parameters | distribution | The Distribution to process queue items for. |
Returns | A list of all successfully processed items' ids. |