Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

2.5.2 whatsnew document corrupts names, by having broken HTML, at least on the Web. #48335

Closed
drj11 mannequin opened this issue Oct 9, 2008 · 2 comments
Closed

2.5.2 whatsnew document corrupts names, by having broken HTML, at least on the Web. #48335

drj11 mannequin opened this issue Oct 9, 2008 · 2 comments
Assignees
Labels
docs Documentation in the Doc dir type-bug An unexpected behavior, bug, or error

Comments

@drj11
Copy link
Mannequin

drj11 mannequin commented Oct 9, 2008

BPO 4085
Nosy @birkenfeld, @drj11

Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

Show more details

GitHub fields:

assignee = 'https://github.com/birkenfeld'
closed_at = <Date 2008-10-09.09:50:10.357>
created_at = <Date 2008-10-09.09:27:54.447>
labels = ['type-bug', 'docs']
title = '2.5.2 whatsnew document corrupts names, by having broken HTML, at least on the Web.'
updated_at = <Date 2008-10-09.09:50:10.355>
user = 'https://github.com/drj11'

bugs.python.org fields:

activity = <Date 2008-10-09.09:50:10.355>
actor = 'georg.brandl'
assignee = 'georg.brandl'
closed = True
closed_date = <Date 2008-10-09.09:50:10.357>
closer = 'georg.brandl'
components = ['Documentation']
creation = <Date 2008-10-09.09:27:54.447>
creator = 'drj'
dependencies = []
files = []
hgrepos = []
issue_num = 4085
keywords = []
message_count = 2.0
messages = ['74560', '74561']
nosy_count = 2.0
nosy_names = ['georg.brandl', 'drj']
pr_nums = []
priority = 'normal'
resolution = 'wont fix'
stage = None
status = 'closed'
superseder = None
type = 'behavior'
url = 'https://bugs.python.org/issue4085'
versions = ['Python 2.5']

@drj11
Copy link
Mannequin Author

drj11 mannequin commented Oct 9, 2008

Consider the web page:

http://www.python.org/doc/2.5.2/whatsnew/acks.html

(the problem appears throughout the whatsnew document, but that page
happens to be short and have more than one instance).

On my browser, Safari 3.1.2 on Intel OS X 10.4.11, Martin von Löwis has
his name corrupted, as does Lars Gustäbel.

The problem seems to be because whilst the page is encoded in utf-8 the
web server does not transmit a Content-Type header that specifies utf-8:

$ curl -I http://www.python.org/doc/2.5.2/whatsnew/acks.html
HTTP/1.1 200 OK
Date: Thu, 09 Oct 2008 08:51:22 GMT
Server: Apache/2.2.3 (Debian) DAV/2 SVN/1.4.2 mod_ssl/2.2.3 
OpenSSL/0.9.8c mod_wsgi/2.0 Python/2.4.4
Last-Modified: Fri, 22 Feb 2008 12:58:18 GMT
ETag: "12c008-1336-c6b00e80"
Accept-Ranges: bytes
Content-Length: 4918
Content-Type: text/html

Shouldn't that be "Content-Type: text/html; charset=UTF-8"? Yeah,
probably. Shouldn't the browser be using the meta tag in the HTML file
itself? Probably, but your broken HTML is preventing Safari from
parsing the <meta> tag correctly.

Specifically:

$ curl http://www.python.org/doc/2.5.2/whatsnew/acks.html | grep 
rel=.first.
<link rel="first" href="whatsnew25.html" title='What's new in python 
2.5' />

The title attribute of that link element is incorrect. It features a
single-quote inside a single-quoted string. Oopsie. I don't think
Safari should be so mean, but bad HTML is bad HTML.

Taking a local copy and fixing that title attribute (by using double
quotes for example) causes the page to render just fine.

@drj11 drj11 mannequin assigned birkenfeld Oct 9, 2008
@drj11 drj11 mannequin added docs Documentation in the Doc dir type-bug An unexpected behavior, bug, or error labels Oct 9, 2008
@birkenfeld
Copy link
Member

Your analysis is correct -- the HTML is invalid. However, this problem
doesn't occur in new documentation since we don't use the system used
until 2.5 anymore.

@ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Documentation in the Doc dir type-bug An unexpected behavior, bug, or error
Projects
None yet
Development

No branches or pull requests

1 participant