Commit 57ef63ef authored by Andreas Jung's avatar Andreas Jung

reST ignored the encoding settings in zope.conf

parent f01ca899
......@@ -103,6 +103,8 @@ Zope Changes
Bugs fixed
- reStructuredText ignored the encoding settings in zope.conf
- ObjectManager no longer raises string exceptions
- Collector #1260: Testing/__init__.py no longer changes the
......
......@@ -15,14 +15,14 @@
__all__ = ("HTML", )
import docutils.core
from docutils.io import StringOutput, StringInput
import sys, os
import docutils.core
from docutils.io import StringOutput, StringInput
from App.config import getConfiguration
default_input_encoding = os.environ.get("REST_INPUT_ENCODING",
sys.getdefaultencoding())
default_output_encoding = os.environ.get("REST_OUTPUT_ENCODING",
sys.getdefaultencoding())
default_enc = sys.getdefaultencoding()
default_output_encoding = getConfiguration().rest_output_encoding or default_enc
default_input_encoding = getConfiguration().rest_input_encoding or default_enc
class Warnings:
......@@ -32,7 +32,6 @@ class Warnings:
def write(self, message):
self.messages.append(message)
def HTML(src,
writer='html4zope',
report_level=1,
......@@ -93,8 +92,6 @@ def HTML(src,
# do the format
return pub.writer.write(document, pub.destination)
from docutils import writers
import html4zope
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment