~launchpad-pqm/launchpad/devel

3944.1.1 by Francis J. Lacoste
Use system version python2.4 for scripts.
1
#!/usr/bin/python2.4
8687.15.22 by Karl Fogel
Add the copyright header block to the remaining .py files.
2
#
3
# Copyright 2009 Canonical Ltd.  This software is licensed under the
4
# GNU Affero General Public License version 3 (see the file LICENSE).
5
2733 by Canonical.com Patch Queue Manager
Upload processor. r=stevea
6
"""Upload processor.
7
8
Given a bunch of context information and a bunch of files, process them as
9
an upload to a distro/whatever within the launchpad.
10
"""
11
8447.1.5 by Jonathan Lange
Should never have dropped this.
12
import _pythonpath
13
8447.1.6 by Jonathan Lange
Removing this import causes three tests to fail for obscure reasons.
14
# XXX: This import is not actually used, but it avoids a major circular import
15
# problem. We love you too, Python.
8426.7.4 by Julian Edwards
mop up some top level scripts with bad imports.
16
from lp.archiveuploader.uploadpolicy import policy_options
2733 by Canonical.com Patch Queue Manager
Upload processor. r=stevea
17
from canonical.config import config
8294.6.5 by Julian Edwards
Fix a bunch of circular imports, but there's still one I can't find.
18
from lp.soyuz.scripts.soyuz_process_upload import ProcessUpload
5294.1.3 by Jeroen Vermeulen
Addressed BjornT's points prior to resuming formal review.
19
3023.4.1 by Christian Reis
Handle review comments from Salgado and Spiv
20
2733 by Canonical.com Patch Queue Manager
Upload processor. r=stevea
21
if __name__ == '__main__':
3691.348.26 by kiko
Convert process-upload.py to use a lockfile that varies according to which upload policy is being used.
22
    script = ProcessUpload('process-upload', dbuser=config.uploader.dbuser)
23
    script.lock_and_run()