Opened 15 years ago

Closed 15 years ago

Last modified 15 years ago

#702 closed bug (Fixed)

renamed folers rollback to it original name

Reported by: axet Owned by: andar
Priority: major Milestone:
Component: Unknown Version: 1.1.8
Keywords: Cc:

Description

try to rename folder, then restart deluge

Attachments (2)

torrent.torrent (166.6 KB) - added by axet 15 years ago.
example torrent with root folder
7436273c4e53c5daf7621060617838a6902cd4f3.torrent (90.3 KB) - added by axet 15 years ago.
torrent file example

Download all attachments as: .zip

Change History (16)

Changed 15 years ago by axet

example torrent with root folder

comment:1 Changed 15 years ago by axet

sometimes renaming do half-renaming, sometimes renaming do rollback after restart.

here is example torrent.

  1. add torrent as paused state
  2. go to files tab, rename root folder
  3. refresh screen (click to any other torrent, and go back)
  4. you can see two folders with old name and new name in files tab
  5. after restart you can see old name\half old half new names\ new names

tested for 1.1.0

comment:2 Changed 15 years ago by axet

  • Version changed from 1.1.0_RC3 to 1.1.0

each deluge restart you lose one renamed torrent

comment:3 Changed 15 years ago by axet

it should be easy to solve. i have run simple test:

  1. run deluge with one torrent
  2. check state/ folder
  3. rename folder, and quit deluge
  4. and check state/ folder again.

here is output:

[axet@axet-laptop state]$ ll
total 112
-rw-rw-r-- 1 axet axet 10394 2009-01-19 00:24 7436273c4e53c5daf7621060617838a6902cd4f3.fastresume
-rw-rw-r-- 1 axet axet 92487 2009-01-18 21:20 7436273c4e53c5daf7621060617838a6902cd4f3.torrent
-rw-rw-r-- 1 axet axet   909 2009-01-19 18:50 torrents.state
[axet@axet-laptop state]$ ll
total 112
-rw-rw-r-- 1 axet axet 10394 2009-01-19 00:24 7436273c4e53c5daf7621060617838a6902cd4f3.fastresume
-rw-rw-r-- 1 axet axet 92487 2009-01-18 21:20 7436273c4e53c5daf7621060617838a6902cd4f3.torrent
-rw-rw-r-- 1 axet axet   909 2009-01-25 17:18 torrents.state
[axet@axet-laptop state]$

as you can see state is not changed! look like as simple .save option miss.

comment:4 Changed 15 years ago by axet

i check this situation in deluge and libtorrent sources. and found two places:

one is in libtorrent library, it called torrent resume data. you can found code in two functions torrent::read_resume_data/torrent::write_resume_data

library call special field in resume data structure as "mapped_files", which help libtorrent to rename and restore new file names from real file names from original .torrent file.

second place is in deluge, torrent.py make a native call to libtorrent library from def rename_folder / rename_files.

i think deluge forgot to call save resume state.

can anyone confirm this bug, and its location?

comment:5 Changed 15 years ago by andar

  • Resolution set to fixed
  • Status changed from new to closed

comment:6 Changed 15 years ago by anonymous

which release?

comment:7 Changed 15 years ago by anonymous

  • Resolution fixed deleted
  • Status changed from closed to reopened

still persist in 1.1.3

comment:8 Changed 15 years ago by anonymous

  • Version changed from 1.1.0 to 1.1.4

persist in 1.1.4

did you mark it as fixed just for fun?

comment:9 Changed 15 years ago by civmaniac@…

  • Version changed from 1.1.4 to 1.1.7

Issue is still in 1.1.7 Renaming is unusable.

Changed 15 years ago by axet

torrent file example

comment:11 Changed 15 years ago by axet

  • Version changed from 1.1.7 to 1.1.8

comment:12 Changed 15 years ago by andar

  • Resolution set to fixed
  • Status changed from reopened to closed

There have been some recent fixes to libtorrent regarding renaming files and I suspect this would fix the issue you are experiencing. You can test this by using the 1.1.0_RC branch from svn, using libtorrent's RC_0_14 branch from svn or waiting for libtorrent 0.14.5 to be released.

comment:13 Changed 15 years ago by anonymous

does it work for you?

comment:14 Changed 15 years ago by anonymous

andar please do not close not solved bugreports

Note: See TracTickets for help on using tickets.