From 606c97c59b4f50d8025b3b2946f6f8a4942c5fb9 Mon Sep 17 00:00:00 2001 From: Scott Worley Date: Sat, 30 Dec 2023 03:37:44 -0800 Subject: [PATCH] =?utf8?q?Rename:=20html=20=E2=86=92=20dom?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- paperdoorknob.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/paperdoorknob.py b/paperdoorknob.py index 6a55675..05b068f 100644 --- a/paperdoorknob.py +++ b/paperdoorknob.py @@ -38,9 +38,9 @@ def process(spec: Spec) -> None: \\newcommand{\\href}[2]{#2\\footnote{#1}} ''') url = flatURL(spec.url) - html = parse(spec.htmlfilter(spec.fetcher.fetch(url))) - num_chunks = ilen(chunkDOMs(html)) - for i, r in enumerate(chunkDOMs(html)): + dom = parse(spec.htmlfilter(spec.fetcher.fetch(url))) + num_chunks = ilen(chunkDOMs(dom)) + for i, r in enumerate(chunkDOMs(dom)): percent = 100.0 * i / num_chunks spec.log(f'Processing chunk {i} of {num_chunks} ({percent:.1f}%)\r') spec.domfilter(r) -- 2.44.1