forked from pool/python-Markdown
Compare commits
13 Commits
Author | SHA256 | Date | |
---|---|---|---|
d09a3e6e64 | |||
0193a563ad | |||
eaf8707cae | |||
2d42a03a66 | |||
5daa561e1e | |||
dcdc2c70c4 | |||
d6daaaf0cd | |||
4f1bd75d98 | |||
922a912ff1 | |||
ec68754c9b | |||
30849af1cb | |||
bdd43dead0 | |||
5db14d974b |
@@ -1,54 +0,0 @@
|
|||||||
From 15346cd3a73f108bf11c57907b32737f8365d6bd Mon Sep 17 00:00:00 2001
|
|
||||||
From: facelessuser <faceless.shop@gmail.com>
|
|
||||||
Date: Mon, 21 Jul 2025 08:56:43 -0600
|
|
||||||
Subject: [PATCH] Fix failing cases for Python 3.14
|
|
||||||
|
|
||||||
New change requires us to monkey patch `locatetagend` to prevent
|
|
||||||
capturing incomplete tags in code spans.
|
|
||||||
---
|
|
||||||
docs/changelog.md | 6 ++++++
|
|
||||||
markdown/htmlparser.py | 14 ++++++++++++++
|
|
||||||
2 files changed, 20 insertions(+)
|
|
||||||
|
|
||||||
Index: markdown-3.8.2/docs/changelog.md
|
|
||||||
===================================================================
|
|
||||||
--- markdown-3.8.2.orig/docs/changelog.md 2025-06-19 19:12:28.000000000 +0200
|
|
||||||
+++ markdown-3.8.2/docs/changelog.md 2025-08-12 21:13:46.980036183 +0200
|
|
||||||
@@ -10,6 +10,12 @@
|
|
||||||
[Python Version Specification]: https://packaging.python.org/en/latest/specifications/version-specifiers/.
|
|
||||||
See the [Contributing Guide](contributing.md) for details.
|
|
||||||
|
|
||||||
+## [Unreleased]
|
|
||||||
+
|
|
||||||
+### Fixed
|
|
||||||
+
|
|
||||||
+* Fix handling of incomplete HTML tags in code spans in Python 3.14.
|
|
||||||
+
|
|
||||||
## [3.8.2] - 2025-06-19
|
|
||||||
|
|
||||||
### Fixed
|
|
||||||
Index: markdown-3.8.2/markdown/htmlparser.py
|
|
||||||
===================================================================
|
|
||||||
--- markdown-3.8.2.orig/markdown/htmlparser.py 2025-06-19 19:12:28.000000000 +0200
|
|
||||||
+++ markdown-3.8.2/markdown/htmlparser.py 2025-08-12 21:13:46.980214669 +0200
|
|
||||||
@@ -69,6 +69,20 @@
|
|
||||||
)?
|
|
||||||
\s* # trailing whitespace
|
|
||||||
""", re.VERBOSE)
|
|
||||||
+htmlparser.locatetagend = re.compile(r"""
|
|
||||||
+ [a-zA-Z][^`\t\n\r\f />]* # tag name
|
|
||||||
+ [\t\n\r\f /]* # optional whitespace before attribute name
|
|
||||||
+ (?:(?<=['"\t\n\r\f /])[^`\t\n\r\f />][^\t\n\r\f /=>]* # attribute name
|
|
||||||
+ (?:= # value indicator
|
|
||||||
+ (?:'[^']*' # LITA-enclosed value
|
|
||||||
+ |"[^"]*" # LIT-enclosed value
|
|
||||||
+ |(?!['"])[^>\t\n\r\f ]* # bare value
|
|
||||||
+ )
|
|
||||||
+ )?
|
|
||||||
+ [\t\n\r\f /]* # possibly followed by a space
|
|
||||||
+ )*
|
|
||||||
+ >?
|
|
||||||
+""", re.VERBOSE)
|
|
||||||
|
|
||||||
# Match a blank line at the start of a block of text (two newlines).
|
|
||||||
# The newlines may be preceded by additional whitespace.
|
|
@@ -1,25 +1,3 @@
|
|||||||
-------------------------------------------------------------------
|
|
||||||
Thu Aug 21 09:30:43 UTC 2025 - Markéta Machová <mmachova@suse.com>
|
|
||||||
|
|
||||||
- Convert to libalternatives on SLE-16-based and newer systems only
|
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
|
||||||
Tue Aug 12 18:28:43 UTC 2025 - Matej Cepl <mcepl@cepl.eu>
|
|
||||||
|
|
||||||
- Add fix-py314.patch to fix failing tests on 3.14.* or 3.13.6+
|
|
||||||
(gh#Python-Markdown/markdown#1547).
|
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
|
||||||
Wed Aug 6 18:16:02 UTC 2025 - Benoît Monin <benoit.monin@gmx.fr>
|
|
||||||
|
|
||||||
- set the minimum version of setuptools to 77.0 to match upstream
|
|
||||||
pyproject.toml
|
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
|
||||||
Fri Jul 11 10:56:26 UTC 2025 - Markéta Machová <mmachova@suse.com>
|
|
||||||
|
|
||||||
- Convert to libalternatives
|
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Thu Jun 19 19:01:44 UTC 2025 - Benoît Monin <benoit.monin@gmx.fr>
|
Thu Jun 19 19:01:44 UTC 2025 - Benoît Monin <benoit.monin@gmx.fr>
|
||||||
|
|
||||||
|
@@ -2,7 +2,6 @@
|
|||||||
# spec file for package python-Markdown
|
# spec file for package python-Markdown
|
||||||
#
|
#
|
||||||
# Copyright (c) 2025 SUSE LLC
|
# Copyright (c) 2025 SUSE LLC
|
||||||
# Copyright (c) 2025 SUSE LLC and contributors
|
|
||||||
#
|
#
|
||||||
# All modifications and additions to the file contributed by third parties
|
# All modifications and additions to the file contributed by third parties
|
||||||
# remain the property of their copyright owners, unless otherwise agreed
|
# remain the property of their copyright owners, unless otherwise agreed
|
||||||
@@ -17,6 +16,7 @@
|
|||||||
#
|
#
|
||||||
|
|
||||||
|
|
||||||
|
%{?sle15_python_module_pythons}
|
||||||
%global flavor @BUILD_FLAVOR@%{nil}
|
%global flavor @BUILD_FLAVOR@%{nil}
|
||||||
%if "%{flavor}" == "test"
|
%if "%{flavor}" == "test"
|
||||||
%define psuffix -test
|
%define psuffix -test
|
||||||
@@ -26,12 +26,6 @@
|
|||||||
%define psuffix %{nil}
|
%define psuffix %{nil}
|
||||||
%bcond_with test
|
%bcond_with test
|
||||||
%endif
|
%endif
|
||||||
%if 0%{?suse_version} > 1500
|
|
||||||
%bcond_without libalternatives
|
|
||||||
%else
|
|
||||||
%bcond_with libalternatives
|
|
||||||
%endif
|
|
||||||
%{?sle15_python_module_pythons}
|
|
||||||
Name: python-Markdown%{psuffix}
|
Name: python-Markdown%{psuffix}
|
||||||
Version: 3.8.2
|
Version: 3.8.2
|
||||||
Release: 0
|
Release: 0
|
||||||
@@ -41,29 +35,21 @@ Group: Development/Languages/Python
|
|||||||
URL: https://python-markdown.github.io/
|
URL: https://python-markdown.github.io/
|
||||||
Source: https://files.pythonhosted.org/packages/source/m/markdown/markdown-%{version}.tar.gz
|
Source: https://files.pythonhosted.org/packages/source/m/markdown/markdown-%{version}.tar.gz
|
||||||
Patch0: markdown-3.0-python37.patch
|
Patch0: markdown-3.0-python37.patch
|
||||||
# PATCH-FIX-UPSTREAM fix-py314.patch gh#Python-Markdown/markdown#1547 mcepl@suse.com
|
|
||||||
# Fix failing cases for Python 3.14
|
|
||||||
Patch1: fix-py314.patch
|
|
||||||
BuildRequires: %{python_module base >= 3.8}
|
BuildRequires: %{python_module base >= 3.8}
|
||||||
BuildRequires: %{python_module importlib-metadata >= 4.4 if %python-base < 3.10}
|
BuildRequires: %{python_module importlib-metadata >= 4.4 if %python-base < 3.10}
|
||||||
BuildRequires: %{python_module pip}
|
BuildRequires: %{python_module pip}
|
||||||
BuildRequires: %{python_module setuptools >= 77.0}
|
BuildRequires: %{python_module setuptools}
|
||||||
BuildRequires: %{python_module wheel}
|
BuildRequires: %{python_module wheel}
|
||||||
BuildRequires: fdupes
|
BuildRequires: fdupes
|
||||||
BuildRequires: python-rpm-macros
|
BuildRequires: python-rpm-macros
|
||||||
Requires: (python-importlib-metadata >= 4.4 if python-base < 3.10)
|
|
||||||
BuildArch: noarch
|
|
||||||
%if %{with libalternatives}
|
|
||||||
BuildRequires: alts
|
|
||||||
Requires: alts
|
|
||||||
%else
|
|
||||||
Requires(post): update-alternatives
|
|
||||||
Requires(postun): update-alternatives
|
|
||||||
%endif
|
|
||||||
%if %{with test}
|
%if %{with test}
|
||||||
BuildRequires: %{python_module Markdown = %{version}}
|
BuildRequires: %{python_module Markdown = %{version}}
|
||||||
BuildRequires: %{python_module PyYAML}
|
BuildRequires: %{python_module PyYAML}
|
||||||
%endif
|
%endif
|
||||||
|
Requires: (python-importlib-metadata >= 4.4 if python-base < 3.10)
|
||||||
|
Requires(post): update-alternatives
|
||||||
|
Requires(postun): update-alternatives
|
||||||
|
BuildArch: noarch
|
||||||
%python_subpackages
|
%python_subpackages
|
||||||
|
|
||||||
%description
|
%description
|
||||||
@@ -101,9 +87,6 @@ supported by the [Available Extensions][].
|
|||||||
%postun
|
%postun
|
||||||
%python_uninstall_alternative markdown_py
|
%python_uninstall_alternative markdown_py
|
||||||
|
|
||||||
%pre
|
|
||||||
%python_libalternatives_reset_alternative markdown_py
|
|
||||||
|
|
||||||
%files %{python_files}
|
%files %{python_files}
|
||||||
%license LICENSE.md
|
%license LICENSE.md
|
||||||
%doc README.md docs/*
|
%doc README.md docs/*
|
||||||
|
Reference in New Issue
Block a user