~azzar1/unity/add-show-desktop-key

« back to all changes in this revision

Viewing changes to lib/common/util.py

  • Committer: dcoles
  • Date: 2008-02-13 04:10:55 UTC
  • Revision ID: svn-v3-trunk0:2b9c9e99-6f39-0410-b283-7f802c844ae2:trunk:443
Added Forum application along with unmodifed version of phpBB3 "Olympus" 3.0.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
31
31
 
32
32
root_dir = conf.root_dir
33
33
 
34
 
class IVLEError(Exception):
35
 
    """
36
 
    This is the "standard" exception class for IVLE errors.
37
 
    It is the ONLY exception which should propagate to the top - it will then
38
 
    be displayed to the user as an HTTP error with the given code.
39
 
 
40
 
    All other exceptions are considered IVLE bugs and should not occur
41
 
    (they will display a traceback).
42
 
 
43
 
    This error should not be raised directly. Call req.throw_error.
44
 
    """
45
 
    def __init__(self, httpcode, message=None):
46
 
        self.httpcode = httpcode
47
 
        self.message = message
48
 
        self.args = (httpcode, message)
49
 
 
50
34
def make_path(path):
51
35
    """Given a path relative to the IVLE root, makes the path relative to the
52
36
    site root using conf.root_dir. This path can be used in URLs sent to the