
report at bugs
Nov 28, 2009, 2:11 PM
Post #7 of 9
(277 views)
Permalink
|
|
[issue1859] textwrap doesn't linebreak on "\n"
[In reply to]
|
|
Greg Ward <greg [at] gerg> added the comment: > Greg, any comment on this issue? Yes, two: 1) textwrap does not handle paragraphs or paragraph breaks in any way. That was a deliberate limitation to keep the code from getting any hairier. People have complained about this in the past, and I have studiously ignored such complaints. The standard answer is that you should break your text into paragraphs and then feed those paragraphs individually to a TextWrapper. But this does not look like that old complaint. 2) Test, test, test. In case you hadn't already noticed, this is a hairy piece of code. It's also a poster child for unit testing. Any change should IMHO be accompanied by lots of new tests. No wait, make that *three* comments: 3) I agree with tlynn that the example in msg95469 looks *awfully* fishy. But I don't remember enough of the details to say what's likely to be broken. That's probably your first test case right there. ---------- _______________________________________ Python tracker <report [at] bugs> <http://bugs.python.org/issue1859> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/list-python-bugs%40lists.gossamer-threads.com
|