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 642830 - Unable to sync podcasts (Caught an exception - System.NullReferenceException)
Unable to sync podcasts (Caught an exception - System.NullReferenceException)
Status: RESOLVED DUPLICATE of bug 679260
Product: banshee
Classification: Other
Component: Device - iPod
2.4.0
Other Linux
: Normal major
: ---
Assigned To: Banshee Maintainers
Banshee Maintainers
: 647644 650377 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2011-02-20 19:20 UTC by Bruce Pieterse
Modified: 2012-09-23 15:46 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Podcast syncing log file (15.44 KB, text/plain)
2011-02-20 19:20 UTC, Bruce Pieterse
Details
Library syncing log file (13.64 KB, text/plain)
2011-02-20 19:21 UTC, Bruce Pieterse
Details
udevadm info (112.42 KB, text/plain)
2011-02-20 19:39 UTC, Bruce Pieterse
Details
gvfs-mount info (231 bytes, text/plain)
2011-02-20 19:47 UTC, Bruce Pieterse
Details
debug DLL with possible fix v1 (28.00 KB, application/octet-stream)
2012-07-09 01:02 UTC, Andrés G. Aragoneses (IRC: knocte)
Details
debug patch v1 (1.27 KB, text/plain)
2012-07-09 09:51 UTC, Andrés G. Aragoneses (IRC: knocte)
Details
log file v1 (1.84 KB, text/plain)
2012-07-09 13:29 UTC, simon.jantsch
Details
terminal output v1 (26.84 KB, text/plain)
2012-07-09 13:30 UTC, simon.jantsch
Details
screenshot v1 (732.32 KB, image/png)
2012-07-09 13:31 UTC, simon.jantsch
Details

Description Bruce Pieterse 2011-02-20 19:20:46 UTC
Created attachment 181420 [details]
Podcast syncing log file

Hi

I am unable to sync podcasts with my iPod classic 160GB (Late 2009). This problem is currently present with versions 1.8.0, 1.8.1, 1.9.3 and daily builds. Here are the steps to reproduce the error:

1. Start Banshee
2. Connect iPod to PC
3. Click on iPod under devices
4. Change Podcasts from "Manage manually" to "Sync entire library" (also present on manual sync/drag and drop onto device)
5. Click on Sync
6. Device syncs podcasts then writes to media database
7. Disconnect iPod

When the iPod has been disconnected and you then navigate to podcasts on the iPod, there are no podcasts to be found! However the synced podcasts are stored under music and can be found under songs. These podcasts are not playable as Banshee never actually copied the podcasts over to the device (no items under the iPod_Control folder or any other folder).

If you sync the device more than once, Banshee seems to add a duplicate entry for the podcasts being synced. If you look at line 132 in banshee.podcasts.log, the 377 invalid tracks were created with Banshee after 3 syncs with version 1.8.1 and 1.9.3 and the current daily build.

At line 189-191 of banshee.podcasts.log:
Cannot save track to iPod - System.NullReferenceException: Object reference not set to an instance of an object (in `Banshee.Dap.AppleDevice')
  at Banshee.Dap.AppleDevice.AppleDeviceTrackInfo.CommitToIpod (GPod.ITDB database) [0x00000] in <filename unknown>:0 
  at Banshee.Dap.AppleDevice.AppleDeviceSource.PerformSyncThreadCycle () [0x00000] in <filename unknown>:0 

N.B. The above is not present when syncing a music library (see banshee.library.log)

I also noticed at line 90 to 97:
[3 Warn  20:34:50.922] Caught an exception - System.ArgumentNullException: Argument cannot be null.
Parameter name: s (in `mscorlib')
  at System.Int32.Parse (System.String s) [0x00000] in <filename unknown>:0 
  at Banshee.Hardware.Gio.UsbDevice.GetBusNumber (IUsbDevice device) [0x00000] in <filename unknown>:0 
  at Banshee.Hardware.Gio.UsbDevice.get_BusNumber () [0x00000] in <filename unknown>:0 
  at Banshee.Hardware.Gio.Device.ResolveUsbPortInfo () [0x00000] in <filename unknown>:0 
  at Banshee.Dap.Mtp.MtpSource.DeviceInitialize (IDevice device) [0x00000] in <filename unknown>:0 
  at Banshee.Dap.DapService.FindDeviceSource (IDevice device) [0x00000] in <filename unknown>:0

The iPod does not show that it is syncing while Banshee syncs to the device, it just shows that the device is connected.

I have attached two log files for comparison. banshee.podcasts.log is for the above procedure for podcasts and banshee.library.log is for syncing a normal music library.

Please let me know if you require any further information or device testing! I would really like to get this bug fixed :)

