PEP 400: don't remove deprecated classes in Python 3.4 anymore
This commit is contained in:
parent
b383afd01e
commit
1ebf91d201
16
pep-0400.txt
16
pep-0400.txt
|
@ -61,7 +61,7 @@ Accordingly, this PEP proposes that:
|
|||
3.3;
|
||||
* the legacy codecs.Stream* interfaces, including the streamreader and
|
||||
streamwriter attributes of codecs.CodecInfo be deprecated in Python
|
||||
3.3 and removed in Python 3.4.
|
||||
3.3.
|
||||
|
||||
|
||||
Rationale
|
||||
|
@ -71,10 +71,6 @@ StreamReader and StreamWriter issues
|
|||
''''''''''''''''''''''''''''''''''''
|
||||
|
||||
* StreamReader is unable to translate newlines.
|
||||
* StreamReaderWriter handles reads using StreamReader and writes
|
||||
using StreamWriter (as io.BufferedRWPair). These two classes may be
|
||||
inconsistent. To stay consistent, flush() must be called after each
|
||||
write which slows down interlaced read-write.
|
||||
* StreamWriter doesn't support "line buffering" (flush if the input
|
||||
text contains a newline).
|
||||
* StreamReader classes of the CJK encodings (e.g. GB18030) only
|
||||
|
@ -198,15 +194,11 @@ codecs.open() is kept for backward compatibility with Python 2.
|
|||
Deprecate StreamReader and StreamWriter
|
||||
'''''''''''''''''''''''''''''''''''''''
|
||||
|
||||
Instanciating StreamReader or StreamWriter must raise a
|
||||
DeprecationWarning in Python 3.3. Implementing a subclass doesn't
|
||||
raise a DeprecationWarning.
|
||||
Instanciating StreamReader or StreamWriter must emit a DeprecationWarning in
|
||||
Python 3.3. Defining a subclass doesn't emit a DeprecationWarning.
|
||||
|
||||
codecs.open() will be changed to reuse the builtin open() function
|
||||
(TextIOWrapper).
|
||||
|
||||
EncodedFile(), StreamRandom, StreamReader, StreamReaderWriter and
|
||||
StreamWriter will be removed in Python 3.4 (or maybe later).
|
||||
(TextIOWrapper) to read-write text files.
|
||||
|
||||
.. _Appendix A:
|
||||
|
||||
|
|
Loading…
Reference in New Issue