From 6f7438ac73508703a7ef80f04bc1f248d0859f46 Mon Sep 17 00:00:00 2001 From: Jonathan Green Date: Wed, 13 Nov 2024 12:16:13 -0400 Subject: [PATCH] Remove other unnecessary improts --- bin/opds2_odl_import_monitor | 4 ---- bin/opds2_odl_schema_validate | 4 ---- bin/opds2_reaper_monitor | 9 +-------- bin/opds2_schema_validate | 6 +----- 4 files changed, 2 insertions(+), 21 deletions(-) diff --git a/bin/opds2_odl_import_monitor b/bin/opds2_odl_import_monitor index a43955c8ac..d7e0769ba9 100755 --- a/bin/opds2_odl_import_monitor +++ b/bin/opds2_odl_import_monitor @@ -3,17 +3,13 @@ OPDS 2.x + ODL collections.""" -from webpub_manifest_parser.odl import ODLFeedParserFactory - from palace.manager.api.odl.importer import ( OPDS2WithODLImporter, OPDS2WithODLImportMonitor, ) -from palace.manager.core.opds2_import import RWPMManifestParser from palace.manager.scripts.monitor import RunCollectionMonitorScript RunCollectionMonitorScript( OPDS2WithODLImportMonitor, import_class=OPDS2WithODLImporter, - parser=RWPMManifestParser(ODLFeedParserFactory()), ).run() diff --git a/bin/opds2_odl_schema_validate b/bin/opds2_odl_schema_validate index 28ab269d3c..29bf822760 100755 --- a/bin/opds2_odl_schema_validate +++ b/bin/opds2_odl_schema_validate @@ -3,17 +3,13 @@ OPDS import collections.""" -from webpub_manifest_parser.odl import ODLFeedParserFactory - from palace.manager.api.odl.importer import OPDS2WithODLImporter -from palace.manager.core.opds2_import import RWPMManifestParser from palace.manager.core.opds_schema import OPDS2WithODLSchemaValidation from palace.manager.scripts.monitor import RunCollectionMonitorScript import_script = RunCollectionMonitorScript( OPDS2WithODLSchemaValidation, import_class=OPDS2WithODLImporter, - parser=RWPMManifestParser(ODLFeedParserFactory()), ) import_script.run() diff --git a/bin/opds2_reaper_monitor b/bin/opds2_reaper_monitor index dfc73f8c75..bdff395115 100755 --- a/bin/opds2_reaper_monitor +++ b/bin/opds2_reaper_monitor @@ -6,16 +6,10 @@ from collections.abc import Generator from typing import Any, cast from sqlalchemy.orm import raiseload -from webpub_manifest_parser.opds2 import OPDS2FeedParserFactory from palace.manager.core.coverage import CoverageFailure from palace.manager.core.metadata_layer import TimestampData -from palace.manager.core.opds2_import import ( - OPDS2API, - OPDS2Importer, - OPDS2ImportMonitor, - RWPMManifestParser, -) +from palace.manager.core.opds2_import import OPDS2API, OPDS2Importer, OPDS2ImportMonitor from palace.manager.scripts.input import CollectionInputScript from palace.manager.sqlalchemy.model.collection import Collection from palace.manager.sqlalchemy.model.edition import Edition @@ -28,7 +22,6 @@ def main(): importer_class=OPDS2Importer, monitor_class=OPDS2ReaperMonitor, protocol=OPDS2Importer.NAME, - parser=RWPMManifestParser(OPDS2FeedParserFactory()), ) reaper_script.run() diff --git a/bin/opds2_schema_validate b/bin/opds2_schema_validate index 117118bdb7..0e1936e333 100755 --- a/bin/opds2_schema_validate +++ b/bin/opds2_schema_validate @@ -2,10 +2,7 @@ """Update the circulation manager server with new books from OPDS import collections.""" - -from webpub_manifest_parser.opds2 import OPDS2FeedParserFactory - -from palace.manager.core.opds2_import import OPDS2Importer, RWPMManifestParser +from palace.manager.core.opds2_import import OPDS2Importer from palace.manager.core.opds_schema import OPDS2SchemaValidation from palace.manager.scripts.opds_import import OPDSImportScript @@ -13,7 +10,6 @@ import_script = OPDSImportScript( importer_class=OPDS2Importer, monitor_class=OPDS2SchemaValidation, protocol=OPDS2Importer.NAME, - parser=RWPMManifestParser(OPDS2FeedParserFactory()), ) import_script.run()