========================================
Additional Information
========================================
iPod Software Version: 2.0.4
iPod Model: MC293
Banshee Version: 1.9.3+git20110219.r1.8eb30f4-0ubuntu1+maverick
Comment 1 Bruce Pieterse 2011-02-20 19:21:48 UTC
Created attachment 181421 [details]
Library syncing log file
Comment 2 Bruce Pieterse 2011-02-20 19:39:53 UTC
Created attachment 181422 [details]
udevadm info
Comment 3 Bruce Pieterse 2011-02-20 19:47:19 UTC
Created attachment 181423 [details]
gvfs-mount info
Comment 4 Bruce Pieterse 2011-02-20 19:50:12 UTC
(In reply to comment #0)
========================================
Additional Information
========================================
iPod Color: Silver
iPod Last 3 digits of Serial No.: 9ZS
iPod Model No. (Back cover): A1238
Comment 5 Bruce Pieterse 2011-02-20 21:34:48 UTC
After disconnecting the iPod and reconnecting it, Banshee sometimes shows a normal playlist called "Podcasts".
Comment 6 Bruce Pieterse 2011-02-21 11:07:55 UTC
(In reply to comment #5)
The podcast playlist does not show any synced items.
Comment 7 Mike B. 2011-03-30 02:31:44 UTC
I have this same bug.  I have an older model iPod (second generation
Comment 8 simon.jantsch 2012-07-08 16:11:58 UTC
I also have the same bug
Comment 9 Andrés G. Aragoneses (IRC: knocte) 2012-07-09 00:25:19 UTC
*** Bug 647644 has been marked as a duplicate of this bug. ***
Comment 10 Andrés G. Aragoneses (IRC: knocte) 2012-07-09 00:29:17 UTC
*** Bug 650377 has been marked as a duplicate of this bug. ***
Comment 11 Andrés G. Aragoneses (IRC: knocte) 2012-07-09 00:36:22 UTC
Bringing the people from the duplicated bugs to the CC list... bear with me.

Changing version to 2.4.0 because I know Simon is running that version.

I'm doing this because I'll change this bug soon to NEEDINFO to see if I can fix it.

Also I'm confirming it due to the high number of duplicates and the clear NRE in the logs.
Comment 12 Andrés G. Aragoneses (IRC: knocte) 2012-07-09 01:02:46 UTC
Created attachment 218312 [details]
debug DLL with possible fix v1

Ok, I created a new Banshee.Dap.AppleDevice.dll with a possible fix and more debugging information, can someone test this on their Banshee and let me know if it works? (And post the log regardless)
Comment 13 Andrés G. Aragoneses (IRC: knocte) 2012-07-09 09:51:38 UTC
Created attachment 218321 [details]
debug patch v1

This is the patch that is applied to the DLL above, if anyone prefers to build from source.
Comment 14 simon.jantsch 2012-07-09 13:29:13 UTC
Hello,

I tried it with the new dll, this is what happens:

At first it seems to work, only that it goes very slow. I then decided to remove the older podcasts, because at this speed it would take forever. When klicking stop thogh, it seems that only the particular podcast that is downloaded at the moment stops and the process continues. I figured this out after clicking stop a couple of times, I'm attaching a screenshot of banshee so you can see what I mean.

After waiting a long time banshee seems to have hung up on one podcast and is not doing anything further.

I'm also attaching the log, made with "kill -s QUIT $(pidof banshee); cp ~/.config/banshee-1/log ~/Desktop/banshee.log" and some output in the terminal that I run banshee from, because there doesnt seem to be much in the log file.
Comment 15 simon.jantsch 2012-07-09 13:29:47 UTC
Created attachment 218331 [details]
log file v1
Comment 16 simon.jantsch 2012-07-09 13:30:31 UTC
Created attachment 218332 [details]
terminal output v1
Comment 17 simon.jantsch 2012-07-09 13:31:02 UTC
Created attachment 218333 [details]
screenshot v1
Comment 18 Andrés G. Aragoneses (IRC: knocte) 2012-09-23 15:46:09 UTC
Simon, sorry for getting back to you so late.

Attachment called "log file v1" sadly doesn't contain any useful information.

And "terminal output v1" is really weird because it mentions MassStorageSource, and AppleDeviceSource doesn't inherit from MassStorageSource, so something very wrong must be happening.

Anyway, I was planning on attaching a new debug DLL here for you to test, but I just realized that this is not the correct place to do it, because if I look on the file attached to comment#2 by Bruce, it contains exactly the same exception that was fixed in bug 679260, so I'm going to mark this one as duplicate of that one, even though it's older, because the other one contains the patch that fixed it and is already marked as FIXED.

So, to all people subscribed to this bug: I recommend you to use banshee master branch, or 2.6.0 which will be released in a few days, which should handler this better.

If you find any additional problems with this version, please report any new bugs you find.

*** This bug has been marked as a duplicate of bug 679260 ***