Re: There should be a way to make Templates substitution to raise an exception on error

2017-09-27 Thread Sjoerd Job Postmus
Also: inline. On Wednesday, September 27, 2017 at 4:55:32 PM UTC+2, pandyas...@gmail.com wrote: > > Please find comment inline > > On Friday, 22 September 2017 15:44:38 UTC+5:30, Sjoerd Job Postmus wrote: >> >> Indeed it could be! >> >> What if it was not `string_if_invalid` but `if_invalid`.

Re: Templates: __html__ method support

2017-09-27 Thread Patryk Zawadzki
W dniu wtorek, 26 września 2017 14:34:29 UTC+2 użytkownik Jonas H napisał: > > Proposal: Support the __html__ method as an alternative/addition to the > __str__ for turning objects into strings in the template layer. > > If this has been discussed before, please point me to it; I couldn't find >

Re: There should be a way to make Templates substitution to raise an exception on error

2017-09-27 Thread pandyashreyas1
Please find comment inline On Friday, 22 September 2017 15:44:38 UTC+5:30, Sjoerd Job Postmus wrote: > > Indeed it could be! > > What if it was not `string_if_invalid` but `if_invalid`. The value could > be: > > * An Exception instance (which would then be raised) > * An Exception class (which