Friday, 16 August 2013

New iTunes Problem :(

A new problem within iTunes is beginning to emerge. I don't know how widespread it is, and I cannot say for sure what it would take for users to observe it. It does not affect all users by any means, but seems capable of suddenly appearing. For example, none of our 30-odd member Beta Testers Team has reported seeing it, and only one system here at BitPerfect exhibits this behaviour, and did not do so as recently as one month ago.

For BitPerfect users, the symptoms are that snippets of tracks keep repeating in short 3-5 second loops, similar to the behaviour when iTunes 11.0.3 first came out and we had to release a BitPerfect update in response. Whereas that previous problem had a known cause, and affected all tracks all the time, the current problem is more erratic, has been traced to an observable flaw in the behaviour of iTunes, though its root cause has not as yet been identified. You can easily observe it yourself when BitPerfect is not even running, if you know where to look, and you have at least one track that systematically displays this behaviour.

When this looping/skipping starts, it can last for a few seconds or longer. For instance, one user reports that it lasts for about one minute at the start of a track and then goes away, and comes back again a few tracks later. Some users report that it affects AIFF tracks and not AAC tracks. Others report that it affects 24/96 tracks and not 16/44.1 tracks. Another user can make the problem go away by placing the affected tracks in a small playlist. Yet another reports that files seem to start becoming "infected", and once affected will always play this way, and that the "infected" list grows slowly. But don't fret - this is most assuredly not a Virus.

Here is what is happening. Internally, iTunes is not updating its own track position slider. So when BitPerfect asks iTunes for the position of the track position slider it gets back the wrong answer. As we know, BitPerfect interprets this as meaning that the user has intentionally moved the track position slider, and so this will generally cause BitPerfect to re-start playback at the erroneous position, which is usually at a point 3 - 5 seconds earlier in playback, hence the loops. This problem is not caused by the BitPerfect/iTunes communication itself, which can be proved by quitting BitPerfect and playing back the same tracks using plain iTunes. If you keep a very close eye on the track position slider, you will see that it fails to correctly update itself from time to time. Had BitPerfect been in charge of playback at those instants it would have created a loop/skip.

We have reported this to Apple, but we don't know whether or not they are responding. Apple is a big black hole when it comes to this sort of thing. What we do know is that the pre-release beta of iTunes 11.1 (which we are currently evaluating) exhibits the same behaviour, so a solution at the root appears nowhere in sight,

Here at BitPerfect we are trying to come up with an appropriate fix for this. We think we know how to address it, and will release an update as soon as possible.