From 338578d10ac0978a00948971a17a89dc95435954 Mon Sep 17 00:00:00 2001 From: Rob Crittenden Date: Fri, 12 Feb 2010 11:01:23 -0500 Subject: Allow one-character Param names This is done explicitly to support the l/localityname attribute. --- ipalib/config.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'ipalib/config.py') diff --git a/ipalib/config.py b/ipalib/config.py index 5eef03b0..5311f990 100644 --- a/ipalib/config.py +++ b/ipalib/config.py @@ -74,11 +74,11 @@ class Env(object): >>> env.BadName = 'Wont work as an attribute' Traceback (most recent call last): ... - ValueError: name must match '^[a-z][_a-z0-9]*[a-z0-9]$'; got 'BadName' + ValueError: name must match '^[a-z][_a-z0-9]*[a-z0-9]$|^[a-z]$'; got 'BadName' >>> env['BadName'] = 'Also wont work as a dictionary item' Traceback (most recent call last): ... - ValueError: name must match '^[a-z][_a-z0-9]*[a-z0-9]$'; got 'BadName' + ValueError: name must match '^[a-z][_a-z0-9]*[a-z0-9]$|^[a-z]$'; got 'BadName' The variable values can be ``str``, ``int``, or ``float`` instances, or the ``True``, ``False``, or ``None`` constants. When the value provided is an -- cgit