Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7933233
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T21:16:01+00:00 2026-06-03T21:16:01+00:00

I did the following script in order to identify itunes songs that doesn’t have

  • 0

I did the following script in order to identify itunes songs that doesn’t have artwork. It’s based on other script that I found in net.

tell application "iTunes"
   repeat with a in every track of playlist "Library"
      if not (exists (artwork 1 of a)) then
         add (get location of a) to (playlist "noart")
      end if
   end repeat
end tell

It seems to be working, it compiles well, and because I can that it in event log windows:

tell application "iTunes"
    count every track of playlist "Library"
        --> 10684
    exists artwork 1 of item 1 of every track of playlist "Library"
        --> true
    exists artwork 1 of item 2 of every track of playlist "Library"
        --> true

But after 4 hundred tracks, it starts to run slowly, and applescript stops responding after one thousand tracks.

I thought that maybe I could be exhausting my mac memory, but in Activity Monitor, I can see that Applescript is consuming 100% CPU and less than 50MB of memory. I’m running macos 10.7.4 on a macbook pro (i7 with 4GB ram).

As you can see my itunes library has 10684 tracks. It’s not a small library, but it’s not a huge one.

Does anyone has any advice? Or a script to identify tracks without artwork?

TIA,

Bob

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-03T21:16:03+00:00Added an answer on June 3, 2026 at 9:16 pm

    Here’s what I use. My main suggestion would be to use “duplicate” instead of “add” and then you do not need to get the location of a track. Also you’ll see I’m using “a reference to” most things which makes it work faster. I also create the “no artwork” playlist with a time stamp on-the-fly so I can see when I ran the script.

    set d to current date
    set missingTracksCount to 0
    tell application "iTunes"
        set isFixedIndexing to fixed indexing
        if not isFixedIndexing then set fixed indexing to true
    
        -- make a new playlist to hold the tracks
        set newPlaylist to make new playlist
        set name of newPlaylist to "No Art - " & month of d & " " & day of d & " " & time string of d
    
        set mainPlaylist to a reference to playlist "Library"
        set noArtworkPlaylist to a reference to newPlaylist
    
        set trackCount to count of tracks of mainPlaylist
        repeat with i from 1 to trackCount
            set trackRef to (a reference to (track i of mainPlaylist))
            if (count of artworks of trackRef) is less than 1 then
                duplicate trackRef to noArtworkPlaylist
                set missingTracksCount to missingTracksCount + 1
            end if
        end repeat
    
        if not isFixedIndexing then set fixed indexing to isFixedIndexing
    
        display dialog "Finished!" & return & (missingTracksCount as text) & " tracks didn't have artwork." buttons {"OK"} default button 1 with icon note giving up after 5
    end tell
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have an events calendar written in PHP, with the following pagination script that
Did you ever have the following situation: you need to store information, but a
I did my research but haven't found an answer to the following problem: I
f'I have the following: A---B---C-----D-- branch dev \--C'-E-/ branch test I did it bad:
I have a TSQL script that does a lot of database structure adjustments but
I have the following script which works perfectly until I regenerate the links .resultLink
I have the following script which I want to debug: function getTabFrame() { $.ajax({
Trying to follow a technique found at bzr and gitosis I did the following:
Based on the helpful answers I received here , I created the following script,
I have written the following script to get the value of hidden field to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.