After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 321742 - iPod playlist support
iPod playlist support
Status: RESOLVED FIXED
Product: banshee
Classification: Other
Component: Device - iPod
1.0.0
Other All
: High enhancement
: 1.4
Assigned To: Kevin Kubasik
Banshee Maintainers
: 354348 (view as bug list)
Depends on: 338057
Blocks:
 
 
Reported: 2005-11-17 18:34 UTC by Giovanni Degani
Modified: 2009-06-09 00:10 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
First work (22.46 KB, patch)
2006-08-09 10:18 UTC, Lukas Lipka
needs-work Details | Review
Update (14.13 KB, patch)
2006-09-13 00:26 UTC, Kevin Kubasik
none Details | Review
Seems to work (16.52 KB, patch)
2006-09-13 03:58 UTC, Kevin Kubasik
none Details | Review
forgot to add new files (23.82 KB, patch)
2006-09-13 05:40 UTC, Kevin Kubasik
none Details | Review
Updated iPod playlist support (18.04 KB, patch)
2006-12-13 05:54 UTC, Kevin Kubasik
none Details | Review
Update, using latest structure (16.58 KB, patch)
2007-01-03 19:41 UTC, Kevin Kubasik
none Details | Review
Modifications to see playlists on ipod when using SVN HEAD 0.13 (10.50 KB, patch)
2007-04-25 03:18 UTC, Trey Ethridge
none Details | Review
This is for 0.13 HEAD. (13.43 KB, patch)
2007-04-29 03:59 UTC, Trey Ethridge
none Details | Review
Working version. Testing needed. (25.56 KB, patch)
2007-05-01 03:36 UTC, Trey Ethridge
none Details | Review

Description Giovanni Degani 2005-11-17 18:34:28 UTC
Would be great to be able to create new playlists and just drag them to the
ipod, and fill the ipod with the contents with this play lists.
So I can create an play lists that is good for "Walkin/Exercise", other, for
reading and etc..so i just drag and drop the playlist into the ipod. updated it,
and im ready.

Other information:
Comment 1 Ruben Vermeersch 2006-04-10 17:26:48 UTC
Moving into the iPod component.
Comment 2 Lukas Lipka 2006-08-09 10:18:49 UTC
Created attachment 70534 [details] [review]
First work

This is my first pass at getting this done. Sorry, but I couldnt finish it soon enough, before leaving to England for the holidays. I'm putting this here if anybody else wants to pick up where I left off. I may get around to finishing it, but it wont be sooner than ~1.5 month from now.
Comment 3 Aaron Bockover 2006-08-09 16:09:38 UTC
Thanks Lukas! Hope to see you back in the ~1.5 months with some more awesome patches :)
Comment 4 Aaron Bockover 2006-09-04 22:19:48 UTC
*** Bug 354348 has been marked as a duplicate of this bug. ***
Comment 5 Kevin Kubasik 2006-09-12 21:49:17 UTC
Any thoughts on the progress of this? The current patch dies in a pretty messy way against CVS HEAD. I would like to help clean this up and finish it, if anyone has a TODO before its inclusion, I wouldn't mind helping out however I can!
Comment 6 Aaron Bockover 2006-09-12 22:58:42 UTC
First would to be getting working against HEAD again. I'd like to target this for inclusion in 0.11.1 or 0.11.2, with 0.11.0 set for release on the 18th (next Monday). Releases are going to start happening quickly.

Do you want to take control of this issue? I'll asign to you if you do.
Comment 7 Kevin Kubasik 2006-09-12 23:28:41 UTC
Let me look at the code a little more and see what needs to be done, I've written a simple plugin for banshee, but thats it for my experience with its codebase. This is pretty deep into things, so it might be over my head, but let me see what I can do ;)
Comment 8 Kevin Kubasik 2006-09-13 00:26:35 UTC
Created attachment 72654 [details] [review]
Update

Ok, this patch should get playlist support building, dunno if it works yet, but its compiles.
Comment 9 Kevin Kubasik 2006-09-13 03:58:59 UTC
Created attachment 72670 [details] [review]
Seems to work

As near as I can tell, this should be working better, It writes playlists to the ipod etc, but has some major ui issues. I'm gonna need some help with that, not super-familiar with gtk, and the UI code is pretty confusing...
Comment 10 Aaron Bockover 2006-09-13 05:13:42 UTC
Kevin: Well, keep playing with it I guess, and ask around on the channel for help, but I'm not going to be able to help too much until after next week's release. 

So far though, it looks good.

I'm setting the target milestone for this for 0.11.2.
Comment 11 Kevin Kubasik 2006-09-13 05:40:58 UTC
Created attachment 72672 [details] [review]
forgot to add new files

