Imports rearrangements, readme reformat, basic stuff.

Smoke tests are 100/100.
This commit is contained in:
2026-05-13 22:13:58 +02:00
parent 3d38ae9633
commit fa24530bc5
13 changed files with 53 additions and 47 deletions
@@ -1,6 +1,6 @@
import importlib.resources
import os
import sys
from importlib.resources import files
from lxml import etree
@@ -52,8 +52,8 @@ class LRFInput(InputFormatPlugin):
self.log.info('Converting XML to HTML...')
with open(str(files('ebook_converter')
.joinpath('data/lrf.xsl'))) as fobj:
with open(importlib.resources.files('ebook_converter') /
'data/lrf.xsl') as fobj:
# TODO(gryf): change this nonsense to etree.parse() instead.
styledoc = etree.fromstring(fobj.read())
media_type = MediaType()