#1078576 lektor: please update lektor so that python3-mistune0 can be removed

Package:
src:lektor
Source:
src:lektor
Submitter:
Alexandre Detiste
Date:
2024-09-05 12:57:04 UTC
Severity:
normal
Tags:
#1078576#5
Date:
2024-08-12 21:55:08 UTC
From:
To:
Please switch to regular, alive, python3-mistune.

Greetings

#1078576#12
Date:
2024-09-05 12:56:10 UTC
From:
To:
Hello,

 > Please switch to regular, alive, python3-mistune.

I looked into upgrading to the Lektor v3.4.x series today, which adds
support for mistune 2.

Unfortunately, python3-mistune already ships mistune 3, and Lektor
doesn't support it. It supports only mistune 0 or 2.

See https://github.com/lektor/lektor/issues/1156

In addition, Lektor doesn't build at all with mistune 3 because of
serious API changes between 2 and 3, for example:

ImportError while loading conftest
'/<<PKGBUILDDIR>>/.pybuild/cpython3_3.12_lektor/build/tests/conftest.py'.
tests/conftest.py:12: in <module>
     import lektor.project
lektor/project.py:12: in <module>
     from lektor.environment import Environment
lektor/environment/__init__.py:26: in <module>
     from lektor.markdown import Markdown
lektor/markdown/__init__.py:33: in <module>
     from lektor.markdown.mistune2 import MarkdownController2 as
controller_class
lektor/markdown/mistune2.py:74: in <module>
     class MarkdownController2(MarkdownController):
lektor/markdown/mistune2.py:93: in MarkdownController2
     PLUGINS = {**mistune.PLUGINS}
E   AttributeError: module 'mistune' has no attribute 'PLUGINS'

Until Lektor ships a markdown controller that supports mistune 3, or
Debian ships a mistune 2 package, I'm afraid it won't be possible to
keep Lektor in testing.