New submission from Antoine Pitrou <pit...@free.fr>:

In issue39681 we reestablished the fallback to read() when a file-like object 
doesn't provide readinto() in _pickle.c.  However, doing so leads to lower 
performance and all file-like object should nowadays provide readinto() (simply 
by deriving from the right base class - e.g. io.BufferedIOBase).

I propose to issue a DeprecationWarning when the fallback behaviour is 
selected, so that one day we can finally remove it.

----------
components: Library (Lib)
messages: 362547
nosy: ogrisel, pierreglaser, pitrou
priority: low
severity: normal
status: open
title: Deprecate readinto() fallback path in _pickle.c
type: enhancement
versions: Python 3.9

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue39734>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to