Claude generated text for the issue, but I did repro it myself:
During bulk uploads, setImmichAssetId in MetadataTask.lua intermittently fails with:
LrCatalog:withPrivateWriteAccessDo: could not execute action '(unknown)'.
It was blocked by another write access call, and no timeout parameters were provided.
This happens when another plugin also writes to the catalog during the export loop (e.g., a plugin that sets the image color label on export). Both plugins call withPrivateWriteAccessDo without a timeout, so they fail immediately instead of waiting for each other to release the lock.
It can also be triggered by Lightroom's own background operations (preview generation, sync, auto-save).
Suggested fix:
Add a timeout parameter to the withPrivateWriteAccessDo call:
catalog:withPrivateWriteAccessDo("setImmichAssetId", function()
photo:setPropertyForPlugin(_PLUGIN, 'immichAssetId', assetId)
end, { timeout = 5 })
This gives Lightroom up to 5 seconds to acquire the write lock before failing. The first argument string also helps identify the action in error messages instead of showing (unknown).
Claude generated text for the issue, but I did repro it myself:
During bulk uploads, setImmichAssetId in MetadataTask.lua intermittently fails with:
LrCatalog:withPrivateWriteAccessDo: could not execute action '(unknown)'.It was blocked by another write access call, and no timeout parameters were provided.
This happens when another plugin also writes to the catalog during the export loop (e.g., a plugin that sets the image color label on export). Both plugins call withPrivateWriteAccessDo without a timeout, so they fail immediately instead of waiting for each other to release the lock.
It can also be triggered by Lightroom's own background operations (preview generation, sync, auto-save).
Suggested fix:
Add a timeout parameter to the withPrivateWriteAccessDo call:
This gives Lightroom up to 5 seconds to acquire the write lock before failing. The first argument string also helps identify the action in error messages instead of showing (unknown).