ERROR Sample metadata not extracted from photo although it should have been used to determine the device timezone?

First off, I hope the dev’s hand is ok, get well soon!
Second, I was trying to move (copy i guess) files into a date/dir structure and Rapid Download seemed to be the best way to do it? I managed to move quite a few files but then I tried another directory and it moved only 20% of the files (combination of photos and videos). Its not clear to me what exactly the problem is, I tried to start it from the term and re-copy the files and it wouldnt but in the term i got an error like:

ERROR    Sample metadata not extracted from photo IMG_0047.JPG although it should have been used to determine the device timezone 
ERROR    Sample metadata not extracted from photo IMG_0046.HEIC although it should have been used to determine the device timezone

Has anyone else had this issue? Any idea how to resolve it?

The problem probably cannot be resolved. Apparently the exif metadata in at least some of your photos and/or videos cannot be read anymore. That indicates it has been corrupted at some point.

You can confirm this by using exiv2 or ExifTool from the command line to try to extract the metadata. Probably you will find exiv2 cannot read it. If ExifTool can in fact extract the metadata, however, then switch the Rapid Photo Downloader preferences to use ExifTool to extract meta data, and continue.

Thanks for your kind words about my hands. I am dictating this using Dragon NaturallySpeaking under Windows.

Wow, wasnt expecting you to be bothering with RPD at the moment (considering your hand) so thanks!
I haven’t tried ExifTool yet but I did try XnView (forgive me for not using FOSS :slight_smile: ) and it seemed to be able to read the files fine, or at least the sample of 5 photos i looked at I could see the dates and they looked normal.
Will tinker with exiftool.
Much appreciated!

EDIT. It just occurred to me that this might have to do with foreign characters? I say that because my partners first language isnt English and they often use their native alphabet, I use only English and transferred 2x the number of photos that were on the same drive with literally no errors. Kinda thinking out loud, probably something I should post to the exiftool forum.

Hi. I have a very similar problem.

I installed version 0.9.34 today on ubuntu 22.10
I Imported 36GB of Images and Videos and about 200 images were not imported due to missing meta-data.
I tried some of the images on the commandline. While exiv2 failed, exiftool could properly read all metadata.
I checked the setting to only use exiftool but unfortunately the files still failed to import.

Do you have any idea why this happens? Looks like RPD does not use exiftool despite the activated setting.

I have some development experience and are willing to help debugging this.

As it says on the Rapid Photo Downloader website, “Rapid Photo Downloader is a tool to get data off the camera / memory card / smart phone / external drive and onto the computer, with on-the-fly back ups and file renaming being optional. It’s not a general purpose renaming tool for files you have already worked on using a photo editing program”.

If you want to try to use Rapid Photo Downloader to copy files that have already being edited, that’s up to you, but it’s on you to fix problems with files whose metadata cannot be read.

The program generates log files to aid in problem diagnosis. You can consult them to determine precisely the files from which the metadata is not being read, and at what point. You can try to open them using ExifTool from the command line to compare what Rapid Photo Downloader is reporting, and what you are finding from the command line.

Hi Damon.

Indeed I try to Import files directly from my SDcard taken out of my DSLR. Why do you think I try to move files around that I previously edited?

ok. Found it.

2023-03-16 23:59:00 ERROR scan.py 974: Sample metadata not extracted from photo DSC02926.JPG although it should have been used to determine the device timezone

Because in all previous cases (there have been many!), that’s why this problem has come up.

If you have files straight out of the camera that cannot be read, that indicates a problem with (1) either the files themselves (problematic memory card?), or (2) ExifTool or exiv2, or (3) in the communication of data between ExifTool/exiv2 and Rapid Photo Downloader.

I Also have this log line for every failed image:

2023-03-17 01:40:32 WARNING rpdfile.py 900: Could not read metadata from /media/juergen/disk/DCIM/101MSDCF/DSC01688.JPG. GExiv2: corrupted image metadata (59)

If I look at the code of that file,

        if force_exiftool or fileformats.use_exiftool_on_photo(
            self.extension, preview_extraction_irrelevant=True
        ):

            self.metadata = metadataexiftool.MetadataExiftool(
                full_file_name=full_file_name,
                et_process=et_process,
                file_type=self.file_type,
            )
            return True
        else:
            try:
                self.metadata = metadataphoto.MetaData(
                    full_file_name=full_file_name,
                    raw_bytes=raw_bytes,
                    app1_segment=app1_segment,
                    et_process=et_process,
                )
            except GLib.GError as e:
                logging.warning(
                    "Could not read metadata from %s. %s", self.full_file_name, e
                )
                self.metadata_failure = True
                return False
            except:
                logging.warning("Could not read metadata from %s", self.full_file_name)
                self.metadata_failure = True
                return False
            else:
                return True

Why do I get the message about GExiv2, when the check for force_exiftool should be true as I have set the applicaton setting to only use exiftool?

If I read through the code and look at load_metadata calls, like in renameandmove.py line 203, I rarely see the force_exiftool parameter set for the function call. If the parameter is not set load_metadata will always use exiv2 for images.

Please understand that I have never worked with Python so chances are I do not understand the code properly.