Error in writing XMP Metadata for Comments

*** Please report new bugs here! ***

Moderators: helmut, XnTriq, xnview, Dreamer

Post Reply
lewisn
Posts: 4
Joined: Fri Apr 08, 2016 7:32 pm

Error in writing XMP Metadata for Comments

Post by lewisn »

I'm running XnViewMP Version 0.79 x64. There is an issue writing XMP Metadata. I have the option selected to "Write comment in XMP (dc:description and exif:UserComment)". One symptom of this is that the Comment will not show up in Windows 10 when I look in the file's Properties/Details or when I add columns for Comments in the Windows File Explorer file display listing. There seems to be an error in how XnViewMP creates the metadata in the file. If I write a comment with XnViewMP and then use ExifTool to update those two fields with other data I get the following warnings:

Warning: [minor] Fixed incorrect list type for XMP-exif:UserComment
Warning: [minor] Fixed incorrect list type for XMP-dc:Description

In doing this, as soon as I write the new data to the XMP-exif:UserComment field using ExifTool then the new Comment shows up in Windows File Explorer. There is something about how the Comment is written by XnViewMP that is preventing Windows from picking up the comment. Rewriting the field using ExifTool fixes the issue, as noted by it's warning above as it fixes the error.

It is interesting to note that if I write a caption using XnViewMP [and I have the Edit IPTC-IIM/XMP option set to "IPTC-IIM, update ore create XMP"] then when the caption metadata is written by XnViewMP then the previously entered XnViewMP Comment will suddenly show up in Windows as well. Whatever was bad about the comment field seems to get corrected by XnViewMP as the caption info is written. However, if I then write a new comment, the comment written will disappear in Windows again. After that the rewritten comment exhibits the bad problem again, and if I update the field (as above) using ExifTool I again get the warning listed above that there was an incorrect list type for the field.
User avatar
xnview
Author of XnView
Posts: 46257
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: Error in writing XMP Metadata for Comments

Post by xnview »

could you send me an image with incorrect comment and the fixed one?
Pierre.
lewisn
Posts: 4
Joined: Fri Apr 08, 2016 7:32 pm

Re: Error in writing XMP Metadata for Comments

Post by lewisn »

Here is information about two test files I used yesterday. I used XnViewMP to write a Comment. I then wrote a Caption using XnViewMP. I then wrote a new Comment using XnviewMP. That file is "CommentWritten2nd.jpg". You can see the contents of the metadata fields for that iteration in my exiftool lisings. Note that in the Windows screenshot that the Comment in the the XMP:UserComment field isn't being listed by Windows.

Then I used XnViewMP to write an edited new Caption. The file "CaptionWritten2nd.jpg" is that file. Note that now Comment in the XMP:UserComment is now being listed by Windows.

I'll try to send you the actual .jpg files in a private message.

Here are metadata tags listed by an exiftool script I use to list tags:

Code: Select all

=====File: CommentWritten2nd.jpg
   Caption-Abstract: added caption3
   Comment (FILE:Comment)   : added comment4
   Comment (XMP:UserComment): added comment4
   XMP:Description: added comment4
=====File: CaptionWritten2nd.jpg
   Caption-abstract: added caption4
   Comment (FILE:Comment)   : added comment3
   Comment (XMP:UserComment): added comment3
   XMP:Description: added caption4
=== End of List ===
Here is the listing for the two files in Windows 10 File Explorer:
screenshot
screenshot
screenshot.jpg (30.76 KiB) Viewed 533 times
Lewis N
Post Reply