summaryrefslogtreecommitdiff
path: root/src/leap/base/exceptions.py
diff options
context:
space:
mode:
authorMicah Anderson <micah@riseup.net>2013-08-22 14:10:50 -0400
committerMicah Anderson <micah@riseup.net>2013-08-22 14:10:50 -0400
commit6bae67c3e7c66af9e8ce1605070f7e92f247f0cb (patch)
tree64dc7e2588cc5c17fdb6c801877792f83cfcecf3 /src/leap/base/exceptions.py
parent00efccabb1eb6c3597282bc0e095cf2026f75a3b (diff)
parent00d98a47c60764475d97df1c2eb847e20a77cae5 (diff)
Merge tag '0.3.0' into debian
Tag bitmask version 0.3.0 Conflicts: .coveragerc .tx/config NEWS.rst setup.cfg src/leap/base/checks.py src/leap/base/exceptions.py src/leap/base/tests/test_checks.py src/leap/eip/checks.py src/leap/gui/firstrun/login.py src/leap/gui/locale_rc.py src/leap/util/polkit.py tests/test_qt_environment.py tox.ini
Diffstat (limited to 'src/leap/base/exceptions.py')
-rw-r--r--src/leap/base/exceptions.py97
1 files changed, 0 insertions, 97 deletions
diff --git a/src/leap/base/exceptions.py b/src/leap/base/exceptions.py
deleted file mode 100644
index 3d8dde48..00000000
--- a/src/leap/base/exceptions.py
+++ /dev/null
@@ -1,97 +0,0 @@
-"""
-Exception attributes and their meaning/uses
--------------------------------------------
-
-* critical: if True, will abort execution prematurely,
- after attempting any cleaning
- action.
-
-* failfirst: breaks any error_check loop that is examining
- the error queue.
-
-* message: the message that will be used in the __repr__ of the exception.
-
-* usermessage: the message that will be passed to user in ErrorDialogs
- in Qt-land.
-"""
-from leap.util.translations import translate
-
-
-class LeapException(Exception):
- """
- base LeapClient exception
- sets some parameters that we will check
- during error checking routines
- """
-
- critical = False
- failfirst = False
- warning = False
-
-
-class CriticalError(LeapException):
- """
- we cannot do anything about it
- """
- critical = True
- failfirst = True
-
-
-# In use ???
-# don't thing so. purge if not...
-
-class MissingConfigFileError(Exception):
- pass
-
-
-class ImproperlyConfigured(Exception):
- pass
-
-
-# NOTE: "Errors" (context) has to be a explicit string!
-
-
-class InterfaceNotFoundError(LeapException):
- # XXX should take iface arg on init maybe?
- message = "interface not found"
- usermessage = translate(
- "Errors",
- "Interface not found")
-
-
-class NoDefaultInterfaceFoundError(LeapException):
- message = "no default interface found"
- usermessage = translate(
- "Errors",
- "Looks like your computer "
- "is not connected to the internet")
-
-
-class NoConnectionToGateway(LeapException):
- message = "no connection to gateway"
- usermessage = translate(
- "Errors",
- "Looks like there are problems "
- "with your internet connection")
-
-
-class NoInternetConnection(LeapException):
- message = "No Internet connection found"
- usermessage = translate(
- "Errors",
- "It looks like there is no internet connection.")
- # and now we try to connect to our web to troubleshoot LOL :P
-
-
-class CannotResolveDomainError(LeapException):
- message = "Cannot resolve domain"
- usermessage = translate(
- "Errors",
- "Domain cannot be found")
-
-
-class TunnelNotDefaultRouteError(LeapException):
- message = "Tunnel connection dissapeared. VPN down?"
- usermessage = translate(
- "Errors",
- "The Encrypted Connection was lost.")