Sorry, forgot to include new files in the patch.
Comment 12 Trey Ethridge 2006-12-12 04:37:24 UTC
Is this still being actively worked on?  Can I get a status update?  I really want this feature.  I'm willing to help if needed.
Comment 13 Kevin Kubasik 2006-12-13 04:33:10 UTC
Status is pretty not-exciting. I'm gonna try to get some more work done on merging this tonight, but the chances I get this working are next to none unless I can recruit some help.
Comment 14 Kevin Kubasik 2006-12-13 05:54:00 UTC
Created attachment 78262 [details] [review]
Updated iPod playlist support

Ok, heres a clobbered together second look at this patch.
Limitations/Notes/Known Issues:
1) ONLY syncs current playlists with an ipod (and only Ipods). 
2) Sync is slooooow, and status is not updated, we need to find a way to do this part faster/less resource intensive.
3) Dead code in patch, there are some snippets of code from the old patch that have survived my merging processes through to this patch, they need to be cleaned out.
4) No way to control which playlists are on iPod, all playlist in library are automatically synced. What should happen is the user drags playlist they want to the ipod, or similar.
5) Doesn't handle On-The-Go playlists, on each sync all playlists on the ipod get wiped and then we write all the current playlists, not only is this slow, but it kills all On-The-Go playlists.
6) Generally untested, after writing a few playlists successfully and deleting some , this is more or less untested, so please help harden.

Basically, I'm plenty literate with ipod-sharp and the like, so issues on that end I can work on/with, but I really am just completely befuddled by the banshee interface, its not my cup of tea, however, if a GUI programmer wants to sit down on the IRC with gobby or the like and hammer this out, I would be more than willing to provide the backend support needed to make this work better.
Comment 15 Kevin Kubasik 2007-01-03 19:41:22 UTC
Created attachment 79303 [details] [review]
Update, using latest structure

