From: Emmanuel V. <emm...@un...> - 2010-05-09 12:02:56
|
On Sun, May 9, 2010 at 1:43 PM, Christophe Fergeau <cfe...@gm...> wrote: > 2010/5/9 Emmanuel Viennet <emm...@un...>: >> (In my preceding posts, I had problems with gtkpod on a new ipod >> classic, and it's unclear if they're related to gtkpod or libgpod. My >> goal being to copy my music library from an ipod to another, I restart >> using Python. We need to copy all tracks but also related metadata: >> tags, iTunes ratings, play counts, last play date, etc.) > > NB: copying artwork might be tricky to get to work if the ipods are > different models > >> >> Unsurprisingly, my first attempt is not successfull: >> >> db1 = gpod.Database( '/media/ipod1') # the old ipod >> db2 = gpod.Database( '/media/ipod2' ) # the new ipod >> >> t = db1[0] # the track to copy >> >> >> db2.add(t) # add to new ipod (is this supposed to work ???) > > I wouldn't expect that to work, I'd start with duplicating "t" and > setting its file path to NULL and copying it or something like that. Can find how to reset the file path. Seams to be read only and accessible via ipod_filename() method. >> 1) When python quit, it crashes ! >> *** glibc detected *** python: free(): invalid pointer: 0x0000000001bb6730 *** >> (traceback omitted) > > Sounds bad... Though a backtrace would be needed ;) One obtained using > valgrind ideally Here attached. Emmanuel |