|
From: <mi...@us...> - 2023-06-27 20:04:28
|
Revision: 9415
http://sourceforge.net/p/docutils/code/9415
Author: milde
Date: 2023-06-27 20:04:25 +0000 (Tue, 27 Jun 2023)
Log Message:
-----------
Remove compatibility hacks `nodes.reprunicode` and `nodes.ensure_str()`.
They are not required with Python 3.x.
Modified Paths:
--------------
trunk/docutils/HISTORY.txt
trunk/docutils/RELEASE-NOTES.txt
trunk/docutils/docutils/nodes.py
Modified: trunk/docutils/HISTORY.txt
===================================================================
--- trunk/docutils/HISTORY.txt 2023-06-27 20:04:16 UTC (rev 9414)
+++ trunk/docutils/HISTORY.txt 2023-06-27 20:04:25 UTC (rev 9415)
@@ -33,6 +33,10 @@
.. _UTF-8 mode: https://docs.python.org/3/library/os.html#utf8-mode
.. _input encoding: docs/api/publisher.html#encodings
+* docutils/nodes.py
+
+ - Remove compatibility hacks `nodes.reprunicode` and `nodes.ensure_str()`.
+
* docutils/parsers/rst/directives/tables.py
- Use the same CSV format for the ``:header:`` option and the main data
Modified: trunk/docutils/RELEASE-NOTES.txt
===================================================================
--- trunk/docutils/RELEASE-NOTES.txt 2023-06-27 20:04:16 UTC (rev 9414)
+++ trunk/docutils/RELEASE-NOTES.txt 2023-06-27 20:04:25 UTC (rev 9415)
@@ -111,9 +111,6 @@
* Remove `parsers.rst.directives.CSVTable.HeaderDialect`
in Docutils 0.22.
-* Remove the compatibility hacks `nodes.reprunicode` and `nodes.ensure_str()`
- in Docutils 0.21 or later. They are not required with Python 3.x.
-
* Remove file ``install.py`` in Docutils 0.21.
See README.txt__ for alternatives.
@@ -206,7 +203,9 @@
* Use the same CSV format for the ``:header:`` option and the main data
of the "csv-table_" directive.
+* Remove the compatibility hacks `nodes.reprunicode` and `nodes.ensure_str()`.
+
Release 0.20.1 (2023-05-17)
===========================
Modified: trunk/docutils/docutils/nodes.py
===================================================================
--- trunk/docutils/docutils/nodes.py 2023-06-27 20:04:16 UTC (rev 9414)
+++ trunk/docutils/docutils/nodes.py 2023-06-27 20:04:25 UTC (rev 9415)
@@ -326,27 +326,6 @@
return None
-class reprunicode(str):
- """
- Deprecated backwards compatibility stub. Use the standard `str` instead.
- """
- def __init__(self, s):
- warnings.warn('nodes.reprunicode() is not required with Python 3'
- ' and will be removed in Docutils 0.21 or later.',
- DeprecationWarning, stacklevel=2)
- super().__init__()
-
-
-def ensure_str(s):
- """
- Deprecated backwards compatibility stub returning `s`.
- """
- warnings.warn('nodes.ensure_str() is not required with Python 3'
- ' and will be removed in Docutils 0.21 or later.',
- DeprecationWarning, stacklevel=2)
- return s
-
-
# definition moved here from `utils` to avoid circular import dependency
def unescape(text, restore_backslashes=False, respect_whitespace=False):
"""
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|