Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #65196

Re: Python shell wont open idle or an exisiting py file

Path csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!newsfeed.datemas.de!rt.uk.eu.org!newsfeed.xs4all.nl!newsfeed3.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail
Return-Path <python-python-list@m.gmane.org>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.001
X-Spam-Evidence '*H*': 1.00; '*S*': 0.00; 'subject:Python': 0.06; 'subject:file': 0.07; 'string': 0.09; 'received:80.91': 0.09; 'received:80.91.229': 0.09; 'received:gmane.org': 0.09; 'received:list': 0.09; 'python': 0.11; 'bug': 0.12; 'jan': 0.12; 'codec': 0.16; "microsoft's": 0.16; 'received:80.91.229.3': 0.16; 'received:plane.gmane.org': 0.16; 'reedy': 0.16; 'separator.': 0.16; 'storing': 0.16; 'sat,': 0.16; 'weird': 0.16; 'wrote:': 0.18; 'feb': 0.22; 'header:User-Agent:1': 0.23; 'byte': 0.24; 'right.': 0.26; 'header:X-Complaints-To:1': 0.27; 'header:In- Reply-To:1': 0.27; 'chris': 0.29; 'character': 0.29; '(which': 0.31; 'fixing': 0.31; 'there.': 0.32; "can't": 0.35; 'combination': 0.36; 'to:addr:python-list': 0.38; 'pm,': 0.38; 'little': 0.38; 'to:addr:python.org': 0.39; 'received:org': 0.40; 'skip:u 10': 0.60; 'received:173': 0.61; 'invalid': 0.68; 'caused': 0.69; '14:': 0.84; 'received:fios.verizon.net': 0.84; 'so...': 0.84
X-Injected-Via-Gmane http://gmane.org/
To python-list@python.org
From Terry Reedy <tjreedy@udel.edu>
Subject Re: Python shell wont open idle or an exisiting py file
Date Sat, 01 Feb 2014 00:44:22 -0500
References <24EAA33389A147D8BC08B029E2209E16@UserPC> <lcguq4$a3s$1@ger.gmane.org> <lchjk7$8og$1@ger.gmane.org> <CAPTjJmpc6+hSjTy9tn_AMNMVsdnfQh6E+GHx0a=SmJmJ5=5Uvw@mail.gmail.com>
Mime-Version 1.0
Content-Type text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding 7bit
X-Gmane-NNTP-Posting-Host pool-173-75-254-207.phlapa.fios.verizon.net
User-Agent Mozilla/5.0 (Windows NT 6.1; WOW64; rv:24.0) Gecko/20100101 Thunderbird/24.2.0
In-Reply-To <CAPTjJmpc6+hSjTy9tn_AMNMVsdnfQh6E+GHx0a=SmJmJ5=5Uvw@mail.gmail.com>
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.15
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <https://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list/>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <https://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.6267.1391233481.18130.python-list@python.org> (permalink)
Lines 22
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1391233481 news.xs4all.nl 2916 [2001:888:2000:d::a6]:32939
X-Complaints-To abuse@xs4all.nl
Xref csiph.com comp.lang.python:65196

Show key headers only | View raw


On 1/31/2014 8:52 PM, Chris Angelico wrote:
> On Sat, Feb 1, 2014 at 12:45 PM, Terry Reedy <tjreedy@udel.edu> wrote:
>> H:\HP_Documents\0PythonWork\AirplaneKinematics\accel2.py
>> caused this message
>> UnicodeDecodeError: 'utf-8' codec can't decode byte 0xc0 in position 14:
>> invalid start byte
>
> So... something's interpreting \0 as codepoint U+0000 (which it
> shouldn't), storing that in "UTF-8" as 0xC0 0x80 (which it shouldn't),
> and then giving it to Python to decode.

Right. Which is why it puzzled me. Credit Serhiy for unraveling this and 
fixing it.

 > That's a weird little combination bug right there.

Which started with Microsoft's decision to reuse the string excape 
character '\' as a directory separator.

-- 
Terry Jan Reedy

Back to comp.lang.python | Previous | Next | Find similar | Unroll thread


Thread

Re: Python shell wont open idle or an exisiting py file Terry Reedy <tjreedy@udel.edu> - 2014-02-01 00:44 -0500

csiph-web