Sorting seems to not be working properly

After much work I cleaned and exported my photo library from Mac Photos and imported into Shotwell. I love Shotwell, mainly just to finally have an alternative to Apple :slight_smile:

But I notice a sorting issue. At the oldest end of my Shotwell library it’s showing pictures which are not that old and not sorted properly. For instance if I click on ‘Photos’ to view all photos, sort by exposure date and go to the ‘old end’, I see loads with exposure dates (viewing date) of 2006, yet there are older ones in there with older exposure dates.

This seems to affect maybe 50-100 photos at the old end of the library, then after that they seem to be sorted properly. More weirdly, if I view events list, go to oldest events, those 50-100 don’t show in any old events.

I don’t suppose there is any kind of ‘clean up’ operation I can run to try and re-index them all?

Thanks

PS I have spent quite a lot of time sitting with two machines, on one is Shotwell, on the other is old imac with Photos app. Both sorted the same. Shotwell seems to have quite a few missing from the date sorted list. I picked a few at random which are missing, found the filename from Photos on mac, searched for that filename in Shotwell and they DO exist in my library, it finds that same photo. BUT, it’s not in the list chronologically where it should be (so I’d have no way to find it by browsing dates which is how I find what I need), and even if I look at Events on left pane, I can’t find it for any events in that date.

Basically there are tons of important photos somewhere inside Shotwell, but I’ll never find them again without knowing their filenames! (In this case A_4a.jpg!)

I need to resolve this or I will have to keep the old imac on desk disconnected from web just as a photo library machine. I intended to do that for a while anyway until I am confident in Shotwell to find what I need quickly. Would much rather dump Photos and Mac completely though

Is there a clean up utility or any other suggestions? for example, maybe I could pay for one of these Mac Photos clean up programs, let it do a clean up/re-index, and then export fresh into Shotwell. Is that likely to improve matters?

thanks for any ideas

Further investigating, not confirmed yet so may be a red herring but a lot of the photos that aren’t showing in Photos sorted list seem to have underscores in filename, and maybe a capital letter. I can’t confirm that applies to every single one yet, but if it inspires any clever ideas I am listening! thanks

EDIT: Scratch that. Most of pics in good sorted order have underscores or capitals, it’s not that.

UPDATE: I noticed something… Let’s say (as is the case) that I have 30 photos from a birthday party in 2008, but 8 are missing from the sorted list in Shotwell (but show in order in Mac Photos). Comparing those that show in Shotwell list vs those that don’t, there’s metadata for those that do show, camera type, focal length etc. For those that don’t show there’s only an exposure date (which is correct in some cases, but in other cases it’s wrong and always same Feb 27 2008?!.

Further update: I found a ‘No Event’ option bottom of left sidebar, not fully checked if ALL are in there, but definitely a LOT of the ones I noticed missing from sorted ‘Photos’ list are in there.

Could this be a metadata corruption of some kind?

Still wondering if one of these overpriced Photos App cleaners may be worth buying, after avoiding them all these years! (and reimport to shotwell)?

ah. That is the issue with not adding things properly into events if there is no exposure time in the meta-data, sorry about that.

Thanks for replying. Sorry but I don’t quite understand, are you saying I have done something wrong causing this? Or are you saying it’s a known issue?
If the latter, could you refer me to anywhere else I can read about it and is there any likelihood of it being cured some day?
thanks again

Is it possible to bulk edit metadata for ALL photos at once, to insert a fake ‘exposure time’ to get around the problem? just thinking out loud!

Yes.

Ctrl+S for a new saved search and set it to “Date is not set” like below

image

Then click on the Seach in the left bar

image

Then Ctrl-A for Select All, then F4 for “Adjust Date and Time” if you just want “some” time on all of the photos, of course you can do all this (selecting, F4, set time) for just a subset if you want to be more precise.

Thanks so much for replying.
This looks promising! So, if I have it right, this will only set a time/date for the photos that don’t already have a date or time in their metadata. is that correct? (i don’t want to overwrite any good date metadata)

Also, is this sorting issue a bug that is likely to be fixed some time?

Thanks again

Did that, the search says 2200 photos (out of 37,000) that have no date set.
However, before I do anything else, when i click on any of them, they do appear to have a date set?! I will put a screenshot below of one example, grateful if you can comment before I proceed, is that not the date you meant? Strange that it found 2200 photos which do appear to have a date set, unless I am missing something (which is likely!)

Thanks

Huh. Interesting. I would need to investigate. Unfortunately there are several dates in use and sometimes it is not very consistent

Yeah, I think I have planned a “sprint” to look into meta-data issues, but I need to finish the GTK4 port fist.

No worries at all.
Would you say I should go ahead and follow the procedure you gave me above to add exposure dates to the 2000 found in the search? Or not point now since they already have dates so it can’t be that causing the sorting issue?

I will wait to hear, may as well not edit the dates if that’s not the issue, as they could be useful in future (if they are accurate, they may be). If needed I am happy to just leave it and live with it until you find time to look into it.
thanks

The properties panel on the right hand side uses the file time (not sure which one) if no time in the metadata is available. there is an old ticket that suggests to do something like that on import already.

The query on the other hand looks only at the meta-data. If the file time looks anywhere correct, it would probably be easier to write a script that transfers that into the file’s meta-data and let shotwell pick it up on the next start. I’m pretty sure such scripts are flying around alreay using either exiftool or exiv2

Getting a bit over my head here but I think you’re saying those exposure times may not be actual metadata? If so, I guess I could confirm by finding out how to look the metadata on the files in my file manager?

I have found Phil Harvey’s ExifTool (CLI and GUI).
Looks like there are commands to bulk write new metadata to files in a folder, so in theory (bit over my pay grade this but positive thinking and all that :slight_smile: ) I could move the saved search results/files into a single folder, apply the ‘write to all files in folder’ command found here ExifTool Command-Line Examples, and add some metadata to help Shotwell sort them, if you think that may help?

Sorry I have just noticed I have two user accounts on here. No idea why, I don’t get this ‘Discourse’ thing, not even sure what it is but I assume I must have created a second user account for another board somewhere and then it tied back to ‘central’. Far too complicated for my old brain! Just give me phpBB back with a user account for any forum I want to join!!

PS I just had a thought, originally you said " no exposure time in the meta-data"
I assumed that meant TIME THE PICTURE WAS TAKEN!!!
Did you actually mean the exposure time as in 1/100? It’s onoly just occurred to me after looking at images. Or did you mean the date/time taken as I first thought?
thanks!

No “exposure time” in Shotwell means the time when the exposure happened, i.e. one of

  • “Exif.Photo.DateTimeOriginal”,
  • “Xmp.exif.DateTimeOriginal”,
  • “Xmp.xmp.CreateDate”,
  • “Exif.Photo.DateTimeDigitized”,
  • “Xmp.exif.DateTimeDigitized”,
  • “Exif.Image.DateTime”

The Exposure time as in “time slot that the exposure was done for” is the “exposure time property on the photo’s meta-data” and yes, that is very confusing naming, sorry.

This topic was automatically closed 45 days after the last reply. New replies are no longer allowed.