Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #100577 > unrolled thread
| Started by | Chris Angelico <rosuav@gmail.com> |
|---|---|
| First post | 2015-12-18 11:16 +1100 |
| Last post | 2015-12-18 11:16 +1100 |
| Articles | 1 — 1 participant |
Back to article view | Back to comp.lang.python
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
Re: Should stdlib files contain 'narrow non breaking space' U+202F? Chris Angelico <rosuav@gmail.com> - 2015-12-18 11:16 +1100
| From | Chris Angelico <rosuav@gmail.com> |
|---|---|
| Date | 2015-12-18 11:16 +1100 |
| Subject | Re: Should stdlib files contain 'narrow non breaking space' U+202F? |
| Message-ID | <mailman.42.1450397817.30845.python-list@python.org> |
On Fri, Dec 18, 2015 at 11:02 AM, Mark Lawrence <breamoreboy@yahoo.co.uk> wrote: > A lot of it is down to Windows, as the actual complaint is:- > > six.print_(source) > File "C:\Python35\lib\encodings\cp1252.py", line 19, in encode > return codecs.charmap_encode(input,self.errors,encoding_table)[0] > UnicodeEncodeError: 'charmap' codec can't encode character '\u202f' in > position 407: character maps to <undefined> > > And as usual I've answered my own question. The cp1252 shows even if my > console is set to 65001, *BUT* I'm piping the output to file as it's so much > faster. Having taken five minutes to run the code without the pipe > everything runs to completion. > > I suppose the original question still holds, but I for one certainly won't > be losing any sleep over it. Talking of which, good night all :) Oh. Windows. Suddenly it all makes sense. Python source code is (as of 3.0) Unicode text, and is assumed to be stored as UTF-8 if not otherwise specified. If Windows can't handle that, too bad for Windows. ChrisA
Back to top | Article view | comp.lang.python
csiph-web