[Python-bugs-list] [ python-Bugs-683416 ] Whats new: Obligatory source code encodings if not ASCII

SourceForge.net noreply@sourceforge.net
Sun, 09 Feb 2003 06:52:29 -0800


Bugs item #683416, was opened at 2003-02-09 14:52
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=683416&group_id=5470

Category: Documentation
Group: Python 2.3
Status: Open
Resolution: None
Priority: 5
Submitted By: Roman Suzi (rnd0110)
Assigned to: Nobody/Anonymous (nobody)
Summary: Whats new: Obligatory source code encodings if not ASCII

Initial Comment:
As per PEP 263, source code encoding cookie is a must
for source code file. This fact  is not stressed enough in
the documentation.

I think, these sections must be changed to reflect PEP263:

What's new in Python 2.3

Section 3: PEP 263 Source Code Encoding
 must inform the reader on this:

Source files which use non-ASCII characters and do not
have encoding declaration are phased out. Python 2.3 
gives DeprecationWarnings. Later versions will give
SyntraxError
instead.


13.1 String changes

Unicode literals can now contain characters of the
source file encoding if such was specified (see PEP 263).



18 Porting to Python 2.3 section needs addition:

* to avoid DeprecationWarnings, add encoding
declaration to all source files according to PEP 263,
if they are using non-ASCII characters. After that,
Unicode strings could be specified with symbols from
specified encoding.

(Please correct my English, as it is not native)

(I'll look into other docs and submit corrections to
them separately)


----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=683416&group_id=5470