~launchpad-pqm/launchpad/devel

« back to all changes in this revision

Viewing changes to lib/lp/hardwaredb/scripts/hwdbsubmissions.py

  • Committer: Jelmer Vernooij
  • Date: 2011-09-21 14:28:02 UTC
  • mfrom: (14006 devel)
  • mto: This revision was merged to the branch mainline in revision 14010.
  • Revision ID: jelmer@canonical.com-20110921142802-7ggkc204igsy532w
MergeĀ lp:launchpad

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
# Copyright 2009 Canonical Ltd.  This software is licensed under the
 
1
# Copyright 2009-2011 Canonical Ltd.  This software is licensed under the
2
2
# GNU Affero General Public License version 3 (see the file LICENSE).
3
3
 
4
4
"""Parse Hardware Database submissions.
1693
1693
        0: HWBus.SCSI,
1694
1694
        1: HWBus.IDE,
1695
1695
        2: HWBus.FLOPPY,
1696
 
        3: HWBus.IPI, # Intelligent Peripheral Interface
 
1696
        3: HWBus.IPI,  # Intelligent Peripheral Interface.
1697
1697
        5: HWBus.ATA,
1698
1698
        6: HWBus.SATA,
1699
1699
        7: HWBus.SAS,
3048
3048
            except (KeyboardInterrupt, SystemExit):
3049
3049
                # We should never catch these exceptions.
3050
3050
                raise
3051
 
            except LibrarianServerError, error:
 
3051
            except LibrarianServerError:
3052
3052
                # LibrarianServerError is raised when the server could
3053
3053
                # not be reaches for 30 minutes.
3054
3054
                #
3067
3067
                    'Could not reach the Librarian while processing HWDB '
3068
3068
                    'submission %s' % submission.submission_key)
3069
3069
                raise
3070
 
            except Exception, error:
 
3070
            except Exception:
3071
3071
                self.transaction.abort()
3072
3072
                self.reportOops(
3073
3073
                    'Exception while processing HWDB submission %s'