Opened 7 years ago

Last modified 2 years ago

#3035 reopened bug

Extractor issues with .rar archives of the same name that have a Subs folder

Reported by: HollowMan Owned by: HollowMan
Priority: major Milestone: Future
Component: Plugin Version: 1.3.12
Keywords: Cc:

Description (last modified by Cas)

There's a really weird behavior where torrents that have the a Subs folder and a multipart .rar archive, will have the .rar file overwritten by the one from the Subs folder if it has the same name. Example:

Movie.2017.unrated.1080p.bluray.x264
|_ movie.2017.unrated.1080p.bluray.x264.rar 140MB
|_ movie.2017.unrated.1080p.bluray.x264.r01 140MB
|_ movie.2017.unrated.1080p.bluray.x264.r02 140MB
|_Subs
   |_ movie.2017.unrated.1080p.bluray.x264.rar 3MB
   |_ movie.2017.unrated.1080p.bluray.x264.idx 3MB

The 3MB .rar file from the Subs folder will override the 140MB .rar file from the main folder no matter how many Re-Checks you do. It downloads 140MB then it deletes it and replaces it with the 3MB file. This happens all the time.

Tested on Ubuntu 16.04.2 and Debian Jessie with: deluged: 1.3.12 libtorrent: 1.0.7.0

It's utterly annoying as i

Attachments (4)

broken.png (36.0 KB) - added by HollowMan 7 years ago.
An example of file structure
p1.png (190.9 KB) - added by HollowMan 7 years ago.
Deluge List
p2.png (105.1 KB) - added by HollowMan 7 years ago.
Directory list
fix.diff (645 bytes) - added by fumu-no-kagomeko 6 years ago.
Patch (git diff)

Download all attachments as: .zip

Change History (19)

Changed 7 years ago by HollowMan

An example of file structure

comment:1 Changed 7 years ago by Cas

  • Description modified (diff)

comment:2 Changed 7 years ago by Cas

Are you talking about downloading or extracting? In that png screenshot the rar files have completely different names and in a folder so I don't see how it can be overwriting it.

Have you got any plugins or scripts that could be the actual culprit here?

Can you provide actual evidence of this overwriting/replacing and an example torrent file.

comment:3 Changed 7 years ago by HollowMan

The only plugins that i am using are Extractor and Label.

So it downloads all the files, but if there is a file with the same name but in a different folder it will overwrite the one in the root folder with the one from the specific folder.

I do not understand why it's doing this but it happened for me both on Debian 8 and Ubuntu 16.

Changed 7 years ago by HollowMan

Deluge List

Changed 7 years ago by HollowMan

Directory list

comment:4 Changed 7 years ago by HollowMan

I've added pictures to demonstrate what i am talking about. This is how it looks like after the Extractor plugin has finished it's job. Look at those 2 archive names in the Directory List

get.out.2017.bdrip.x264-sparks.rar Get.Out.2017.BDRip.x264-SPARKS.rar

The one with uppercase is the name of the file from the subs archive.

I just now understood what actually happens. The plugin extracts the sub archive rar in the same folder as the Movie and then it replaces the original file.

Is there any way to avoid this ?

comment:5 Changed 7 years ago by Cas

  • Component changed from Unknown to Plugin
  • Milestone changed from needs verified to 1.3.15
  • Priority changed from critical to major
  • Summary changed from DelugeD issues with .rar archives of the same name that have a Subs folder! to Extractor issues with .rar archives of the same name that have a Subs folder

Thanks. I'll need to look into the code to understand what it's doing with the rar files

comment:6 Changed 7 years ago by Cas

  • Milestone changed from 1.3.15 to 1.3.16

Ticket retargeted after milestone closed

comment:7 Changed 7 years ago by HollowMan

Easiest way to fix this is to extract only the archives found in the torrent root dir and not do it recursively for all the folders in the torrent.

comment:8 Changed 6 years ago by fumu-no-kagomeko

From what _ understood by glancing at the code, the destination directory is the same for all extracted files.

Here, a quick fix. It should work.

_ can’t test it because _ don’t know of any such torrents.

Changed 6 years ago by fumu-no-kagomeko

Patch (git diff)

comment:9 Changed 6 years ago by HollowMan

I'll give it a try ty!

comment:10 Changed 5 years ago by int3l

  • Owner set to HollowMan
  • Status changed from new to assigned

comment:11 Changed 5 years ago by int3l

Waiting for feedback from user.

comment:12 Changed 5 years ago by HollowMan

Hi,

I've stopped using Deluge a few months ago, but i didn't encounter the issue anymore.

comment:13 Changed 5 years ago by int3l

  • Resolution set to Fixed
  • Status changed from assigned to closed

comment:14 Changed 5 years ago by Cas

  • Resolution Fixed deleted
  • Status changed from closed to reopened

This was not fixed in the Deluge code so is still an issue

comment:15 Changed 2 years ago by Cas

  • Milestone changed from 1.3.16 to Future
Note: See TracTickets for help on using tickets.