[Python-3000-checkins] r60100 - python/branches/py3k/Lib/pydoc.py
georg.brandl
python-3000-checkins at python.org
Sat Jan 19 21:44:32 CET 2008
Author: georg.brandl
Date: Sat Jan 19 21:44:32 2008
New Revision: 60100
Modified:
python/branches/py3k/Lib/pydoc.py
Log:
#1867: fix a few 3.0 incompatibilities in pydoc.
Modified: python/branches/py3k/Lib/pydoc.py
==============================================================================
--- python/branches/py3k/Lib/pydoc.py (original)
+++ python/branches/py3k/Lib/pydoc.py Sat Jan 19 21:44:32 2008
@@ -1946,9 +1946,9 @@
def send_document(self, title, contents):
try:
self.send_response(200)
- self.send_header('Content-Type', 'text/html')
+ self.send_header('Content-Type', 'text/html; charset=UTF-8')
self.end_headers()
- self.wfile.write(html.page(title, contents))
+ self.wfile.write(html.page(title, contents).encode('utf-8'))
except IOError: pass
def do_GET(self):
@@ -1974,7 +1974,7 @@
return '<a href="%s.html">%s</a>' % (name, name)
names = filter(lambda x: x != '__main__',
sys.builtin_module_names)
- contents = html.multicolumn(names, bltinlink)
+ contents = html.multicolumn(list(names), bltinlink)
indices = ['<p>' + html.bigsection(
'Built-in Modules', '#ffffff', '#ee77aa', contents)]
More information about the Python-3000-checkins
mailing list