News for hackers. Stuff that matters.
Re:New Python Idioms by twp on Sunday October 24, 2010 @10:29AM (#1826173)
In the section on the with statement he says

> Please don't abuse with for XML/HTML generation

Being guilty of such abuse, I would like to know why not? (I genuinely want to know!)

Re:New Python Idioms by ljlolel on Sunday October 24, 2010 @03:12PM (#1826925)
There is no reason because it's not true. I've used the with statement to help with auto-closing tags (and just readability) in templating and it helps a lot. I've used in on sites which received over 1 million hits a month. It's been used on over a dozen sites and projects from hundreds of lines of codes and even into the tens of thousands of lines of code.

http://news.ycombinator.com/item?id=1605249