darktable icon indicating copy to clipboard operation
darktable copied to clipboard

Color label not written to sidecars

Open rekcodocker opened this issue 1 month ago • 7 comments

Is there an existing issue for this?

  • [x] I checked and did not find my issue in the already reported ones

Describe the bug

I just labeled 700+ files with star ratings and color labels. Now I find DT did not write the color label to a single file. I don't know how to reproduce

Steps to reproduce

Go to light table Color label an image

XMP file has a line "xmp:Label="NoColor" " Which is incorrect because it does have a color.

Close and re-open DT.
The image has the correct color label but it's not in the sidecar file. The rating is in the sidecar.

Expected behavior

Write the correct color label to the sidecar

Logfile | Screenshot | Screencast

No response

Commit

No response

Where did you obtain darktable from?

darktable.org / GitHub release

darktable version

5.2.0

What OS are you using?

Linux

What is the version of your OS?

Mint

Describe your system

No response

Are you using OpenCL GPU in darktable?

Yes

If yes, what is the GPU card and driver?

not relevant but it's the intel CPU

Please provide additional context if applicable. You can attach files too, but might need to rename to .txt or .zip

No response

rekcodocker avatar Nov 17 '25 12:11 rekcodocker

Is you sidecar writing set to after edit?

wpferguson avatar Nov 17 '25 16:11 wpferguson

Is you sidecar writing set to after edit?

Yes it is set to 'after edit' It stores the star-rating in the xmp file, as well as the edit. But it does not write the color label.

I ran into the problem when I re-imported files which were edited before but are not in my database. This information is lost while other info (the edit, star rating) is maintained.

rekcodocker avatar Nov 17 '25 19:11 rekcodocker

Cannot reproduce:

   <darktable:colorlabels>
    <rdf:Seq>
     <rdf:li>1</rdf:li>
     <rdf:li>3</rdf:li>
    </rdf:Seq>
   </darktable:colorlabels>

Note that the color labels are not written in xmp:Label but in darktable:colorlabels as we need a list for supporting multiple labels on the same image.

TurboGit avatar Nov 18 '25 10:11 TurboGit

Ah so they're in a different spot in the XMP? This is what happened:

I had a typo in a directory name. I deleted the files from DT knowing the edits would be preserved in the XMP. I then renamed the directory outside of DT Then I reimported the lot.

That is when the color label was lost.

rekcodocker avatar Nov 18 '25 21:11 rekcodocker

I can reproduce it now. I see it's lost on importing xmp files.

  1. I assign a color label to an image.
  2. I remove it from DT (not from disk)
  3. I re-import it again.
    The color label is lost on imoprt.

I have attached detailed XMP files so you can see it getting lost from file 6 to 7. The color label starts at line 99.

P5461051.ORF.xmp.1afterInitialImport.txt P5461051.ORF.xmp.2-afterAssigningThreeColorLabels.txt P5461051.ORF.xmp.4-afterExitingDTtoForceWritingXMPfile.txt P5461051.ORF.xmp.5-ReOpenDT.txt P5461051.ORF.xmp.6-RemoveFromDTNotFromDisk.txt P5461051.ORF.xmp.7-ImportAgain.txt

rekcodocker avatar Nov 23 '25 09:11 rekcodocker

@rekcodocker : Still cannot reproduce with the scenario above. Question, do you have a Lr sidecar file next to the image?

TurboGit avatar Nov 23 '25 10:11 TurboGit

No, I use digikam and Darktable. I don't use Lightroom or other programs. Thanks for trying. Perhaps it's my database or something has gone corrupt in the settings.

rekcodocker avatar Nov 30 '25 12:11 rekcodocker