Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(29040)

#20491: textwrap: Non-breaking space not honored

Can't Edit
Can't Publish+Mail
Start Review
Created:
5 years, 8 months ago by kaarle.ritvanen
Modified:
3 years ago
Reviewers:
merwok
CC:
lemburg, loewis, Georg, AntoinePitrou, haypo, Benjamin Peterson, mcepl, ezio.melotti, eric.araujo, r.david.murray, devnull_psf.upfronthosting.co.za, dfnsonfsduifb_gmx.de, storchaka, kaarle.ritvanen_datakunkku.fi, d.budinova_gmail.com, maatt, Mariatta
Visibility:
Public.

Patch Set 1 #

Patch Set 2 #

Patch Set 3 #

Total comments: 1

Patch Set 4 #

Total comments: 3

Patch Set 5 #

Unified diffs Side-by-side diffs Delta from patch set Stats Patch
Lib/test/test_textwrap.py View 1 2 3 4 1 chunk +31 lines, -0 lines 0 comments Download
Lib/textwrap.py View 1 2 3 4 3 chunks +13 lines, -14 lines 0 comments Download

Messages

Total messages: 2
eric.araujo
http://bugs.python.org/review/20491/diff/10923/Lib/textwrap.py File Lib/textwrap.py (right): http://bugs.python.org/review/20491/diff/10923/Lib/textwrap.py#newcode84 Lib/textwrap.py:84: (r'([%s]+|' % _whitespace) + To avoid all the parens ...
5 years, 7 months ago #1
eric.araujo
5 years, 7 months ago #2
http://bugs.python.org/review/20491/diff/11358/Lib/test/test_textwrap.py
File Lib/test/test_textwrap.py (right):

http://bugs.python.org/review/20491/diff/11358/Lib/test/test_textwrap.py#newc...
Lib/test/test_textwrap.py:447: text = 'This is a sentence with non-breaking'\
Minor: It’s recommended to use extra parens instead of backslash to continue a
statement on two lines.

http://bugs.python.org/review/20491/diff/11358/Lib/textwrap.py
File Lib/textwrap.py (right):

http://bugs.python.org/review/20491/diff/11358/Lib/textwrap.py#newcode20
Lib/textwrap.py:20: _whitespace = '\t\n\x0b\x0c\r '
Like I said on the ticket, this comment should be updated (it confuses bytes and
characters).

http://bugs.python.org/review/20491/diff/11358/Lib/textwrap.py#newcode89
Lib/textwrap.py:89: )
As I recommended, this would be most readable with a verbose regex.
Sign in to reply to this message.

RSS Feeds Recent Issues | This issue
This is Rietveld 894c83f36cb7+