mirror of
https://github.com/RicterZ/nhentai.git
synced 2025-04-19 18:31:24 +02:00
remove img2pdf in requirements
This commit is contained in:
parent
d2e68c6c45
commit
7570b6ae7d
@ -9,7 +9,6 @@ import zipfile
|
||||
import shutil
|
||||
import requests
|
||||
import sqlite3
|
||||
import img2pdf
|
||||
|
||||
from nhentai import constant
|
||||
from nhentai.logger import logger
|
||||
@ -195,6 +194,11 @@ def generate_cbz(output_dir='.', doujinshi_obj=None, rm_origin_dir=False, write_
|
||||
|
||||
|
||||
def generate_pdf(output_dir='.', doujinshi_obj=None, rm_origin_dir=False):
|
||||
try:
|
||||
import img2pdf
|
||||
except ImportError:
|
||||
logger.error("Please install img2pdf package by using pip.")
|
||||
|
||||
"""Write images to a PDF file using img2pdf."""
|
||||
if doujinshi_obj is not None:
|
||||
doujinshi_dir = os.path.join(output_dir, doujinshi_obj.filename)
|
||||
|
@ -4,5 +4,4 @@ BeautifulSoup4>=4.0.0
|
||||
threadpool>=1.2.7
|
||||
tabulate>=0.7.5
|
||||
future>=0.15.2
|
||||
img2pdf>=0.3.6
|
||||
iso8601 >= 0.1
|
||||
|
Loading…
x
Reference in New Issue
Block a user