strange shift day bug

Started by minipai, March 07, 2021, 04:37:05 PM

Previous topic - Next topic

minipai

There is a strange bug when I try to shift datetime. The command I ran is

exiftool "-AllDates+=2:11:27 16:10:00" "-FileModifyDate+=2:11:27 16:10:00" .

the result will be different when there is a different file combination in the folder
please see screenshot

this is the expected result


the result is wrong when added another file to batch



however, I workarounded with

exiftool "-AllDates+=1095 16:10:00" "-FileModifyDate+=1095 16:10:00" .

the files that cause the problem can be download from https://www.dropbox.com/s/fn04y3kjzkr36o2/Archive.zip?dl=0

version: MacOS Package: ExifTool-12.21.dmg (3.0 MB)

Phil Harvey

This is intentional.  Read here.

I'm guessing that your test case is purely hypothetical, because it isn't likely that anyone would really want to shift date/times like this.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

minipai

Thanks for your reply
After reading the "TRICKY" section I understand now.

The test case is real but simplified.

There were around 400 pics in my sd card's folder which time span for months.
I took a new photo (which will be the last photo in the folder) to find out how much I need to shift the whole folder, which the tool gave me the format starting with years.
Then found out if I apply to the whole folder the result would be different.

Phil Harvey

It would work if you shifted the test photo first. ie)

exiftool .... test_photo.jpg DIR

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).