Re: Is casting Field.help_text to string in Field.__init__ necessary?

2013-03-26 Thread Evgeny S
It works! Thanks a lot!

On Tue, Mar 26, 2013 at 12:45 AM, Claude Paroz  wrote:
> Le samedi 23 mars 2013 22:28:31 UTC+1, Claude Paroz a écrit :
>>
>> Le samedi 23 mars 2013 12:16:15 UTC+1, Evgeny a écrit :
>>>
>>> Hi.
>>>
>>> Is it necessary to cast help_text to string in Field.__init__ there
>>> https://github.com/django/django/blob/master/django/forms/fields.py#L92 ? I
>>> will be eventually displayed as string in template, and will be casted
>>> there. I think it would be better design - cast string type only in last
>>> moment in presentation template.
>>>
>>> I am asking because i try to display in template two help texts one to
>>> the right from the field and one to the bottom, and to do that i tried to
>>> pass in help_text tuple of two strings but failed because of that cast.
>>
>>
>> It seems to me that it is an "historic" remainder. I suggest you remove
>> the offending lines, run the entire test suite, and if you don't get any
>> errors, open a ticket suggesting the removal.
>
>
> Eventually, I addressed this issue in
> https://github.com/django/django/commit/066bf42675040abd7b1a42e5559890e5f9881058
> Hopefully it will solve your problem.
>
> Cheers,
>
> Claude
>
> --
> You received this message because you are subscribed to the Google Groups
> "Django developers" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-developers+unsubscr...@googlegroups.com.
> To post to this group, send email to django-developers@googlegroups.com.
> Visit this group at http://groups.google.com/group/django-developers?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To post to this group, send email to django-developers@googlegroups.com.
Visit this group at http://groups.google.com/group/django-developers?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: Is casting Field.help_text to string in Field.__init__ necessary?

2013-03-25 Thread Claude Paroz
Le samedi 23 mars 2013 22:28:31 UTC+1, Claude Paroz a écrit :
>
> Le samedi 23 mars 2013 12:16:15 UTC+1, Evgeny a écrit :
>>
>> Hi.
>>
>> Is it necessary to cast help_text to string in Field.__init__ there 
>> https://github.com/django/django/blob/master/django/forms/fields.py#L92 ? 
>> I will be eventually displayed as string in template, and will be casted 
>> there. I think it would be better design - cast string type only in last 
>> moment in presentation template.
>>  
>> I am asking because i try to display in template two help texts one to 
>> the right from the field and one to the bottom, and to do that i tried to 
>> pass in help_text tuple of two strings but failed because of that cast.
>>
>
> It seems to me that it is an "historic" remainder. I suggest you remove 
> the offending lines, run the entire test suite, and if you don't get any 
> errors, open a ticket suggesting the removal.
>

Eventually, I addressed this issue in 
https://github.com/django/django/commit/066bf42675040abd7b1a42e5559890e5f9881058
Hopefully it will solve your problem.

Cheers,

Claude 

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To post to this group, send email to django-developers@googlegroups.com.
Visit this group at http://groups.google.com/group/django-developers?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: Is casting Field.help_text to string in Field.__init__ necessary?

2013-03-24 Thread Gavin Wahl
+1. This has been a problem for me too.

On Saturday, March 23, 2013 5:16:15 AM UTC-6, Evgeny wrote:
>
> Hi.
>
> Is it necessary to cast help_text to string in Field.__init__ there 
> https://github.com/django/django/blob/master/django/forms/fields.py#L92 ? 
> I will be eventually displayed as string in template, and will be casted 
> there. I think it would be better design - cast string type only in last 
> moment in presentation template.
>  
> I am asking because i try to display in template two help texts one to the 
> right from the field and one to the bottom, and to do that i tried to pass 
> in help_text tuple of two strings but failed because of that cast.
>
> Thanks.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To post to this group, send email to django-developers@googlegroups.com.
Visit this group at http://groups.google.com/group/django-developers?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Re: Is casting Field.help_text to string in Field.__init__ necessary?

2013-03-23 Thread Claude Paroz
Le samedi 23 mars 2013 12:16:15 UTC+1, Evgeny a écrit :
>
> Hi.
>
> Is it necessary to cast help_text to string in Field.__init__ there 
> https://github.com/django/django/blob/master/django/forms/fields.py#L92 ? 
> I will be eventually displayed as string in template, and will be casted 
> there. I think it would be better design - cast string type only in last 
> moment in presentation template.
>  
> I am asking because i try to display in template two help texts one to the 
> right from the field and one to the bottom, and to do that i tried to pass 
> in help_text tuple of two strings but failed because of that cast.
>

It seems to me that it is an "historic" remainder. I suggest you remove the 
offending lines, run the entire test suite, and if you don't get any 
errors, open a ticket suggesting the removal.

Claude

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To post to this group, send email to django-developers@googlegroups.com.
Visit this group at http://groups.google.com/group/django-developers?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.




Is casting Field.help_text to string in Field.__init__ necessary?

2013-03-23 Thread Evgeny
Hi.

Is it necessary to cast help_text to string in Field.__init__ there 
https://github.com/django/django/blob/master/django/forms/fields.py#L92 ? I 
will be eventually displayed as string in template, and will be casted 
there. I think it would be better design - cast string type only in last 
moment in presentation template.
 
I am asking because i try to display in template two help texts one to the 
right from the field and one to the bottom, and to do that i tried to pass 
in help_text tuple of two strings but failed because of that cast.

Thanks.

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-developers+unsubscr...@googlegroups.com.
To post to this group, send email to django-developers@googlegroups.com.
Visit this group at http://groups.google.com/group/django-developers?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.