CMS 3D CMS Logo

List of all members | Public Member Functions | Public Attributes
uploadConditions.HTTPError Class Reference
Inheritance diagram for uploadConditions.HTTPError:
Exception

Public Member Functions

def __init__ (self, code, response)
 

Public Attributes

 args
 
 code
 
 response
 

Detailed Description

A common HTTP exception.

self.code is the response HTTP code as an integer.
self.response is the response body (i.e. page).

Definition at line 210 of file uploadConditions.py.

Constructor & Destructor Documentation

def uploadConditions.HTTPError.__init__ (   self,
  code,
  response 
)

Definition at line 217 of file uploadConditions.py.

217  def __init__(self, code, response):
218  self.code = code
219  self.response = response
220 
221  # Try to extract the error message if possible (i.e. known error page format)
222  try:
223  self.args = (response.split('<p>')[1].split('</p>')[0], )
224  except Exception:
225  self.args = (self.response, )
226 
227 
def __init__(self, code, response)
double split
Definition: MVATrainer.cc:139

Member Data Documentation

uploadConditions.HTTPError.args

Definition at line 223 of file uploadConditions.py.

uploadConditions.HTTPError.code

Definition at line 218 of file uploadConditions.py.

uploadConditions.HTTPError.response

Definition at line 219 of file uploadConditions.py.