Deluge starts downloading paused torrent on force re-check

General support for problems installing or using Deluge
Post Reply
greenwich
Member
Member
Posts: 20
Joined: Tue Oct 18, 2011 10:53 pm

Deluge starts downloading paused torrent on force re-check

Post by greenwich »

Deluge starts downloading paused torrent on force re-check.

Steps:
1) Add a new torrent
a. Do not set the directory or file name of existing files.
b. Check "Add In Paused State".

2) Take note of the status of the torrent, it should be: Paused (0.00%)

3) Do a Force Re-Check on the newly added torrent.

Expected occurence: It should return to it's previous status, Paused (0.00%), after finding no files.

What happens: torrent status go from Paused to Downloading.

4 (optional)) You can try pausing it and force Re-Check again, it will start Downloading again.

It's critical that adding and re-checking works when (re-)adding torrents for existing files, because if the directories don't match the user will be in trouble if Deluge starts re-downloading large amounts of data. Knowing the inherent risk, the user will be cautious and add the torrents in a paused state, but this is currently a trap, because the paused state is overridden if the directory (or file name if single file torrent) doesn't match 100%.

Tested with Deluge 1.3.11 and 1.3.6 on Windows 7 x64, both local drives and on mapped samba shares. The initial report/complaint came to my attention from another user on another forum, I did not discover it myself, but I did test to confirm.
lordkappa
New User
New User
Posts: 2
Joined: Fri May 15, 2015 8:21 pm

Re: Deluge starts downloading paused torrent on force re-che

Post by lordkappa »

I can confirm this is still an issue in develop.

I managed to fix the issue for my own install by making the following change to core/torrentmanager.py. Line 967 in develop, search for it in any other version.

Code: Select all

<       if torrent.forcing_recheck:
<            torrent.forcing_recheck = False
<            if torrent.forcing_recheck_paused:
<                torrent.handle.pause()
---
>       if torrent.forcing_recheck:
>           torrent.forcing_recheck = False
>            if torrent.forcing_recheck_paused:
>                torrent.handle.pause()
>                torrent.pause()
I am a C programmer and NOT very familiar with python, but I've tested it in all my normal usage scenarios and it seems to work perfectly.

Disclaimer: I don't understand the inner workings of Deluge well enough to appreciate any downstream consequences of the changes I submitted here.
galneon
Member
Member
Posts: 31
Joined: Mon May 18, 2015 3:24 pm

Re: Deluge starts downloading paused torrent on force re-che

Post by galneon »

Surely this is not intended behavior: immediately starting downloading of a torrent after recheck. It's made my migration from uTorrent far more annoying than it had to be. Especially problematic are large torrents I've downloaded only certain files from. I'd like to be able to recheck, sort by progress, mark what I don't want as "do not download," then resume partial seeding. Instead, if I'm not here to stop it as soon as it finishes rechecking, I have a mixed directory full of fully downloaded files and partially downloaded files with no easy way of getting rid of the partials.
Shryp
Moderator
Moderator
Posts: 521
Joined: Mon Apr 20, 2015 10:20 pm

Re: Deluge starts downloading paused torrent on force re-che

Post by Shryp »

In my test cases if I force recheck on a new torrent it will check, shows downloading for half a second, scrapes the tracker and then pauses again.

Could this be a libtorrent issue and not a deluge issue? I upgraded my libtorrent.
Airbus
New User
New User
Posts: 2
Joined: Mon Sep 01, 2014 9:55 pm

Re: Deluge starts downloading paused torrent on force re-che

Post by Airbus »

It's the worse bug there can be, I just noticed today and I'm in big trouble because of it.

Your software can crash every 5 minutes, it's ok I can change the client. Your software can crash my computer every 5 minutes, it's OK, I can change the client. Your software cannot auto-resume and start downloading paused torrents, someone can easily be banned of his/her favorite privater tracker because of this critical bug.
Post Reply