Let me know, I know it locks up the GUI, and is crash-prone, so we need some hammer time on it, but its much better, and usable.
Comment 16 Alan 2007-01-04 00:34:11 UTC
As for the GUI (I haven't seen how the patch looks), the simplest idea I can think of is to make the "Synchronize iPod" button also be a drop-down menu, like the back and forward buttons in any old modern browser. Just clicking the button would do what it currently does, and the dropdown would have options for specific sources to sync from. It may also be useful to have the button default to the last action, ie, if the playlist "Jogging" was last used for syncing, do that this time, too.
Comment 17 Kevin Kubasik 2007-01-04 02:27:08 UTC
Ok, well, heres a rough idea for how  this works at the moment, its just click and drag. Drag a playlist to the ipod. I have a short screencast, but my computers compiling too much at the moment for me to compress it down. I'll try to upload it for some time tomorrow, 
Comment 18 Josiah Ritchie - flickerfly 2007-02-20 19:31:01 UTC
I increased the Target Milestone because 0.11.4 has passed. I'm assuming this is something we'd like in 0.11.x. I don't know if this is subject to the freeze, but if it is, it will wait for 0.12.x.
Comment 19 Josiah Ritchie - flickerfly 2007-02-20 20:07:23 UTC
A side note, this is one of only two bugs left that were submitted in 2005 or earlier.
Comment 20 Aaron Bockover 2007-02-20 21:00:53 UTC
This will be going in the next series.
Comment 21 Dhruv Bhavsar 2007-04-16 00:52:57 UTC
Ok so please don't jump on me and kill me but how do i incorporate this into banshee. Do i just save the .diff file somewhere or compile it using something. Please explain i Try to learn as much as i can.
Comment 22 Josiah Ritchie - flickerfly 2007-04-23 15:39:50 UTC
Dhruv, you need to use the patch command. Check out this tutorial.

http://www.cpqlinux.com/patch.html
Comment 23 Trey Ethridge 2007-04-25 03:18:27 UTC
Created attachment 86975 [details] [review]
Modifications to see playlists on ipod when using SVN HEAD 0.13

I'm working on this.  This is by no means finished.  Right now, the only thing that I can confirm is working is that you can see your playlists AND the tracks in the playlist.  :-)  You can also drag and drop playlists on the ipod node and they will show up under the ipod node.

For now, that's about it.  I haven't tried sync'ing.  I also noticed that the total number of tracks for the ipod is about 3 times the true amount.  

I hope to post more updates over the next week.
Comment 24 Trey Ethridge 2007-04-29 03:59:09 UTC
Created attachment 87216 [details] [review]
This is for 0.13 HEAD.  

Getting closer.  The patch will copy playlists to the ipod, but you can end up with songs from a playlist added twice.  When you plugin your ipod the total and playlist counts should be correct.

There are a lot of debugging comments in here.  I'm uploading now for safe keeping and so that you guys can see how things are progressing.  I still hope to have this finished in the next week.
Comment 25 Trey Ethridge 2007-05-01 03:36:42 UTC
Created attachment 87303 [details] [review]
Working version.  Testing needed.

I've left in all of my logging that I used for debugging.  From my limited testing it is working.  I expect you guys to find some issues that I missed.  

Please code review and make suggestions.  I know the code can be cleaner and more efficient.  I plan to clean it up, but I wanted to get feedback.  

By the way, I've only tested making manual changes.  I'm not sure how synchronize library will work.  My collection is too large.  I'll need to empty my library so that it will fit on my iPod.  I got a feeling this may be an area that I need to work on still.
Comment 26 Gabriel Burt 2007-05-03 02:01:43 UTC
Style things: use spaces instead of tabs (you do most everywhere but a few places there are tabs).  Be consistent with your if() vs if ()'s.  if () is fine.

Instead of doing the check and showing the dialogs if the user deletes the podcast playlist or tries to name a playlist that, can we have a subclass PodcastIPodPlaylist < IPodPlaylist that doesn't respond to being renamed/deleted?  That way we don't care what they name their playlists.

RemoveTrackFromPlaylists is very inefficient (use events) plus I don't see why removing a track from one playlist should remove it from all of them.

Just my 2c from a quick cursory overview.  I'll try running it and maybe to a deeper review soon.
Comment 27 Trey Ethridge 2007-05-03 14:08:59 UTC
Just a quick comment on the RemoveTrackFromPlaylists method.  I can switch that to event based.  The reason it is there is for the case when a user removes a file from the ipod master playlist.  In which case, I assumed we would remove it from the iPod itself.  That would mean removing it from all playlists too.

The iPod master playlist holds tracks that aren't in any playlist and tracks for each of the songs that are only in playlists.  If the same song shows up in more than one playlist, it is only shown once in the ipod master playlist. 

As for the other suggestions, they all sound good too.  I'll make it happen.

Any other comments/suggestions?

-- Trey
Comment 28 Jeff Simpson 2007-06-04 23:21:11 UTC
This patch does not work for me.

I just checked out the latest SVN and applied the patch. It applied without any errors. I ran banshee and got some debug messages about iPod playlists (Adding iPod playlist 'Playlist Name' to Banshee).

I created a new playlist in banshee, added a few tracks to it, and dragged it to the mounted iPod. Nothing happened. I unmounted and checked the iPod, the new playlist was not added.

I tried this with --debug as well, got no useful information.
Comment 29 Trey Ethridge 2007-06-05 16:40:00 UTC
Jeff, you need to synchronize the ipod.  Right now, the patch only supports synching manual changes.  So, create a playlist, drag it to the ipod, it should show up under the ipod, then click the synchronize button in the top right corner (you can also right click the ipod and select synchronize).  When the dialog pops up asking you if you want to sync the entire library or just your manual changes, then select manual changes.  When it completes, your playlist should be on the ipod along with all the music for that playlist.

I'm planning to fix the issue where it doesn't sync all playlists when the user selects to sync the entire library.  The only other issue that I'm aware of is that the patch doesn't sort the playlists.  I've fixed this in my development code, but I haven't posted an updated patch.

By the way, if this doesn't work, please post some information about your ipod too.  Playlists don't work with ipod shuffles.  I'm sure you know that, but I'm just making sure.
Comment 30 Jeff Simpson 2007-06-05 16:47:55 UTC
The synchronize button was greyed out. I assumed that was because the dragging a
Comment 31 Trey Ethridge 2007-06-05 20:16:47 UTC
This seems like you are having other issues.  I would recommend taking your issue to the mailing list.  I don't want to fill this bug up with more comments that aren't directly related to the issue.  I'll be glad to help you if you post to the mailing list.  Then everyone else can benefit from our discussion.
Comment 32 Karim Hasham 2007-06-21 18:11:50 UTC
I have no idea how to use this patch..
Any help would be appreciated, 

Thanks
Comment 33 Kevin Kubasik 2007-06-26 04:38:20 UTC
hey, download the patch as a file, named something like ipod_patch.diff, then enter the source dir of banshee, copy the patch file into the source directory, then run.

patch -p0 < ipod_patch.diff

and it should work :)
Comment 34 Karim Hasham 2007-06-26 12:26:15 UTC
lol um, I'm a complete noob, how would i download the patch as a file? 
Comment 35 Aloisio Almeida Jr 2007-06-27 18:21:28 UTC
I've tried your patch, it worked for every feature that you described, but I'm experiencing problems during synchronize. The program freezes (I need to kill it in terminal) in step "flushing data to device (may take some time)" or something like that.
Comment 36 Karim Hasham 2007-06-29 05:20:51 UTC
Ok, so i downloaded, by saving link as, i don't know where the source is though, so i just put the patch in every banshee folder and tried to use that command, it always said, file can not be found...continue [n] i typed y and chose each banshee main file in the folder to patch, nothing happened it said it stopped at some lines of code. 

