Skip to content

Commit 1c3df3e

Browse files
committed
Fix ptp-reseed for non-rtorrent clients
1 parent 3a3abed commit 1c3df3e

3 files changed

Lines changed: 7 additions & 2 deletions

File tree

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
# Changelog
22

3+
## [0.9.1] - 2023-03-28
4+
### Fixed
5+
- `ptp-reseed` now only tries to connect to rtorrent when not using
6+
`--client`
7+
38
## [0.9.0] - 2023-03-28
49
### Added
510
- Utility script for downloading and running archiver.py

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[tool.poetry]
22
name = "PTPAPI"
3-
version = "0.9.0"
3+
version = "0.9.1"
44
description = "A small API for a mildly popular movie site"
55
authors = ["kannibalox <kannibalox@gmail.com>"]
66
repository = "https://github.com/kannibalox/PTPAPI"

src/ptpapi/scripts/ptp_reseed.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -265,7 +265,6 @@ def load_torrent(
265265
ID, path, client=None, hash_check=False, overwrite_incomplete=False
266266
) -> bool:
267267
"""Send a torrent to rtorrent and kick off the hash recheck"""
268-
proxy = pyrosimple.connect().open()
269268
logger = logging.getLogger(__name__)
270269
torrent = ptpapi.Torrent(ID=ID)
271270
torrent_data = torrent.download()
@@ -285,6 +284,7 @@ def load_torrent(
285284
return False
286285
if client is None:
287286
hash_exists = True
287+
proxy = pyrosimple.connect().open()
288288
try:
289289
logger.debug("Testing for hash {0}".format(proxy.d.hash(thash)))
290290
if proxy.d.complete(thash):

0 commit comments

Comments
 (0)