I made heavy use of the Batch change command in iPhoto.
Now that I'm in Photos, how can I get the same results?
Specifically the Batch change of title....
I made heavy use of the Batch change command in iPhoto.
Now that I'm in Photos, how can I get the same results?
Specifically the Batch change of title....
Posted on Apr 11, 2015 9:47 PM
Apr 12, 2015 12:35 AM
You can't.
http://www.apple.com/feedback/macosx.html is the place for feature requests and feedback
Apr 12, 2015 8:10 AM
To batch change the titles of selected photos to the same title you could try a simple Apple Script and run it with Automator.
Create an Automator action, that prompts you for the new title and executes an Apple Script to change the titles to the name you entered:
I put a copy of the finished workflow into my Dropbox, if you want to try it: https://www.dropbox.com/sh/r6kf61oiktntt3q/AADJtXaEuB38OZY0H0PWEIPfa?dl=0
The Apple Script:
on run {input, parameters}
-- batch chnage the title to the input
tell application "Photos"
activate
set imageSel to (get selection)
if imageSel is {} then
error "Please select some images."
else
repeat with im in imageSel
tell im
set the name to input
end tell
end repeat
end if
end tell
return input
end run
Launch Automator,
Copy and paste the text above into the "Run Apple Script" action to replace the default text in the action.
Save this workflow with a suitable name. It will be installed in the services.
Apr 13, 2015 2:02 PM
.
Apr 13, 2015 11:04 AM
How would you modify the script to put a sequential number at the end, i.e. - 001, - 002, etc.?
And to get the file name and use it?
Apr 13, 2015 2:29 PM
Like this:
I'd add a variable "counter" that will be incremented for each new file. then append this counter to the filename (the "&" operator appends strings and converts numbers to strings)
tell application "Photos"
activate
set imageSel to (get selection) -- get a list of selected images
set counter to 1
set currentfilename to ""
if imageSel is {} then
error "Please select an image."
else
repeat with im in imageSel
set title to the name of im
if not (exists (title)) then
set currentfilename to the filename of im as text -- retrieve the filename of image "Im"
set newname to currentfilename & "." & counter
set counter to counter + 1 -- increment the counter
set the name of im to newname -- write the newname to the title field
end if
end repeat
end if
return currentfilename -- return the filename of the last image
end tell
The spellchecker is continually corrupting the code😟 I hope, I found all "corrections"
Apr 13, 2015 2:36 PM
léonie:
I get this error when running the script:
error "The variable newsman is not defined." number -2753 from "newsman"
What is newsman
Yes, that spellchecker can do make some awful messes at times.
Apr 13, 2015 2:46 PM
I put a link to the original source in my Dropbox:
https://www.dropbox.com/s/a0qj8znhoan0pn1/filename2titlewithnumber.scpt?dl=0
😁 the newsman was not the worst! The spellchecker changed all variable names and changed the name "im" to "I'm"
Apr 13, 2015 2:55 PM
That took care of the error and adds the file name to the Title field. If there's already a title showing it will not replace it.
Thanks so much.
Apr 13, 2015 3:28 PM
Apr 13, 2015 3:35 PM
Apr 13, 2015 3:37 PM
Apr 13, 2015 3:42 PM
Works as advertised this way.
I see you have already a nice collection!
Perhaps I should make a Photos version of my Aperture script, that sets the time of all selected selected photos to the same date, and increments it by a fixed step for each photo, like iPhotos batch change time does. I use that script mainly for scanned slides.
Apr 13, 2015 5:52 PM
Restarting the system was required.
Now I see the service, but I'm getting an error.
Code:
| -- batch change the title to the input |
tell application "Photos"
| activate |
| set counter to 1 |
| set imageSel to (get selection) -- get a list of selected images |
| if imageSel is {} then |
| error "Please select an image." |
| else |
| repeat with im in imageSel |
| set title to the name of im |
| -- if not (exists (title)) then |
| set newname to input & "." & counter |
| set counter to counter + 1 -- increment the counter |
| set the name of im to newname -- write the new title field |
| -- end if |
| end repeat |
| end if |
end tell
return input
end run
What line is in error?
Apr 14, 2015 9:02 AM
In the fragment, that you posted the first line "on run {input, parameters}" is missing, so the variable "input" in the last line "return input" is undefined.
What are you trying to do?
That looks now like a mixture of the first script I posted, to change the title to string, that is read from a user input,
and the second script, that I posted in answer to old Toad's question about setting the title to the filename.
Which of the two batch changes do you want to do?
Apr 14, 2015 11:44 AM
My paste was in error, I did have the first line
"on run {input, parameters}"
But Failed to include it in my last post...
So, where is the error...
If nothing is selected, I do get the statement -- error "Please select an image."
So, with a selection, it does get to the else that follows
Is name a property of im? (an image)
Where can I see the allowed/defined properties of an image?
Thanks
Apr 15, 2015 8:52 AM
Hello,
I followed exactly what you did. I am trying to batch change and append a number to each photo but I keep receiving this error in Photos.
This is my input in the AppleScript.
tell application "Photos"
activate
set imageSel to (get selection) -- get a list of selected images
set counter to 1
set currentfilename to ""
if imageSel is {} then
error "Please select an image."
else
repeat with im in imageSel
set title to the name of im
if not (exists (title)) then
set currentfilename to the filename of im as text -- retrieve the filename of image "Im"
set newname to currentfilename & "." & counter
set counter to counter + 1 -- increment the counter
set the name of im to newname -- write the newname to the title field
end if
end repeat
end if
return currentfilename -- return the filename of the last image
end tell
Apr 15, 2015 11:49 AM
Grumpy4u wrote:
Where can I see the allowed/defined properties of an image?
In the Applescript dictionary for Photos. You can access that through Script Editor (in your Utilities folder). Open Script Editor & from the File menu, choose "Open Dictionary..." then navigate to Photos in your Applications folder & choose it.
Look for the entry in the dictionary for media item (the object type for photos & videos) -- it is part of the Photos Suite. It will look like this, but with better formatting:
media item n : A media item, such as a photo or video.
elements
contained by application, albums, moments.
properties
keywords (list of text) : A list of keywords to associate with a media item
name (text) : The name (title) of the media item.
description (text) : A description of the media item.
favorite (boolean) : Whether the media item has been favorited.
date (date) : The date of the media item
id (text, r/o) : The unique ID of the media item
height (integer, r/o) : The height of the media item in pixels.
width (integer, r/o) : The width of the media item in pixels.
filename (text, r/o) : The name of the file on disk.
altitude (real, r/o) : The GPS altitude in meters.
location (list of real, r/o) : The GPS latitude and longitude, in an ordered list of 2 numbers. Latitude in range -90.0 to 90.0, longitude in range -180.0 to 180.0.
responds to
duplicate.
Apr 15, 2015 10:10 PM
Apr 15, 2015 11:05 PM
The problem is, that your script is a mixture of two scripts -
and the mixture ha undefined variables.
If you want a script to ask for a new image title for all images, but append a number, do this:
https://www.dropbox.com/sh/29exskbyuuffk5h/AAA-CDQ1fonab-TxSjvQBG-Ca?dl=0 (dropbox)
on run {input, parameters}
-- batch chnage the title to the input
tell application "Photos"
activate
set counter to 1
set imageSel to (get selection) -- get selected images
if imageSel is {} then
error "Please select some images."
else
repeat with im in imageSel
tell im
set the name to input & "_" & counter as text
-- set the title to the input plus number
set counter to counter + 1
end tell
end repeat
end if
end tell
return input
end run
Apr 16, 2015 6:55 AM
Apr 16, 2015 7:23 AM
I am having the same problem as you Grumpy4u.
Apr 16, 2015 7:49 AM
@Léonie
Thanks so much for your scripts. They run like a charm. Really happy with this 🙂.
All the Best
Ben
Apr 16, 2015 8:08 AM
Did you set this up as service in Automator, & if so do you have exactly the same 'service receives' settings as léonie shows?
Apr 16, 2015 1:17 PM
Apr 16, 2015 3:09 PM
As a test launch Photos with the Option key held down and create a new, test library. Import some photos and test to see if the same problem persists. Does it?
Apr 16, 2015 8:46 PM
YES !
The test library works properly.
What do I need to reset on my primary library?
Apr 16, 2015 10:10 PM
I did a Photo Library repair, to no avail. It did not resolve the problem.
Apr 17, 2015 8:51 AM
Apr 17, 2015 11:48 AM
.
Apr 17, 2015 12:29 PM
It was the System Photo Library already. It was created by the conversion process that did away with iPhoto.
Apr 17, 2015 3:30 PM
I believe my last post was intended for another topic. 😕
Apr 18, 2015 5:28 AM
Apr 18, 2015 5:41 AM
.
Apr 18, 2015 5:44 AM
Why do you 00004000 have an "Ask for Text" Automator action preceding the "Run Applescript" one?
Apr 18, 2015 6:11 AM
That's the way it was in léonie's post (page 1 of this thread). I don't know much about AppleScript, but it looks like that is how it gets the text for the titles.
-Jay
Apr 18, 2015 6:42 AM
I have scanned through this thread and bottom line is Photos has taken a step back in functionality and can not do what iPhoto did. Running a script to make changes is a solution but a ridiculous amount of work compared to what it used to be in iPhoto.
Apr 18, 2015 7:21 AM
Apr 18, 2015 7:28 AM
Jay Deitch wrote:
That's the way it was in léonie's post (page 1 of this thread). I don't know much about AppleScript, but it looks like that is how it gets the text for the titles.
You are correct about that. Sorry, I confused the batch change script with léonie's other one that sets titles to filenames. (Need more coffee, I guess.) 😊
Apr 18, 2015 8:48 AM
Here's the script I use to change the title on multiple photos while adding a sequential number at the end:
on run {input, parameters}
-- batch chnage the title to the input
tell application "Photos"
activate
set counter to 1
set imageSel to (get selection) -- get selected images
if imageSel is {} then
error "Please select some images."
else
repeat with im in imageSel
tell im
set the name to input & "_" & counter as text
-- set the title to the input plus number
set counter to counter + 1
end tell
end repeat
end if
end tell
return input
end run
This script is courtesy of léonie. It gives your Title-1, Title-2, Title-3, etc. Am trying to modify it so it will give us Title-01, Title-02, etc. so the sort better when in the Finder.
Apr 18, 2015 9:06 AM
Apr 18, 2015 9:11 AM
Apr 18, 2015 12:03 PM
I agree the script should work. But there is a problem.
Look at my posts above. Mine dies on the real library, and only works on a test library I just created.
So that means the problem is not the script, but the library....
And it's not just for me. Jay seems to have the same problem.
I checked out the file protections in a terminal window. My system library (with the problem) and my test library have same protection bits:
| drwxr-xr-x@ 33 dwills staff | 1122 Apr 17 18:29 Photos Library.photoslibrary |
| drwxr-xr-x@ 11 dwills staff | 374 Apr 16 20:51 Test Photos Library.photoslibrary |
ACL settings? where/how do I check?
Apr 18, 2015 12:10 PM
So... I ran it again, and here is the error log:
4/18/15 12:07:04.165 PM WindowServer[169]: disable_update_timeout: UI updates were forcibly disabled by application "Photos" for over 1.00 seconds. Server has re-enabled them.
4/18/15 12:07:05.551 PM WindowServer[169]: common_reenable_update: UI updates were finally reenabled by application "Photos" after 2.39 seconds (server forcibly re-enabled them after 1.00 seconds)
4/18/15 12:07:05.585 PM cloudphotosd[487]: New connection request from 943
4/18/15 12:07:08.633 PM Photos[943]: Received changes notification alert: <LiModelChangeGroup: 0x600000e7d880> alert flags : Replay Complete
4/18/15 12:07:55.014 PM Photos[943]: An exception was thrown during execution of an NSScriptCommand...
4/18/15 12:07:55.014 PM Photos[943]: *** -[__NSArrayM objectAtIndex:]: index 32260 beyond bounds for empty array
This script works fine on the test photo library... What's going on?
Apr 18, 2015 12:14 PM
Another point of possible issue. I DO NOT use iCloud for photo storage.
All Photo preferences for iCloud, are unchecked.
My photo library is 32000 photos, running about 82GB.
My iPhoto library (of same pics) exceeded 112GB.
Apr 18, 2015 12:40 PM
Grumpy4u wrote:
ACL settings? where/how do I check?
You can use the @ switch with the l (el, not the number) one for that, like this:
ls -l@ <path to folder here>
Apr 18, 2015 4:21 PM
Here are the Console messages I get when I run the script. The two at 6:16:49 are when the script is launched, the ones at 6:17:12 are after I enter the text to be used for the title and press Enter:
4/18/15 6:16:49.054 PM Automator Runner[2691]: -[AMApplicationRegistry loadDefinitionAtURL:]: No application name for definition at URL file:///Library/Automator/Office.definition/
4/18/15 6:16:49.054 PM Automator Runner[2691]: -[AMApplicationRegistry _loadDefinitionsAtURLS:]: Failed to load definition at URL file:///Library/Automator/Office.definition/
4/18/15 6:17:12.289 PM Photos[2680]: An exception was thrown during execution of an NSScriptCommand...
4/18/15 6:17:12.289 PM Photos[2680]: *** -[__NSArrayM objectAtIndex:]: index 48243 beyond bounds for empty array
4/18/15 6:17:12.617 PM WorkflowServiceRunner[2690]: WorkflowServiceRunner received error running Workflow Service at /Users/Jay/Library/Services/BatchChangeTitles.workflow: The action “Run AppleScript” encountered an error.
Apr 18, 2015 9:09 PM
Ok, I executed a ls -l@
and I got:
3369181 Photos Library.photoslibrary
4423411 Test Photos Library.photoslibrary
669992 iPhoto Library.migratedphotolibrary
What does it mean?
Apr 19, 2015 12:10 AM
This is just what I was looking for. Thank you very much!
Apr 19, 2015 7:00 AM
to Old Toad...
reading thru this thread, as well as a few others in the last week, there are a number of people having the same problem as me.
What works on a "test" library does not work on my system library.
Is there anyway to elevate this to someone at Apple? It really seems to be a Version 1.0 issue of Photos.
Apr 19, 2015 9:38 AM
Have you tired repairing your system photo library? Launch Photos with the Command+Option keys held down and run the repair.
Otherwise all we can do is ask Apple for this feature via https://www.apple.com/feedback/photos.html
Apr 19, 2015 10:52 AM
Repairing the Photos library didn't fix my batch change problem.
Jay
Apr 19, 2015 11:54 AM
If you have iPhoto 9.6.1 and can run it on your original iPhoto library here's something you can try:
1 - run the First Aid (launch with the Option+Command keys held down) and run Options #1, #2 and #4.
2 - launch Photos with the Option key held down and cover the "fixed" iPhoto Library.
3 - test the batch change title script again.
Apr 19, 2015 3:17 PM
Hi,
I did all that and still get the message "The action 'Run AppleScript' encountered and error." I also tried the script on my laptop (MB Air) except instead of copying the script from this thread, I typed it all in directly - same result. Very strange.
Thanks for your help,
Jay
Apr 22, 2015 1:22 PM
Still trying to get this to run. Does anyone know about sandbox extensions? Here is part of the Console log when the error occurs:
4/22/15 3:16:19.077 PM Photos[789]: __CFPasteboardIssueSandboxExtensionForPath : sandbox extension creation failed: client lacks entitlements? for path: [/Users/Jay/Library/Services/Batch Change Titles.workflow]
4/22/15 3:16:19.077 PM Photos[789]: __CFPasteboardCreateSandboxExtensionDataFromCFData : failed to obtain sandbox extension data for url [file:///Users/Jay/Library/Services/Batch%20Change%20Titles.workflow/]
4/22/15 3:16:19.086 PM sandboxd[177]: ([789]) Photos(789) deny file-issue-extension /Users/Jay/Library/Services/Batch Change Titles.workflow
4/22/15 3:16:19.089 PM Finder[224]: No valid sandbox extension for item: [789514] of flavor: [public.file-url] was created.
4/22/15 3:16:19.089 PM Finder[224]: Failed to get a sandbox extensions for itemIdentifier (789514). The data for the sandbox extension was NULL
4/22/15 3:16:19.139 PM sandboxd[177]: ([789]) Photos(789) deny file-issue-extension /Users/Jay/Library/Services/Batch Change Titles.workflow
4/22/15 3:16:19.141 PM com.apple.xpc.launchd[1]: (com.apple.quicklook[849]) Endpoint has been activated through legacy launch(3) APIs. Please switch to XPC or bootstrap_check_in(): com.apple.quicklook
4/22/15 3:16:20.338 PM sandboxd[177]: ([851]) QuickLookUIHelpe(851) deny file-read-data /Users/Jay/Library/Services/Batch Change Titles.workflow
Thanks,
Jay
Apr 22, 2015 3:37 PM
To get it to run with sandboxing enabled just Control (right) - click on the app and select Open from the contextual menu. From then on it will open normally.
Apr 22, 2015 4:53 PM
Thanks Old Toad,
I opened Photos from the contextual menu, selected a few photos and tried the script from the Services menu. I entered in the new title and then got the same error message. Now the Console shows:
4/22/15 6:47:16.988 PM Photos[1188]: An exception was thrown during execution of an NSScriptCommand...
4/22/15 6:47:16.989 PM Photos[1188]: *** -[__NSArrayM objectAtIndex:]: index 16693 beyond bounds for empty array
Thanks,
Jay
Apr 24, 2015 9:00 AM
No, you can't. HOWEVER, IPHOTO SHOULD STILL BE IN YOUR APPLICATIONS FOLDER!!!
I am very annoyed that the OS update made it appear that my iPhoto (which I purchased with iLife11) was arbitrarily and totally swapped out and VERY annoyed that my photo library was "migrated over" (without my permission or prior notification/warning) to ONLY be compatible with Photos. But even after the update I noted I STILL HAVE iPhoto in my Applications folder. I had to create a new iPhoto Library (Hold down OPTION when launching iPhoto and you will be prompted for the choice) and (whether I choose to export and re-import all my pictures again) all is as it was.
It's okay to be miffed (I sure am) but Apple did not brazenly take iPhoto away like I had at first thought!
Apr 24, 2015 10:34 AM
You didn't have to create a new Library either...
Apr 25, 2015 5:03 AM
Quite true, Devlin! Thank you.
Your OLD iPhoto Library IS still there too but the update seriously messed up my iPhoto library. Thankfully I am a religious TimeMachine user and I simply restored my iPhoto Library to the latest backup prior to the update. So all is good for me now.
I am still looking for ANY reason to ever use or even keep the Photos app on my Mac, it is (kind of) the same thing as iPhoto (and yes it is directly analogous to the iOS Photos) but Photos is a whole LOT less capable. Why Apple would think Pro users would want and to try to force Pro users to use a Tin hammer rather than the Steel one we already have, to me, seems kind of stupid.
There is a good reason I have one iPhone but several Macs. I LIKE my iPhone and appreciate they are trying to make them better- more like Macs are. But I am worried that Apple, in this post-Jobs era, will continue to make my Mac(s) worse so they can be more like my iPhone. I don't WANT my OS X and iOS devices to be the same thing.
May 4, 2015 3:55 AM
Thanks sorted 🙂
Jun 4, 2015 10:57 PM
Same here. I have successfully used many AppleScripts (in iTunes and Finder) and as an IT Consultant I am generally a good troubleshooter. But none of the shared batch scripts for Photos are working for me. Sometimes one photo gets the desired change (but that's rare) and every time, the script then fails with this error:
I have run the database repair on my Photos library, and every other suggestion in this thread. My Photos library is working fine with everything else. It's just thatI have tried these scripts as Automator Services, Scripts and applications, and none of them work. Has anyone else solved this issue? Is there any more information I can provide?
I am running OS X 10.10.3 on a brand new MacBook Pro. What else can I try?
Thanks....
Jun 5, 2015 2:12 AM
I noticed some problems with the script.
- Selecting pictures in an album directly -> run script --> won't work
- Selecting pictures in album "all photo's" --> script works
- Selecting pictures in "Photos" (the one on the top of the list) just after I clicked on an album --> wont't work
- Select pictures in "Photos" afther clicking on album "all photo's" and then on "Photos" --> script will work.
I think there is a bug in the album section.
The script works with this workaround fine for me
Jun 5, 2015
Fofer wrote:
Is there any more information I can provide?
Is your Photos Library in the default location in your Pictures folder or somewhere else? Is it the designated System Photo Library? Do you have more than one Photos Library? What if any iCloud services are you using?
I have no idea if any of these things are relevant but maybe one of them is, or will provide some clue about what is.
FWIW, all the scripts & Automator services I have tried in the User Tips work for me.
Jun 5, 2015 6:08 AM
Is your Photos Library in the default location in your Pictures folder or somewhere else?
Yes. It is in the default location (in ~/Pictures.)
Is it the designated System Photo Library?
Yes.
Do you have more than one Photos Library?
No.
What if any iCloud services are you using?
I have iCloud Photo Library, My Photo Stream, and iCloud Photo Sharing enabled.
Jun 5, 2015 7:47 AM
"Selecting pictures in album "all photo's" --> script works"
Same here! Thanks so much, vbs3. Phew, finally, I'm now getting consistent results, and the scripts are working.
Can this workaround be coded into the script?
Jun 5, 2015 8:28 AM
The problem with all the scripts is, that the line "set imageSel to (get selection)" in the Apple Scripts does not work reliably in Photos. It will give random timeouts and works best in the "All Photos" album. Apple needs to fix this to make scripting more reliable. The errors are more frequently with iCloud Photo Library enabled. When I first posted the scripts I did not use iCloud Photo Library.
There is a work-around proposed by NicFletcher: Don't ask for the current selection, but add the photos you want to process to an album with a fixed name.
Here is a sample Apple Script by NicFletcher that uses this method:
https://discussions.apple.com/thread/6999613?answerId=28087786022#28087786022
Jun 5, 2015 9:40 AM
I noticed some problems with the script.
Which script(s) are you experiencing this with? All of them?
As a test launch Photos with the Option key held down and create a new, test library. Import some photos and test to see if the same problem persists. Does it?
Jun 5, 2015 9:57 AM
Update: just ran a test on another library and had some photos that would not work with the scripts and some in the same batch that would. Repair the library and that fixed those problem photos so they would work with the scripts in whatever window I was in.
Jun 5, 2015 10:55 AM
léonie wrote:
The problem with all the scripts is, that the line "set imageSel to (get selection)" in the Apple Scripts does not work reliably in Photos. It will give random timeouts and works best in the "All Photos" album. Apple needs to fix this to make scripting more reliable. The errors are more frequently with iCloud Photo Library enabled. When I first posted the scripts I did not use iCloud Photo Library.
There is a work-around proposed by NicFletcher: Don't ask for the current selection, but add the photos you want to process to an album with a fixed name.
- Create an album with a fixed name - mycurrentselection or similar - and add all photos you want to process to this album.
- Instead of the "get current selection" process the photos in this album.
Here is a sample Apple Script by NicFletcher that uses this method:
https://discussions.apple.com/thread/6999613?answerId=28087786022#28087786022
Many thanks for this explanation -- it helps a lot!
Jun 5, 2015 11:16 AM
Finally, it becomes clear. Photo is messed up. The script does work on selected pics in the "All Photos" album. I will try the fixed album name next.
I had been trying on selections in the Last Import album. Because the photos were together. They sometimes scatter (by time) when in All Photos.
Jun 5, 2015 11:19 AM
Jun 5, 2015 12:55 PM
léonie wrote:
The problem with all the scripts is, that the line "set imageSel to (get selection)" in the Apple Scripts does not work reliably in Photos. It will give random timeouts and works best in the "All Photos" album. Apple needs to fix this to make scripting more reliable. The errors are more frequently with iCloud Photo Library enabled. When I first posted the scripts I did not use iCloud Photo Library.
Do you (or the others having problems with these batch change scripts) have iCloud Photo Library set to Optimize Mac Storage? I'm wondering if the timeouts in that case might have something to do with selecting items when their originals have not been stored locally & for some reason Photos is connecting to the iCloud Photo Library unnecessarily before adding them to the selection. In that case, the variable time it takes for the network connection to that item might be a factor.
Regarding timeouts in Photos Applescripts in general, someone in the Applescript forum reported that adding a longer than the default 2 minute timeout to repeat loops in Photos improved their reliability. In some of my own Photos scripts experiments (which did not involve getting a selection but looped through every media item), I found it necessary to include a short delay in the loop to get them to work.
I wonder if either of those things would improve the reliability of the User Tip batch scripts.
Jun 5, 2015 1:07 PM
R C-R wrote:
Do you (or the others having problems with these batch change scripts) have iCloud Photo Library set to Optimize Mac Storage?
As mentioned, I have iCloud Photo Library enabled, but the setting is for "Download Originals to this Mac." My local Photos library file is ~80 GB. I was trying to use the batch scripts in photos I had just imported. I'm fairly certain this means the originals were/are, in fact, local on my Mac.
That I am having success using the scripts when in Albums -> "All Photos" but not the first "Photos" tab tells me it's something else at the root here. Probably a bug with Photos 1.0's AppleScriptability...
Jun 5, 2015 2:34 PM
I'm wondering if the timeouts in that case might have something to do with selecting items when their originals have not been stored locally & for some reason Photos is connecting to the iCloud Photo Library unnecessarily before adding them to the selection.
I am using the same iCloud Photo Library on three Macs. The library has 37000 photos and a few videos.
The problem is occurring on all three Macs, and it started after I enabled iCloud Photo Library. I never had the problem with small test libraries.
Two of the Macs are storing the libraries locally, one MacBook Pro is using "Optimise Mac Storage". One Mac is connected to our fast university Ethernet, and at home I am having a fast cable network.
I already repaired the library, and it did not change the problem.
Repairing the library, when it is syncing to iCloud is expensive. I cannot recommend it. Photos will start to upload the full library again to iCloud. I sincerely hope, future updates will make this unnecessary. Repairing libraries used to be a fairly routine fix. Being forced to upload the complete photos library after a simple repair is not acceptable. We have seen reports from OPs, where uploading the library took a whole week or longer.
Jun 6, 2015 11:15 PM
batch change the title to the input, © léonie & Old Toad, version 1.0.1
Jul 2, 2015 4:35 PM
Did you make a script that works in Photos Yosemite to batch change date to sequential as you mentioned later in this thread? This is exactly what I have been looking for! From Hopeful in PV!
Jul 2, 2015 5:08 PM
Did you make a script that works in Photos Yosemite to batch change date to sequential as you mentioned later in this thread?
Do you mean batch change the title to the date with a sequential number attached? If so try this one: Photos for Mac: Batch Change Title to Capture Date-Description-Padded Sequential Number.
Jul 9, 2015 6:31 AM
Hey Léonie .. I haven't a clue when it comes to Apple Scripts etc, so I'll try not to confuse the heck out of you.. 😉 This script to batch change Descriptions works flawlessly, so thanks! Instead of batch changing the text to something new, however, I want to remove the description text entirely (so set it to blank, if you will). I've played around with the script in Automator to see if I could figure it out on my own, but being a tot 00004000 al noob, I've kept running into errors when I try to run it in the Photos app.
Is it possible? And if so, would you mind helping me out with the script?? The description field is useless to me (and annoying every time it pops up when entering a matching search word), so I just want to remove the info completely. The function was available in iPhoto, but somehow this is applicable to newer photos I'm adding to my library.
Anything you can advise would be much appreciated. Cheers.
Jul 9, 2015 8:50 AM
Just run the same script and enter a single space to replace the current descriptions.
Jul 10, 2015 6:26 AM
There has been a lot of responses to this question.
The real answer is that scripts do work, but have to be of selections from the "All Photos" folder.
Thanks to léonie for pointing it out.
Jul 10, 2015 9:09 AM
have to be of selections from the "All Photos" folder.
That's not exactly true. I'm able to run the scripts (which I've made into apps rather than running as scripts) from albums and smart albums and the Photos window.
Jul 10, 2015 12:08 PM
I appreciate your comment, but should's and would's don't help me.
That's why it took so long for me to get it to work.
I started out using selected photos in the Last Import folder. They never worked there for me.
I did try a "New" photos library, and they did work there, but I don't recall which folder I used.
But with nearly 33000 photos, I didn't want to reload my whole library.
It wasn't until I tried in "All Photos" as suggested by leonie, did I get it to work.
But I just gave it another try. On three different albums, and three additional smart albums, I gave it another go.
All six tries failed. For me, the script only works in the "All Photos" folder....
I have also extended the script, by cloning it twice for Setting/appending text to the description.
They both run fine, as long as I select photos in the "All Photos" folder....
I would have expected more consistent results for a product from Apple. It appears Photos is just too new.
Jul 24, 2015 8:08 PM
This is the script you want to use if you want to
1. Batch change the title of numerous photos at once
AND
2. add a number suffix to each photo in the batch
Worked like a charm for me... but it does take a few seconds to process and rename the pics, so be patient
and re-start of Photo app was needed.
Jul 26, 2016 9:21 PM
Now you can....
Latest Photos, in El Capitan, is allowing the scripts discussed in depth. Also, Multiple images can be assigned same description, by simply selecting them and editing the description in the Information dialog. Titles Too!
Sep 14, 2016 4:38 PM
Actually, I just found out that you can, but it's done differently..... have all the photos which you want to change showing, and select them all .. then do a 'get info', the info box that shows up will apply to all the selected photos. Make the change you want in that info box, and it will apply to all the selected photos. An Apple tech support person just told me about that feature.
Sep 14, 2016 6:35 PM
Right - exactly as posted hundreds of times in this forum including multiple times in this thread - that feature ia nearly a year old and well documented and often discussed here
LN
Originally posted at discussions.apple.com/thread/6989989