From 2a249662d3ace0cf1c76720cfc9e5afe3f7146f1 Mon Sep 17 00:00:00 2001 From: jonathan vanasco Date: Mon, 29 Apr 2019 15:29:14 -0400 Subject: [PATCH] adding cgi.escape -> html.escape ; https://github.com/benjaminp/six/issues/159 --- documentation/index.rst | 2 ++ six.py | 1 + 2 files changed, 3 insertions(+) diff --git a/documentation/index.rst b/documentation/index.rst index 675361700..1ac7fb09a 100644 --- a/documentation/index.rst +++ b/documentation/index.rst @@ -614,6 +614,8 @@ Supported renames: +------------------------------+-------------------------------------+---------------------------------------+ | ``html_entities`` | :mod:`py2:htmlentitydefs` | :mod:`py3:html.entities` | +------------------------------+-------------------------------------+---------------------------------------+ +| ``html_escape`` | :func:`py2:cgi.escape` | :func:`py3:html.escape` | ++------------------------------+-------------------------------------+---------------------------------------+ | ``html_parser`` | :mod:`py2:HTMLParser` | :mod:`py3:html.parser` | +------------------------------+-------------------------------------+---------------------------------------+ | ``http_client`` | :mod:`py2:httplib` | :mod:`py3:http.client` | diff --git a/six.py b/six.py index 47ecf52bd..2286f8411 100644 --- a/six.py +++ b/six.py @@ -236,6 +236,7 @@ class _MovedItems(_LazyModule): MovedAttribute("cStringIO", "cStringIO", "io", "StringIO"), MovedAttribute("filter", "itertools", "builtins", "ifilter", "filter"), MovedAttribute("filterfalse", "itertools", "itertools", "ifilterfalse", "filterfalse"), + MovedAttribute("html_escape", "cgi", "html", "escape", "escape"), MovedAttribute("input", "__builtin__", "builtins", "raw_input", "input"), MovedAttribute("intern", "__builtin__", "sys"), MovedAttribute("map", "itertools", "builtins", "imap", "map"),