Where would the file im supposed to patch be? and am i downloading in the correct way?, i saved link as, named as u stated and changed the extension.

Again thanks for the help 
Comment 37 Will Farrington 2007-10-01 19:57:09 UTC
Would someone be willing to make sure this patch still works against the current SVN TRUNK?

Getting this into Banshee should be a priority.
Comment 38 Kevin Kubasik 2007-10-02 04:24:59 UTC
Ok, I'm working on merging this with the current trunk and getting some real test data. 

Should have an updated patch later today.
Comment 39 Kevin Kubasik 2007-10-02 09:10:25 UTC
Ok, given how broken ipod support in general is in the current SVN trunk, this is going to have to wait. Once ipod support is restabalized in trunk, I will update and commit a working (and slightly optimized) version of this patch.
Comment 40 Will Farrington 2007-10-02 16:30:48 UTC
(In reply to comment #39)
> Ok, given how broken ipod support in general is in the current SVN trunk, this
> is going to have to wait. Once ipod support is restabalized in trunk, I will
> update and commit a working (and slightly optimized) version of this patch.
> 

What do you mean? My 5g video is working just fine with TRUNK. o_O
Comment 41 Kevin Kubasik 2007-10-02 16:32:41 UTC
What version of ipod-sharp are you using? I think thats what's messing me up.
Comment 42 Kevin Kubasik 2007-10-02 20:22:06 UTC
Ok, when using the release version of ipod-sharp I have solid ipod support. I'm merging the patch now.
Comment 43 Will Farrington 2007-10-02 20:29:02 UTC
(In reply to comment #42)
> Ok, when using the release version of ipod-sharp I have solid ipod support. I'm
> merging the patch now.
> 

Is this in Trunk or in banshee-with-dap-playlists branch?
Comment 44 Kevin Kubasik 2007-10-03 02:50:52 UTC
Ok, there is a rough working implementation of this in trunk, further development should take place there. 
Comment 45 Will Farrington 2007-10-03 03:10:42 UTC
I can confirm the behaviors in the commit log.

I can also confirm that adding a blank playlist, and then adding tracks to the playlist from the iPod achieves expected results (though Banshee does lockup during the sync process).
Comment 46 Andrew Conkling 2008-02-08 04:02:45 UTC
Has this been merged yet?
Comment 47 Andrés G. Aragoneses (IRC: knocte) 2008-02-09 15:20:43 UTC
(In reply to comment #46)
> Has this been merged yet?

Yes:

http://kubasik.net/blog/2007/10/03/banshee-ipod-playlist-support/

BTW, Gabriel Burt confirmed me it's on trunk:

http://svn.gnome.org/viewvc/banshee/trunk/banshee/src/Dap/Banshee.Dap.Ipod/

But maybe this bug was left open because, as the blog post explains, there are still issues related with the patch.
Comment 48 Maciej (Matthew) Piechotka 2008-02-09 16:20:57 UTC
However 'REOPENED' would be much more exact description then NEEDINFO.
Comment 49 Mathijs 2008-06-23 10:27:28 UTC
This still does not seem to work in banshee-1.
Comment 50 Gabriel Burt 2008-09-06 22:05:24 UTC
Over the last few days I added playlist support to iPods, MTP devices, and Mass Storage devices to trunk.  Please svn up and test!

Sorry it took so long, thanks for your patience, patches, and testing!

Note that putting podcast items into the iPod podcast folder isn't working yet.
Comment 51 Andrés G. Aragoneses (IRC: knocte) 2008-12-13 17:52:55 UTC
I figured out I should provide some feedback here, since there hasn't been any comment after Gabriel's one, verifying the feature (sorry for the noise if I shouldn't).

It turns out I haven't been able to test this until now, which is a shame because it seems not to work in all circumstances (I don't see the playlist being replicated in the iPod source when I drag'n'drop it from my Music library). This also seems to have been reported as bug 560970, although it may be more logical to reopen this one...

Regards!
Comment 52 Lu Timdale 2009-06-09 00:10:00 UTC
Tested on version 1.6 beta 1

For ipod nanos, you should be able to select which playlists you want sync'ed. The entire music library doesn't fit on these devices. If you manage this manually, it doesn't copy the playlists, only the songs. And it should warn you that you don't have enough room on the device for the entire library and have the option "Sync Music Library" be greyed out.

The ipod manage window should have
Music Library
  Sync Music Library
x Sync Only these Playlists
       x playlist 1
         playlist 2
       x playlist 3

Songbird has this. This is the only reason I'm using songbird still.