fix #96
This commit is contained in:
@ -1,7 +1,8 @@
|
||||
from msilib.schema import File
|
||||
from pathlib import Path
|
||||
from typing import Set, Tuple, Optional, Union, List
|
||||
|
||||
from qbittorrentapi import TorrentFilesList
|
||||
|
||||
from app import schemas
|
||||
from app.core.config import settings
|
||||
from app.core.metainfo import MetaInfo
|
||||
@ -188,7 +189,7 @@ class QbittorrentModule(_ModuleBase):
|
||||
"""
|
||||
return self.qbittorrent.start_torrents(ids=hashs)
|
||||
|
||||
def torrent_files(self, tid: str) -> Optional[List[File]]:
|
||||
def torrent_files(self, tid: str) -> Optional[TorrentFilesList]:
|
||||
"""
|
||||
获取种子文件列表
|
||||
"""
|
||||
|
@ -1,9 +1,8 @@
|
||||
import time
|
||||
from msilib.schema import File
|
||||
from typing import Optional, Union, Tuple, List
|
||||
|
||||
import qbittorrentapi
|
||||
from qbittorrentapi import TorrentDictionary
|
||||
from qbittorrentapi import TorrentDictionary, TorrentFilesList
|
||||
from qbittorrentapi.client import Client
|
||||
from qbittorrentapi.transfer import TransferInfoDictionary
|
||||
|
||||
@ -266,7 +265,7 @@ class Qbittorrent(metaclass=Singleton):
|
||||
logger.error(f"删除种子出错:{err}")
|
||||
return False
|
||||
|
||||
def get_files(self, tid: str) -> Optional[List[File]]:
|
||||
def get_files(self, tid: str) -> Optional[TorrentFilesList]:
|
||||
"""
|
||||
获取种子文件清单
|
||||
"""
|
||||
|
@ -1,7 +1,8 @@
|
||||
from msilib.schema import File
|
||||
from pathlib import Path
|
||||
from typing import Set, Tuple, Optional, Union, List
|
||||
|
||||
from transmission_rpc import File
|
||||
|
||||
from app import schemas
|
||||
from app.core.config import settings
|
||||
from app.core.metainfo import MetaInfo
|
||||
|
Reference in New Issue
Block a user