Title: bytearray undocumented on trunk
Type: enhancement Stage: resolved
Components: Documentation Versions: Python 2.7
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: pitrou Nosy List: brian.curtin, docs@python, eric.araujo, georg.brandl, ipatrol, l0nwlf, mark.dickinson, pebolle, pitrou
Priority: normal Keywords: patch

Created on 2010-04-07 23:22 by brian.curtin, last changed 2010-11-20 19:37 by pitrou. This issue is now closed.

File name Uploaded Description Edit
functions.patch l0nwlf, 2010-04-10 22:08 This patch backports 'bytearray' and 'byte' documentation review
Messages (9)
msg102576 - (view) Author: Brian Curtin (brian.curtin) * (Python committer) Date: 2010-04-07 23:22
It looks like the bytearray documentation wasn't backported when the bytearray code was. See Doc/library/functions.rst
msg102796 - (view) Author: Shashwat Anand (l0nwlf) Date: 2010-04-10 22:01
On a related note, the documentation of 'bytes' is not backported too.
msg102798 - (view) Author: Shashwat Anand (l0nwlf) Date: 2010-04-10 22:08
Attached a patch to backport the 'bytearray' and 'bytes' documentation in trunk.
msg102799 - (view) Author: √Čric Araujo (eric.araujo) * (Python committer) Date: 2010-04-10 22:10
> * If it is a *string*, you must also give the *encoding* (and optionally,
> *errors*) parameters; :func:`bytearray` then converts the string to
>     bytes using :meth:`str.encode`.

I think this needs some lines to tell how it behaves with str and unicode.

msg108259 - (view) Author: Mark Dickinson (mark.dickinson) * (Python committer) Date: 2010-06-21 09:19
This affects 2.6 as well, doesn't it?
msg108262 - (view) Author: Mark Dickinson (mark.dickinson) * (Python committer) Date: 2010-06-21 11:48
Ideally, there should be documentation of 'bytes' and 'bytearray' in the 'Built-in Types' section of the library manual, too.  (library/stdtypes.rst).
msg108293 - (view) Author: Antoine Pitrou (pitrou) * (Python committer) Date: 2010-06-21 18:09
'bytes' is an alias for 'str' in 2.x, so it shouldn't be "documented" separately.
As for bytearray, yes, it should be added if not present.
msg111515 - (view) Author: (ipatrol) Date: 2010-07-25 00:37
Yeah, I'll say. I prefer bytearray to back-and-forth mapping with chr and ord. I use it particularly as a mid-step in working with binary representations of strings. Please backport these docs with changes reflecting 2.x's paradigms.
msg121735 - (view) Author: Antoine Pitrou (pitrou) * (Python committer) Date: 2010-11-20 19:37
Done in r86602.
Date User Action Args
2010-11-20 19:37:26pitrousetstatus: open -> closed
resolution: fixed
messages: + msg121735

stage: patch review -> resolved
2010-10-15 15:26:25georg.brandlsetassignee: docs@python -> pitrou
2010-10-15 11:10:10pebollesetnosy: + pebolle
2010-08-07 20:25:40terry.reedysetstage: needs patch -> patch review
versions: - Python 2.6
2010-07-25 00:37:41ipatrolsettype: behavior -> enhancement

messages: + msg111515
nosy: + ipatrol
2010-06-21 18:09:26pitrousetnosy: + pitrou
messages: + msg108293
2010-06-21 11:48:45mark.dickinsonsetmessages: + msg108262
2010-06-21 10:26:44eric.araujosetassignee: georg.brandl -> docs@python

nosy: + docs@python
2010-06-21 09:19:50mark.dickinsonsetnosy: + mark.dickinson

messages: + msg108259
versions: + Python 2.6
2010-04-10 22:10:32eric.araujosetnosy: + eric.araujo
messages: + msg102799
2010-04-10 22:08:22l0nwlfsetfiles: + functions.patch
keywords: + patch
messages: + msg102798
2010-04-10 22:01:38l0nwlfsetnosy: + l0nwlf
messages: + msg102796
2010-04-07 23:22:58brian.curtincreate