~ubuntu-branches/ubuntu/trusty/quantum/trusty

« back to all changes in this revision

Viewing changes to quantum/openstack/common/exception.py

  • Committer: Package Import Robot
  • Author(s): Chuck Short, Adam Gandelman, Chuck Short
  • Date: 2012-11-23 09:43:14 UTC
  • mfrom: (2.1.16)
  • Revision ID: package-import@ubuntu.com-20121123094314-e1tqsulrwe21b9aq
Tags: 2013.1~g1-0ubuntu1
[ Adam Gandelman ]
* debian/patches/*: Refreshed for opening of Grizzly.

[ Chuck Short ]
* New upstream release.
* debian/rules: FTFBS if there is missing binaries.
* debian/quantum-server.install: Add quantum-debug.

Show diffs side-by-side

added added

removed removed

Lines of Context:
22
22
import logging
23
23
 
24
24
 
25
 
class ProcessExecutionError(IOError):
26
 
    def __init__(self, stdout=None, stderr=None, exit_code=None, cmd=None,
27
 
                 description=None):
28
 
        if description is None:
29
 
            description = "Unexpected error while running command."
30
 
        if exit_code is None:
31
 
            exit_code = '-'
32
 
        message = "%s\nCommand: %s\nExit code: %s\nStdout: %r\nStderr: %r" % (
33
 
                  description, cmd, exit_code, stdout, stderr)
34
 
        IOError.__init__(self, message)
35
 
 
36
 
 
37
25
class Error(Exception):
38
26
    def __init__(self, message=None):
39
27
        super(Error, self).__init__(message)