summaryrefslogtreecommitdiffstats
path: root/ipalib/errors.py
diff options
context:
space:
mode:
authorRob Crittenden <rcritten@redhat.com>2010-12-06 15:09:03 -0500
committerRob Crittenden <rcritten@redhat.com>2010-12-07 16:37:42 -0500
commit6e2dd0fa5b79849c3dbd5f9b855e43b634e2a4b3 (patch)
tree3264b8ba10fdb44845ee4f257e851f2764f3a6cd /ipalib/errors.py
parent78786a699586b12ec53c0a87703e0a44e9c7427e (diff)
downloadfreeipa-6e2dd0fa5b79849c3dbd5f9b855e43b634e2a4b3.tar.gz
freeipa-6e2dd0fa5b79849c3dbd5f9b855e43b634e2a4b3.tar.xz
freeipa-6e2dd0fa5b79849c3dbd5f9b855e43b634e2a4b3.zip
Add new parameter type IA5Str and use this to enforce the right charset.
ticket 496
Diffstat (limited to 'ipalib/errors.py')
-rw-r--r--ipalib/errors.py16
1 files changed, 16 insertions, 0 deletions
diff --git a/ipalib/errors.py b/ipalib/errors.py
index 58799628d..49d6343a4 100644
--- a/ipalib/errors.py
+++ b/ipalib/errors.py
@@ -1252,6 +1252,22 @@ class OnlyOneValueAllowed(ExecutionError):
format = _('%(attr)s: Only one value allowed.')
+class InvalidSyntax(ExecutionError):
+ """
+ **4208** Raised when trying to set more than one value to single-value attributes
+
+ For example:
+
+ >> raise OnlyOneValueAllowed(attr='ipahomesrootdir')
+ Traceback (most recent call last):
+ ...
+ InvalidSyntax: ipahomesrootdir: Invalid syntax
+ """
+
+ errno = 4208
+ format = _('%(attr)s: Invalid syntax.')
+
+
class CertificateError(ExecutionError):
"""
**4300** Base class for Certificate execution errors (*4300 - 4399*).