This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: Better index entry for encoding declarations
Type: enhancement Stage: resolved
Components: Documentation Versions: Python 3.4, Python 3.5, Python 2.7
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: docs@python Nosy List: docs@python, eric.araujo, ezio.melotti, mansam, ncoghlan, python-dev, r.david.murray, terry.reedy
Priority: normal Keywords: easy, patch

Created on 2013-08-02 04:49 by terry.reedy, last changed 2022-04-11 14:57 by admin. This issue is now closed.

Files
File name Uploaded Description Edit
encoding-declarations-index.patch mansam, 2014-04-14 17:25 review
Messages (5)
msg194152 - (view) Author: Terry J. Reedy (terry.reedy) * (Python committer) Date: 2013-08-02 04:49
Three related doc change proposals. The Versions only apply to the third as the first two are for PEP 8.

1. PEP 8 has a section entitled "Encodings (PEP 263)" with a link to the verbose PEP. I think it would be better if it were "Source Encoding" with a link to the 'current' Reference Manual section 2.1.4. Encoding declarations. The latter gets right to the point.

2. This section twice uses the informal and undefined term 'coding cookie'. It is not in the ref manual section above, nor in the glossary, nor in the index. (Dave Angel asked about the definition on python-list. Before searching on the web, he first thought it meant BOM.) I suggest changing "a coding cookie" to "an encoding declaration".

3. The index has several entries that begin with 'encode', including one that just says 'encodings'. The last is the one that points to 2.1.4., but one would only guess by process of elimination. I think 'encoding (source file)' or 'encoding declarations (source file)' would be clearer.
msg194174 - (view) Author: Nick Coghlan (ncoghlan) * (Python committer) Date: 2013-08-02 10:32
I changed the section heading in PEP 8 to "Source File Encoding" and the sole remaining use of "a coding cookie" to "an encoding declaration". No link, since it would need separate links for Python 2 and 3, and that just gets messing. Now it uses the right terminology, it should be easier to look up.

So, this is now just a regular docs bug for Terry's third point about the (lack of a suitable) index entry :)
msg216125 - (view) Author: Sam Lucidi (mansam) * Date: 2014-04-14 17:25
Here's a patch which changes the entry in the index to "encoding declarations (source file)" per Terry's third point.
msg216639 - (view) Author: Roundup Robot (python-dev) (Python triager) Date: 2014-04-17 01:58
New changeset 0413e0b1f76d by R David Murray in branch '3.4':
#18628: clarify index entry for source file encoding declaration.
http://hg.python.org/cpython/rev/0413e0b1f76d

New changeset 7c2dcb18146c by R David Murray in branch 'default':
Merge: #18628: clarify index entry for source file encoding declaration.
http://hg.python.org/cpython/rev/7c2dcb18146c

New changeset 2a793df32be5 by R David Murray in branch '2.7':
#18628: clarify index entry for source file encoding declaration.
http://hg.python.org/cpython/rev/2a793df32be5
msg216644 - (view) Author: R. David Murray (r.david.murray) * (Python committer) Date: 2014-04-17 02:15
Thanks, Sam.
History
Date User Action Args
2022-04-11 14:57:48adminsetgithub: 62828
2014-04-17 02:15:14r.david.murraysetstatus: open -> closed

nosy: + r.david.murray
messages: + msg216644

resolution: fixed
stage: patch review -> resolved
2014-04-17 01:58:21python-devsetnosy: + python-dev
messages: + msg216639
2014-04-14 18:00:48eric.araujosetnosy: + eric.araujo
stage: needs patch -> patch review

versions: + Python 3.5, - Python 3.3
2014-04-14 17:25:44mansamsetfiles: + encoding-declarations-index.patch

nosy: + mansam
messages: + msg216125

keywords: + patch
2013-08-08 16:45:37ezio.melottisetkeywords: + easy
nosy: + ezio.melotti
type: enhancement
2013-08-02 10:32:14ncoghlansetassignee: ncoghlan -> docs@python
messages: + msg194174
title: PEP 8 and encodings -> Better index entry for encoding declarations
2013-08-02 10:20:55ncoghlansetassignee: docs@python -> ncoghlan
2013-08-02 04:49:44terry.reedycreate