I generally agree about the capitalizing, but I'm not sure all the messages 
deserve a period at the end (e.g., "Invalid expression", "Value not 
allowed", "No Match", etc.).

Anthony

On Saturday, February 25, 2012 10:51:24 AM UTC-5, Kernc wrote:
>
> Hi,
>
> *I propose all validators' error_message values be capitalized and 
> end-punctuated*, so e.g. 
>
> this:
>
>> enter from %(min)g to %(max)g characters
>>
> becomes this:
>
>> Enter from %(min)g to %(max)g characters.
>>
>
> As of now, some validators' errors are capitalized while most aren't 
> (inconsistent).
>
> Thus, to have chances of looking even remotely professional, I always have 
> to do the following in controllers with forms:
>
>> if form.errors:
>>   for err in form.errors:
>>     form.errors[err] = form.errors[err].capitalize() + '.'
>>
>
> In case of IS_STRONG() validator, which returns several failures, the 
> above code doesn't even work correctly.
>
> What are your thoughts on this?
> If I provide a latest validators.py diffing patch, will it be accepted?
>

Reply via email to