Music App: Forcing Synchronization
Pretty much since forever, beaTunes is capable of synchronizing with either a folder-based or an iTunes/Music.app-based music collection. In both cases beaTunes synchronizes its database with what is found either in music files or the iTunes/Music-database—like a smart import (changes originating from beaTunes, on the other hand, are typically written right away). You can imagine that importing whole libraries takes a very long time, especially when they reside on an external or network drive (not recommended). Therefore beaTunes employs some tricks to speed up the process. For the old iTunes XML files, for example, it does a smart diff, not unlike the Unix tool diff. Thus beaTunes is able to detect changes and only import the relevant parts. For folder-based libraries, beaTunes simply looks at the last modification dates of your audio files. If the file has been changed recently, its metadata is re-read.
Now, with macOS 10.15 and the new Music app, doing a diff
is not an option anymore and checking the file system is inefficient. Therefore beaTunes uses a last-modification/hash-based approach, which works really well. It has only one downside: Apple hasn't updated the ITLibrary framework for years. This is the Apple API that must be used to access the Music library. You simply won't find newer properties like loved, movement, or work. This means that just using the recommended Apple API certain changes cannot be detected. However, those properties are available via AppleScript (Apple did a better job here). And this is where forcing synchronization comes into play. When you manually initiate synchronization via the File
menu, and beaTunes 5.2 cannot detect any changes, you are given the option to force synchronization (see screenshot), i.e., to ignore any shortcuts, previous knowledge etc., and re-read all available data. This makes sure that all your play counts, loved flags, etc. reflect the status in the Music app. As you can imagine, the process takes a little longer, so you might not want to do this all the time, but only every now and then.
Labels: Catalina, iTunes, Music, TipsAndTricks