R. David Murray added the comment:

I agree that the documentation is not optimal.  To give you some background, 
binascii was primarily implemented to support the email module, and the 
standard it is referring to is in fact the MIME standard that references base64 
(I believe at the time the independent base64 standard did not exist).  The 
number 57 is derived from the fact that 57 * 4/3 = 76; that is, input data of 
length 57 will result in an encoded line that is equal to the maximum 
recommended line length.  Thus in encoding an email the email package 
(originally, it no longer does this) passed the data in in 57 byte chunks and 
appended the resulting lines to the output buffer.

So, this documentation is historically correct, but no longer particularly 
useful.  Suggested improvements are welcome.  

This state of affairs exists because the binascii module doesn't really have a 
current maintainer. Someday I'd love to have enough time to pick it up, since I 
maintain email and it is still used by email (and could be used better, with 
some module improvements).

----------
nosy: +r.david.murray

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

Reply via email to