From 6e2dd0fa5b79849c3dbd5f9b855e43b634e2a4b3 Mon Sep 17 00:00:00 2001 From: Rob Crittenden Date: Mon, 6 Dec 2010 15:09:03 -0500 Subject: Add new parameter type IA5Str and use this to enforce the right charset. ticket 496 --- ipalib/errors.py | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'ipalib/errors.py') 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*). -- cgit