Up to [cvs.NetBSD.org] / pkgsrc / textproc / py-docutils
Request diff between arbitrary revisions
Keyword substitution: kv
Default branch: MAIN
py-docutils: update to 0.21.1.
Release 0.21.1 (2024-04-10)
===========================
The sdist in 0.21 was incomplete
- pypi allows no file replacing
- adding a postrelease suffix "post1": docutils-0.21.post1.tar.gz
works on pypi, but fails with pip because the metadata differs.
But if the metadata is 0.21.post1 pypi makes it a new release.
0.21.1 is the same code except for the version number.
Release 0.21 (2024-04-09)
=========================
* General
- Drop support for Python 3.7 and 3.8.
- Updated build system to use Flit_ (patch #186 by Adam Turner).
Removed ``setup.py``.
- Provide ``rst2*`` "console_scripts" `entry points`_
(without the ``.py`` extension) instead of installing the
``rst2*.py`` front end tools in the binary PATH.
.. _Flit: https://github.com/pypa/flit/
* docs/ref/docutils.dtd
- The <image> element accepts a new attribute "loading".
- Fix definitions (no change to actual behaviour):
* The <math_block> element uses the attribute "xml:space".
* The <raw> element may contain text only (no inline elements).
* The <topic> element uses the "depth" and "local" attributes to
store "contents" directive options when used as placeholder for a
generated table of contents (LaTeX writers with `use_latex_toc`_
setting).
- Documentation fix:
Reference names (``%refname.type`` and ``%refnames.type``)
are whitespace-normalized but **not** always downcased.
* docutils/frontend.py
- Allow `validate_*()` functions to be called with just the "value"
argument but keep the legacy interface for use with optparse.
- New function `frontend.validate_math_output()`.
* docutils/io.py
- Simpler and more secure `input encoding`_ default behaviour:
Do not use the locale encoding as fallback if Python is started in
`UTF-8 mode`_. Stop using "latin1" as second fallback.
Remove BOM (U+FEFF ZWNBSP at start of data) only if the "input_encoding"
configuration setting is None, '', 'utf-8-sig', 'utf-16', or 'utf-32'.
Do not remove other ZWNBSPs.
.. _UTF-8 mode: https://docs.python.org/3/library/os.html#utf8-mode
.. _input encoding: docs/api/publisher.html#encodings
- Auto-close `FileInput.source` in case of reading/decoding errors.
* docutils/languages/, docutils/parsers/rst/languages/
- Mark/Fix mistranslated localizations of the "admonition" directive
name. In Docutils, "admonition" is used as a generic term for
"advice"/"advisory"/"remark", not a reprimand.
- Add support for Georgian language (patch #204 by Temuri Doghonadze).
- Update/complete Catalan translations (patch #203 by Antoni Bella Pérez).
* docutils/nodes.py
- Remove compatibility hacks `nodes.reprunicode` and `nodes.ensure_str()`.
* docutils/parsers/rst/directives/images.py
- New "image" directive option "loading".
* docutils/parsers/rst/directives/tables.py
- Use the same CSV format for the ``:header:`` option and the main data
of the "csv-table" directive.
- Move `parsers.rst.directives.Table.process_header_option()` method
to `parsers.rst.directives.CSVTable`.
* docutils/parsers/rst/states.py
- Don't split inside "< >" when parsing "option groups" (fixes bug #474).
* docutils/parsers/rst/directives/misc.py,
docutils/parsers/rst/directives/tables.py
- Consider the new root_prefix_ setting when including files with
"include", "raw", or "csv-table" directives.
* docutils/utils/math/*
- Use custom exception `utils.math.MathError` instead of
abusing `SyntaxError` for LaTeX math syntax errors.
- Unify interface of LaTeX -> MathML conversion functions.
Improve error reporting.
- Sort ℏ (`\hslash`) as "mathord", not "mathalpha".
* docutils/utils/math/latex2mathml.py
- Generate "MathML Core" to fix rendering with Chromium/Android.
Use CSS rules instead of the deprecated "columnalign" attribute
to style <mtable> as "align" environment.
Use Mathematical Alphanumeric Symbols instead of <mstyle> with
"mathvariant" attribute.
- Use <mi> instead of <mo> for character class "mathord".
- Support "aligned" environment.
- Eliminate side-effect on later import of "tex2unichar".
* docutils/utils/math/mathml_elements.py
- New module defining MathML element classes
(outsourced from latex2mathml.py).
- Base MathML element classes on `xml.etree.ElementTree`.
* docutils/utils/roman.py
- Update to version `1.4 <https://pypi.org/project/roman/4.1/>`__.
Fixes feature-request #95 (license is now ZPL 2.1).
* docutils/utils/smartquotes.py
- Pre-compile regexps once, not with every call of `educateQuotes()`
(patch #206 by Chris Sewell).
- Simplify regexps; skip replacement rules if there is nothing to replace.
* docutils/writers/html4css1/__init__.py
- Support video inclusion via ``<object>`` tags.
* docutils/writers/html5_polyglot/\*.css
- Move MathML styles to "minimal.css" (required for correct rendering).
- Highlight heading of target section also with explicit hyperlink target.
- No additional margins for line-blocks.
* docutils/writers/_html_base.py
- Stop setting the "footnote-reference" class value for footnote references.
Since 0.18, you can use the CSS selector ``[role="doc-noteref"]``.
- Support reading/embedding images also with "file:" URI.
- Warn, if image scaling fails because the image file cannot be read.
- Support video inclusion via ``<video>`` tags
(moved here from writers/html5_polyglot/__init__.py).
- New auxiliary method `HTMLTranslator.uri2imagepath()` ensures the
image file can also be read when CWD and output directory differ.
- Consider the root_prefix_ setting when converting an image URI
to a local filesystem path.
- New `\<image>`_ attribute "loading" overrides image_loading_ setting.
- Embed SVG images as ``<svg>`` instead of data-URI.
Fixes feature-request #100.
- Generate system messages for errors/warnings during the writing stage
(image transformations, math content conversion, ...).
- Close ``<dt>`` element in `depart_term()` to allow a
"definition_list_item" with multiple "terms" (cf. feature-request #60).
- Link to the document "#top" from the ToC heading
(unless toc_backlinks_ is False).
- Transfer `id` attribute from <field> elements to the respective
<field_name> child element to allow cross-references to field-list items
(<field>s are skipped in HTML output).
* docutils/writers/latex2e/__init__.py
- Fix placement of hyperlink target (label) for tables (bug #440).
- More compact LaTeX source for option-lists and description-lists
(no change in output).
* docutils/writers/manpage.py
- Put manual section in .TH in quotes.
- Skip footer to avoid the link to document source in the manpage.
- Add multiple definition list term support, see feature #60.
- Render reference, refid and refuri.
Use of ``.UR`` and ``.UE`` macros for reference markup is too brittle.
- Add preprocessor hinting tbl first line, see bug #477.
- Change tbl-Tables using box option, see bug #475.
- Apply literal block patch #205. Use ``.EE`` and ``.EX`` macros.
Thanks to G. Branden Robinson.
* docutils/writers/odf_odt/__init__.py
- Use context manager for image reading operations.
Catch `URLError` when `urllib.request.urlopen()` fails.
- Convert image URI to path if accessing a local file. Fixes bug #153.
* docutils/writers/s5_html/__init__.py
- Warn if the S5 writer cannot copy the theme files.
- Programmatic customization of theme_url_ setting no longer
overridden by the default for theme_.
* tools/buildhtml.py
- New configuration setting `sources`_.
- Match `prune`_ values with `fnmatch.fnmatch()`.
py-docutils: avoid self-conflict
py-docutils: updatede to 0.15.2
Release 0.15.2:
* docutils/nodes.py
- Fix 366: circular import when docutils nodes is iported before docutils.utils
by putting import docutils.utils into astext.
- Fix 366: as it is done in trunk Commit [r8294], moving the function.
Release 0.15:
* General
- Dropped support for Python 2.4, 2.5, 3.1, and 3.2.
- Infrastructure automation.
* docs/ref/rst/restructuredtext.txt:
- Document rST syntax change: Tokens like :this:example: are now valid
field list names (instead of ordinary text).
* docutils/io.py
- Fix [ 348 ] Since Python 3.4, the 'U' universal newlines mode has been
deprecated (thanks to hugovk).
* docutils/languages/la.py
docutils/parsers/rst/languages/la.py:
- Apply [ 153 ] Korean mappings by Thomas Sungjin Kang.
* docutils/nodes.py
- Fix [ 251 ] system_message.copy() TypeError.
- Element.copy() also copies document, line, and source attributes.
* docutils/parsers/rst/__init__.py:
- Apply [ 152 ] reset default role at end of document.
* docutils/parsers/rst/states.py:
- Allow embedded colons in field list field names.
- Add rawsource attribute for text of inline elements.
* docutils/parsers/rst/directives/html.py:
- Fix bug 281: Remove escaping backslashes in meta directive content.
* docutils/parsers/rst/directives/misc.py:
- Don't convert tabs to spaces, if tab_width is negative in
include directive with code option.
* docutils/parsers/rst/directives/tables.py:
- Apply patch 121: Add "width" option for the table directives.
* docutils/transforms/frontmatter.py:
- Add field name as class argument to generic docinfo fields unconditionally.
* docutils/transforms/references.py:
- Fix bug 331: fixed the "trim" options of the "unicode" directive.
* docutils/utils/__init__.py:
- Deprecate unique_combinations (obsoleted by itertools.combinations).
* docutils/utils/smartquotes.py:
- Fix bug 332: use open quote after whitespace, ZWSP, and ZWNJ.
* docutils/writers/html5_polyglot/
- automatically add HTML5-compatible meta tags for docinfo items
"authors", "date", and "copyright".
* docutils/writers/_html_base.py
- Fix bug 358: Non-breaking space removed from fixed-width literal.
* docutils/writers/latex2e/__init__.py:
- Fix bug 323: spurious \phantomsection and whitespace in
parts['title'].
- Fix bug 324: Invalid LaTeX for table with empty multicolumn cell.
- Fixes to literal block handling.
Release 0.13.1 (2016-12-09)
===========================
* docutils/languages/fa.py
docutils/parsers/rst/languages/fa.py
docutils/languages/la.py
docutils/parsers/rst/languages/la.py:
- Apply [ 133 ] Persian mappings by Shahin Azad.
- Apply [ 135 ] Language modules for Latvian by Alexander Smishlajev
* docutils/nodes.py
- Fix [ 253 ] Attribute key without value not allowed in XML.
* docutils/parsers/
- Apply [ 103 ] Recognize inline markups without word boundaries.
- Enable escaping in embedded URIs and aliases (fixes [ 284 ]).
* docutils/parsers/rst/__init__.py
- Fix [ 233 ] Change the base URL for the :rfc: role.
* docutils/parsers/rst/directives/tables.py
- Apply [ 120 ] tables accept option widths: list of relative widths, 'auto'
or 'grid'.
- Implement feature request [ 48 ]
Add :align: option to the table directives.
Thanks to Takeshi KOMIYA for the patch.
* docutils/parsers/rst/roles.py
- Fix [ 295 ] Class argument for custom role inheriting from math.
* docutils/parsers/rst/tableparser.py
- Really fix [ 159 ] Spurious table column alignment errors.
* docutils/transforms/frontmatter.py
- Add name of generic bibliographic fields as a "classes" attribute value
(after conversion to a valid identifier form).
* docutils/utils/error_reporting.py
- Fix [ 130 ] support streams expectiong byte-strings in ErrorOutput.
* docutils/utils/math/math2html.py
- Add ``\colon`` macro, fix spacing around colons. Fixes [ 246 ].
- New upstream version (additional macros, piecewise integrals and sums).
* docutils/writers/_html_base.py
- New auxiliary module for definitions common to all HTML writers.
* docutils/writers/html5_polyglot/
- New HTML writer generating clean, polyglot_ markup conforming to
`HTML 5`_.
The CSS stylesheets ``minimal.css`` and ``plain.css`` contain required
and recommended layout rules.
* docutils/writers/html4css1/__init__.py
- Add "docutils" to class values for "container" object to address [ 267 ].
- Apply patch [ 119 ] by Anatoly Techtonik: use absolute paths for
``default_stylesheet_path`` and ``default_template_path``.
- Fix [ 266 ] creating labels/class values in description list items.
- Do not use <sup> and <sub> tags inside <pre> (parsed-literal blocks).
- Fix footnotes with content that does not start with a paragraph.
- Use https in default MathJax URL (report Alan G Isaac).
- Outsourcing of common code to _html_base.py.
* docutils/writers/latex2e/__init__.py
- Fix [ 262 ] Use ``\linewidth`` instead of ``\textwidth`` for figures,
admonitions and docinfo.
- Use absolute path for ``default_template_path``.
- Removed deprecated options ``--use-latex-footnotes`` and
``--figure-footnotes``.
- Cleaner LaTeX code for enumerations and literal blocks.
- Use "hyperref" package together with "bookmark" (improved hyperlinking
by the same author).
- Fix [ 286 ] Empty column title cause invalid latex file.
- Fix [ 224 ] Fix rowspan support for tables.
- Let LaTeX determine the column widths in tables with "colwidths-auto".
Not suited for with multi-paragraph cells!
* docutils/writers/odf_odt/__init__.py
- remove decode.encode of filename stored in zip.
* docutils/writers/xetex/__init__.py
- LuaLaTex compatibility: do not load "xunicode".
* tools/
- New front-end ``rst2html5.py``.
* tox.ini
- Test py26, py27, py33 and py34.
To use, install the ``tox`` package via pip or easy_install and use
tox from the project root directory.
.. _polyglot: http://www.w3.org/TR/html-polyglot/
.. _HTML 5: http://www.w3.org/TR/html5/
.. _XHTML 1.0: http://www.w3.org/TR/xhtml1/
Update to 0.12
Also use ALTERNATIVES framework to allow concurrent installation under
multiple pythons.
Release 0.12 (2014-07-06)
=========================
* docs/ref/rst/directives.txt
- Update "math" and "csv-table" descriptions.
* docutils/parsers/rst/directives/images.py
- Fix [258] figwidth="image" generates unitless width value.
* docutils/parsers/rst/states.py
- Improve error report when a non-ASCII character is specified as
delimiter, quote or escape character under Python 2.
Fixes [ 249 ] and [ 250 ].
* docutils/writers/html4css1/__init__.py
- Don't add newline after inline math.
Thanks to Yury G. Kudryashov for the patch.
* docutils/writers/latex2e/__init__.py
- Fix [ 239 ] Latex writer glues paragraphs with figure floats.
- Apply [ 116 ] by Kirill Smelkov. Don't hardcode \large for subtitle.
* docutils/writers/odf_odt/__init__.py
- Apply patch by Jakub Wilk to fix bug [ 100 ].
* test/test_error_reporting.py
- Fix [ 223 ] by removing redundant tests we do not have control over.
* test/test_nodes.py
- Apply [ 115 ] respect fixed 2to3 string literal conversion behavior.