qBittorrent doesn't check existing file(s) when creating task from magnet link #7132

Closed
opened 2026-02-21 18:47:54 -05:00 by deekerman · 9 comments
Owner

Originally created by @fireattack on GitHub (Apr 11, 2018).

Please provide the following information

qBittorrent version and Operating System

4.0.4 on Win 7 x64

What is the problem

When adding a new BT task from magnet link, it doesn't check destination folder for existing file(s). It will just mindlessly redownload from 0%.

Steps to reproduce

  1. Download any torrent and save it to for example D:\.
  2. Finish downloading the file.
  3. Save the Magnet link of this torrent, and remove the task, but keep the file.
  4. add this torrent through Magnet link again (save to the same folder).

What happened:

It restarts and downloads form 0%, despite there is a downloaded file in destination folder already.

What is the expected behavior:

It should check and use partial file(s) in temp folder first. It doesn't happen when you're adding from a .torrent file,

Originally created by @fireattack on GitHub (Apr 11, 2018). **Please provide the following information** ### qBittorrent version and Operating System 4.0.4 on Win 7 x64 ### What is the problem When adding a new BT task from magnet link, it doesn't check destination folder for existing file(s). It will just mindlessly redownload from 0%. ### Steps to reproduce 1. Download any torrent and save it to for example `D:\`. 1. Finish downloading the file. 1. Save the Magnet link of this torrent, and remove the task, but keep the file. 1. add this torrent through Magnet link again (save to the same folder). #### What happened: It restarts and downloads form 0%, despite there is a downloaded file in destination folder already. #### What is the expected behavior: It should check and use partial file(s) in temp folder first. It doesn't happen when you're adding from a .torrent file,
Author
Owner

@HairyPhil commented on GitHub (Apr 13, 2018):

Does it overwrite the existing files?

Do you have "pre-allocate disk space" enabled?

@HairyPhil commented on GitHub (Apr 13, 2018): Does it overwrite the existing files? Do you have "pre-allocate disk space" enabled?
Author
Owner

@fireattack commented on GitHub (Apr 13, 2018):

IIRC (will double check later), it will overwrite existing file, but on block level. I.e. it will not touch existing file unless it finishes a new block, and then only replaces that block.

For an extreme example, if you already have a 100% finished file there, it will try to re-download the whole thing - but at any time, you still have a complete file, because it just keeps replacing finished block with (identical) finished block. The time and net traffic are still wasted, though.

Do you have "pre-allocate disk space" enabled?

No.

@fireattack commented on GitHub (Apr 13, 2018): IIRC (will double check later), it will overwrite existing file, but on block level. I.e. it will not touch existing file unless it finishes a new block, and then only replaces that block. For an extreme example, if you already have a 100% finished file there, it will try to re-download the whole thing - but at any time, you still have a complete file, because it just keeps replacing finished block with (identical) finished block. The time and net traffic are still wasted, though. >Do you have "pre-allocate disk space" enabled? No.
Author
Owner

@HairyPhil commented on GitHub (Apr 13, 2018):

I only use a single download folder (no moving after completion), but for the sake of sharing results, I just copied some files downloaded via another client, found the original magnet links, and qBittorrent worked as expected: correctly detected the existing files, took a few seconds to verify them, then marked the download as 100% complete, and started seeding. v4.0.4 on Windows 10.

@HairyPhil commented on GitHub (Apr 13, 2018): I only use a single download folder (no moving after completion), but for the sake of sharing results, I just copied some files downloaded via another client, found the original magnet links, and qBittorrent worked as expected: correctly detected the existing files, took a few seconds to verify them, then marked the download as 100% complete, and started seeding. v4.0.4 on Windows 10.
Author
Owner

@fireattack commented on GitHub (Apr 17, 2018):

I just realized my initial observation seems to be pretty off. I revised the ticket content and the title.

Sorry for the confusion. @HairyPhil

@fireattack commented on GitHub (Apr 17, 2018): I just realized my initial observation seems to be pretty off. I revised the ticket content and the title. Sorry for the confusion. @HairyPhil
Author
Owner

@fortpolio commented on GitHub (May 13, 2018):

It only happens if you click OK to add the torrent while "Retrieving metadata" is still displayed. This is more likely and easier to reproduce for larger torrents where the metadata takes a few seconds to download.

@fortpolio commented on GitHub (May 13, 2018): It only happens if you click OK to add the torrent while "Retrieving metadata" is still displayed. This is more likely and easier to reproduce for larger torrents where the metadata takes a few seconds to download.
Author
Owner

@fireattack commented on GitHub (May 13, 2018):

I disabled "When adding a torrent - display torrent content and some options", so I didn't click anything.

@fireattack commented on GitHub (May 13, 2018): I disabled "When adding a torrent - display torrent content and some options", so I didn't click anything.
Author
Owner

@fortpolio commented on GitHub (May 13, 2018):

OK, I didn't know about that setting. That must be why you saw it then, something must be going wrong if it loads the metadata after the task is added, rather than in that menu.

@fortpolio commented on GitHub (May 13, 2018): OK, I didn't know about that setting. That must be why you saw it then, something must be going wrong if it loads the metadata after the task is added, rather than in that menu.
Author
Owner

@techdragon commented on GitHub (Feb 16, 2019):

I can confirm similar behavior. I think your correct @fortpolio, I just performed some tests with some deliberate network throttling applied, if I wait for the metadata about the linux iso before I click ok to add the torrent, it functions as expected, however if I dont wait and add the torrent before the metadata is complete, it ignores the existing file and creates a new *.!qB file and begins downloading the content again.

@techdragon commented on GitHub (Feb 16, 2019): I can confirm similar behavior. I think your correct @fortpolio, I just performed some tests with some deliberate network throttling applied, if I wait for the metadata about the linux iso before I click ok to add the torrent, it functions as expected, however if I dont wait and add the torrent before the metadata is complete, it ignores the existing file and creates a new `*.!qB` file and begins downloading the content again.
Author
Owner

@Piccirello commented on GitHub (Aug 4, 2019):

Duplicate of #127

@Piccirello commented on GitHub (Aug 4, 2019): Duplicate of #127
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/qBittorrent#7132
No description provided.