#3041: Execute plugin fails when filename contains two consecutive spaces
-----------------------+----------------------------
 Reporter:  linearray  |      Owner:
     Type:  bug        |     Status:  new
 Priority:  minor      |  Milestone:  needs verified
Component:  Plugin     |    Version:  1.3.15
 Keywords:             |
-----------------------+----------------------------
 The "name" option of a torrent is used for display purposes
 https://github.com/deluge-
 torrent/deluge/blob/develop/deluge/core/torrent.py#L128

 In particular, it appears that several consecutive space (0x20) characters
 are coalesced into one. This can be easily verified by creating a torrent
 file for a file named

 {{{
 Untitled  .txt
 }}}

 (note the two spaces) and then looking at the entry in the torrent list in
 e.g. WebUI, which is
 {{{
 Untitled .txt
 }}}

 (one space).

 The file written to disk, however, retains the original name with two
 spaces. This becomes a problem when using the Execute plugin, because it
 reads the display name https://github.com/deluge-
 
torrent/deluge/blob/develop/deluge/plugins/Execute/deluge/plugins/execute/core.py#L98,
 which then has no relation to the actual filename, rendering it useless
 for all file operations.

 I am not entirely sure where the coalescing happens, perhaps here
 https://github.com/deluge-
 torrent/deluge/blob/develop/deluge/core/torrentmanager.py#L331, neither am
 I sure about the best way to correct this. If the coalescing is
 intentional for display purposes, then the Execute plugin probably should
 not read the name option and instead read the name of the top-most file of
 a torrent.

--
Ticket URL: <http://dev.deluge-torrent.org/ticket/3041>
Deluge <http://deluge-torrent.org/>
Deluge Project

-- 
You received this message because you are subscribed to the Google Groups 
"Deluge Dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/deluge-dev.
For more options, visit https://groups.google.com/d/optout.

Reply via email to