maxarnold / serato-itch-sync

Automatically exported from code.google.com/p/serato-itch-sync
0 stars 0 forks source link

Sync moved tracks to new folder #21

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
What program (itch vs. scratch live) you are using, and what version?
- Scratch Live & Itch

What version of the itch sync tool you are using?
- Latest as of 11.24.2010

On what operating system?
- Mac

- When Syncing the a Hard Drive to Mirror in the program it works great!  If 
you add new music it will add those new tracks to the correct folder...  But I 
noticed if you move songs around to different folders and re-sync, it then ass 
the tracks in the new folders but does not remove them from the previous 
folders and still shows up in the old folders which is playable.

Since there is a way of syncing all folders with the program, is there a way 
that if you add new music but also move tracks around to new folders, it will 
update those folders and also update the folders it previously was in to not 
show it in there anymore? 

Original issue reported on code.google.com by mich...@djmichaelpaul.com on 24 Nov 2010 at 11:27

GoogleCodeExporter commented 8 years ago
Very serious issue when using this tool. Will try to help out there...

Original comment by marc.log...@gmail.com on 5 Jan 2011 at 12:16

GoogleCodeExporter commented 8 years ago
Let's start with good news first.

If you think about it, it's essentially a request for "delete orphan tracks" 
feature. E.g. let's assume you have crates "A" & "B" (stored in A.crate and 
B.crate respectively) and "All" view which is stored in "database V2" file that 
is automatically generated by Serato. Once you move a track from folder "A" to 
folder "B" and run the sync, the tool will re-generate and overwrite A.crate 
and B.crate files so the crates should be be just fine. The problem is that 
"database V2" file will not get updated by Serato automatically, and "All" view 
will show some of the files in red.

The bad news is that it's not that easy to fix, as you have to re-generate 
"database V2" file.

Right now the tool supports optional flag 
"music.library.itch.clear-before-sync=true". That deletes "database V2" file, 
so the next time you run Serato it will re-generate it. That fixes the problem 
with "Red" tracks, but I believe you can lose some configuration in this way 
(e.g. played/not played flags for tracks, set of displayed columns in the 
browser, their order, etc).

So, ideally the tool should be updating "database V2" file in a somewhat 
"gentle" way, preserving all user settings. It will obviously require reading 
this file (which is stored like a regular crate), extracting relevant 
information, and writing the updated version back to the disk. Right now the 
tool does only write/replace stuff for crates... no real reading. There is some 
experimental code for reading ".crate" files in place, but it obviously needs 
to be polished.

A lot of room for research & coding this in a very safe and reliable way... We 
need to make sure that whatever we are doing with "database V2", it won't get 
corrupted.

Hope that helps :) You may want to play with Serato & the tool (also, using the 
option "music.library.itch.clear-before-sync=true") to check that my words are 
really accurate

Original comment by raleksee...@gmail.com on 5 Jan 2011 at 11:36

GoogleCodeExporter commented 8 years ago
Another problematic use case could be related to the crate files themselves, 
and not to the "All" view. That is renaming the folder.

E.g. you rename folder 'A' to folder 'B' and run the sync, it will correctly 
create B.crate but leave A.crate in place, so crate 'A' will be messed up.

Original comment by raleksee...@gmail.com on 5 Jan 2011 at 12:07

GoogleCodeExporter commented 8 years ago
Thanks for insights. Got them all and understand the problem here. We really 
need to get technical specs from Serato. Its so annoying to code inside the 
format and only wild guessing things, but even if we dont get the specs, its 
manageable.

I will need some more time playing with the code when it comes to create writes 
and reads. This is by far the most complex stuff in the project.

Original comment by marc.log...@gmail.com on 6 Jan 2011 at 1:09

GoogleCodeExporter commented 8 years ago
Thank you, let me know any updates.. :)

Original comment by mich...@djmichaelpaul.com on 13 Jan 2011 at 2:56