Message159452
Here's my patch, along the lines of the work-around I posted earlier. A few remarks:
1. The modifications in pydoc only touch the four console pagers and the html pager (html.page).
2. A module-wide default encoding is initialized from locale.getpreferredencoding. Pagers that write to a file use the encoding of that file if defined, else they use the module-wide default. The html pager uses ascii. All of them use xml character entity replacement as fall-back.
3. An additional set of tests has been added to test.test_pydoc to verify the behaviour of the modifications.
4. No functionality is broken if Python is built without unicode support. |
|
Date |
User |
Action |
Args |
2012-04-27 12:21:59 | taschini | set | recipients:
+ taschini, loewis, ping, rhettinger, cben, eric.araujo, r.david.murray, ness |
2012-04-27 12:21:59 | taschini | set | messageid: <1335529319.58.0.751505375377.issue1065986@psf.upfronthosting.co.za> |
2012-04-27 12:21:59 | taschini | link | issue1065986 messages |
2012-04-27 12:21:58 | taschini | create | |
|