• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: iTunes and persistent ID
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: iTunes and persistent ID


  • Subject: Re: iTunes and persistent ID
  • From: has <email@hidden>
  • Date: Sat, 26 Aug 2006 09:48:18 +0100

Dave Dribin wrote:

The dictionary has an "item" class with "persistent ID" property.
This can be used to lookup tracks and playlists, even when things get
rearranged.  From what I can tell, this property was introduced in
the dictionary somewhat recently, version 6.0.2 from various Google
searches.  Can anyone confirm what version of iTunes this property
was introduced in?

The 'persistent ID' property is in iTunes 6.0.2, but not in iTunes 6.0.1.



Note that persistent IDs are completely unreliable in AppleScript. AppleScript's integer type have 30-bit precision; anything bigger gets mapped to AppleScript's real type, which is limited to 52-bit precision. Persistent IDs are 64-bit integers so AppleScript throws away the bottom twelve bits when mapping them to reals. That means different IDs can (and often do) appear as the same number in AS.


Persistent IDs are safe to use in C and in Python+appscript, however, as those correctly preserve the original 64-bit value. Not sure about Perl+Mac::Glue; you'd need to check.


HTH

has
--
http://freespace.virgin.net/hamish.sanderson/


_______________________________________________ Do not post admin requests to the list. They will be ignored. Applescript-users mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
  • Follow-Ups:
    • Re: iTunes and persistent ID
      • From: Dave Dribin <email@hidden>
    • Re: iTunes and persistent ID
      • From: Emmanuel <email@hidden>
  • Prev by Date: Re: Desktop Picture not persist across reboot
  • Next by Date: Re: iTunes and persistent ID
  • Previous by thread: Re: iTunes and persistent ID
  • Next by thread: Re: iTunes and persistent ID
  • Index(es):
    • Date
    • Thread