Duplicates not listed in JSON output's duplicate entry when uploading via CLI #7496

Open
opened 2026-02-20 05:03:56 -05:00 by deekerman · 0 comments
Owner

Originally created by @mattbaker-digital on GitHub (Nov 30, 2025).

I have searched the existing issues, both open and closed, to make sure this is not a duplicate report.

  • Yes

The bug

When uploading photos using the CLI and enabling JSON output, the duplicates are not listed in the duplicates JSON array even though the output shows that duplicates were found and skipped.

The OS that Immich Server is running on

TrueNAS Community 25.10.0.1 - Goldeye

Version of Immich Server

v2.3.1 build 19524231183

Version of Immich Mobile App

N/A

Platform with the issue

  • Server
  • Web
  • Mobile

Device make and model

No response

Your docker-compose.yml content

N/A

Your .env content

N/A

Reproduction steps

  1. Add API key and instance URL to environment variable.
  2. Run immich upload <path to photos> -r --json-output.
  3. Verify duplicates found: Skipped <n> duplicate assets (<size>).
  4. Check JSON output duplicates entry.
  5. Notice it is empty.

Relevant log output

Crawling for assets...
Found 8871 new files and 0 duplicates
Successfully uploaded 8075 new assets (37.5 GB)
Skipped 796 duplicate assets (252.6 MB)
{
    "newFiles": [
        "/mnt/temp/2016-05/100APPLE/IMG_0020.JPG",
        "/mnt/temp/2016-05/100APPLE/IMG_0002.JPG",
        "/mnt/temp/2016-05/100APPLE/IMG_0019.JPG",
        "/mnt/temp/2016-05/100APPLE/IMG_0001.JPG",
        "/mnt/temp/2016-05/100APPLE/IMG_0024.JPG",
        "/mnt/temp/2016-05/100APPLE/IMG_0035.JPG",
        "/mnt/temp/2016-05/100APPLE/IMG_0025.JPG",
        "/mnt/temp/2016-05/100APPLE/IMG_0022.JPG",
        "/mnt/temp/2016-05/100APPLE/IMG_0023.JPG",
        "/mnt/temp/2016-05/100APPLE/IMG_0032.JPG",
        "/mnt/temp/2016-05/100APPLE/IMG_0054.JPG",
        "/mnt/temp/2016-05/100APPLE/IMG_0030.JPG",
        "/mnt/temp/2016-05/100APPLE/IMG_0033.JPG",
        "/mnt/temp/2016-05/100APPLE/IMG_0043.PNG",
        "/mnt/temp/2016-05/100APPLE/IMG_0062.JPG",
        "/mnt/temp/2016-05/100APPLE/IMG_0058.JPG",
        "/mnt/temp/2016-05/100APPLE/IMG_0059.JPG",
        "/mnt/temp/2016-05/100APPLE/IMG_0060.JPG",
        "/mnt/temp/2016-05/100APPLE/IMG_0063.JPG",
        "/mnt/temp/2016-05/100APPLE/IMG_0061.JPG",
        "/mnt/temp/2016-05/100APPLE/IMG_0067.JPG",
        "/mnt/temp/2016-05/100APPLE/IMG_0064.JPG",
        ...
        "/mnt/temp/received_407369622784956.jpg",
        "/mnt/temp/received_407369632784955.jpeg",
        "/mnt/temp/received_407369629451622.jpg",
        "/mnt/temp/received_407369632784955.jpg"
    ],
    "duplicates": [],
    "newAssets": [
        {
            "id": "cf84df6a-27af-4015-86f4-7a7f4ee17d48",
            "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0035.JPG"
        },
        {
            "id": "6cd25771-0b78-4b7d-aa77-898ba0ee92a6",
            "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0020.JPG"
        },
        {
            "id": "462f7242-78db-4bb6-b6e0-691e54adebce",
            "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0001.JPG"
        },
        {
            "id": "81b60239-996f-4b6c-94de-e02be4938a1d",
            "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0019.JPG"
        },
        {
            "id": "16f74e1d-a1f1-4018-a876-e12b8f270dc7",
            "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0002.JPG"
        },
        {
            "id": "4c2fd2ca-9547-437a-ac63-253d6939f47a",
            "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0024.JPG"
        },
        {
            "id": "176d2edc-5ca1-49fd-8858-31430a3345c2",
            "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0025.JPG"
        },
        {
            "id": "7535cb84-d9fb-44bd-801d-007db4eea5ce",
            "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0054.JPG"
        },
        {
            "id": "c30e0384-2f4d-48bc-9282-01a06aad4723",
            "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0032.JPG"
        },
        {
            "id": "06a80f82-fa1b-4e09-a4f3-23e646421fed",
            "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0022.JPG"
        },
        {
            "id": "d7b077d7-27ff-4c36-b15b-694fc3be4e04",
            "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0023.JPG"
        },
        {
            "id": "a8eae2ad-e01e-4ef0-abf2-efa4240fdb03",
            "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0030.JPG"
        },
        {
            "id": "81d955f1-a392-4417-be17-bc8143cf7ae5",
            "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0043.PNG"
        },
        {
            "id": "8c899191-f8a9-4d17-87ef-dea78d8ce077",
            "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0062.JPG"
        },
        {
            "id": "67cd445b-5f27-4803-80e2-2208d194484b",
            "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0033.JPG"
        },
        {
            "id": "486f6e29-01f9-457a-8065-40c78f5d4db5",
            "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0064.JPG"
        },
        ...
         {
            "id": "76a7a288-e39d-49dc-9afe-6a984b2c1a86",
            "filepath": "/mnt/temp/2017-06-10/105CLOUD/IMG_4090.JPG"
        },
        {
            "id": "ffbc681e-c6d9-4d8e-8763-5bfd709c8405",
            "filepath": "/mnt/temp/received_407369622784956.jpg"
        },
        {
            "id": "7301bc5f-911a-4008-b64c-50d55afec3e5",
            "filepath": "/mnt/temp/received_407369612784957.jpg"
        },
        {
            "id": "5916a55e-7cb4-46be-9555-a2fa93f6759f",
            "filepath": "/mnt/temp/received_407369629451622.jpg"
        },
        {
            "id": "806ac9b1-470e-4b65-a9f6-8fd11f49871b",
            "filepath": "/mnt/temp/received_407369632784955.jpeg"
        },
        {
            "id": "52ea6aed-6bfd-4c7a-9651-af07c60e5832",
            "filepath": "/mnt/temp/received_407369632784955.jpg"
        }
    ]
}

Additional information

I have also verified the same behaviour on a fresh instance without any media yet uploaded.

Originally created by @mattbaker-digital on GitHub (Nov 30, 2025). ### I have searched the existing issues, both open and closed, to make sure this is not a duplicate report. - [x] Yes ### The bug When uploading photos using the CLI and enabling JSON output, the duplicates are not listed in the `duplicates` JSON array even though the output shows that duplicates were found and skipped. ### The OS that Immich Server is running on TrueNAS Community 25.10.0.1 - Goldeye ### Version of Immich Server v2.3.1 build 19524231183 ### Version of Immich Mobile App N/A ### Platform with the issue - [x] Server - [ ] Web - [ ] Mobile ### Device make and model _No response_ ### Your docker-compose.yml content ```YAML N/A ``` ### Your .env content ```Shell N/A ``` ### Reproduction steps 1. Add API key and instance URL to environment variable. 2. Run `immich upload <path to photos> -r --json-output`. 3. Verify duplicates found: `Skipped <n> duplicate assets (<size>)`. 4. Check JSON output `duplicates` entry. 5. Notice it is empty. ### Relevant log output ```shell Crawling for assets... Found 8871 new files and 0 duplicates Successfully uploaded 8075 new assets (37.5 GB) Skipped 796 duplicate assets (252.6 MB) { "newFiles": [ "/mnt/temp/2016-05/100APPLE/IMG_0020.JPG", "/mnt/temp/2016-05/100APPLE/IMG_0002.JPG", "/mnt/temp/2016-05/100APPLE/IMG_0019.JPG", "/mnt/temp/2016-05/100APPLE/IMG_0001.JPG", "/mnt/temp/2016-05/100APPLE/IMG_0024.JPG", "/mnt/temp/2016-05/100APPLE/IMG_0035.JPG", "/mnt/temp/2016-05/100APPLE/IMG_0025.JPG", "/mnt/temp/2016-05/100APPLE/IMG_0022.JPG", "/mnt/temp/2016-05/100APPLE/IMG_0023.JPG", "/mnt/temp/2016-05/100APPLE/IMG_0032.JPG", "/mnt/temp/2016-05/100APPLE/IMG_0054.JPG", "/mnt/temp/2016-05/100APPLE/IMG_0030.JPG", "/mnt/temp/2016-05/100APPLE/IMG_0033.JPG", "/mnt/temp/2016-05/100APPLE/IMG_0043.PNG", "/mnt/temp/2016-05/100APPLE/IMG_0062.JPG", "/mnt/temp/2016-05/100APPLE/IMG_0058.JPG", "/mnt/temp/2016-05/100APPLE/IMG_0059.JPG", "/mnt/temp/2016-05/100APPLE/IMG_0060.JPG", "/mnt/temp/2016-05/100APPLE/IMG_0063.JPG", "/mnt/temp/2016-05/100APPLE/IMG_0061.JPG", "/mnt/temp/2016-05/100APPLE/IMG_0067.JPG", "/mnt/temp/2016-05/100APPLE/IMG_0064.JPG", ... "/mnt/temp/received_407369622784956.jpg", "/mnt/temp/received_407369632784955.jpeg", "/mnt/temp/received_407369629451622.jpg", "/mnt/temp/received_407369632784955.jpg" ], "duplicates": [], "newAssets": [ { "id": "cf84df6a-27af-4015-86f4-7a7f4ee17d48", "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0035.JPG" }, { "id": "6cd25771-0b78-4b7d-aa77-898ba0ee92a6", "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0020.JPG" }, { "id": "462f7242-78db-4bb6-b6e0-691e54adebce", "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0001.JPG" }, { "id": "81b60239-996f-4b6c-94de-e02be4938a1d", "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0019.JPG" }, { "id": "16f74e1d-a1f1-4018-a876-e12b8f270dc7", "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0002.JPG" }, { "id": "4c2fd2ca-9547-437a-ac63-253d6939f47a", "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0024.JPG" }, { "id": "176d2edc-5ca1-49fd-8858-31430a3345c2", "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0025.JPG" }, { "id": "7535cb84-d9fb-44bd-801d-007db4eea5ce", "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0054.JPG" }, { "id": "c30e0384-2f4d-48bc-9282-01a06aad4723", "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0032.JPG" }, { "id": "06a80f82-fa1b-4e09-a4f3-23e646421fed", "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0022.JPG" }, { "id": "d7b077d7-27ff-4c36-b15b-694fc3be4e04", "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0023.JPG" }, { "id": "a8eae2ad-e01e-4ef0-abf2-efa4240fdb03", "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0030.JPG" }, { "id": "81d955f1-a392-4417-be17-bc8143cf7ae5", "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0043.PNG" }, { "id": "8c899191-f8a9-4d17-87ef-dea78d8ce077", "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0062.JPG" }, { "id": "67cd445b-5f27-4803-80e2-2208d194484b", "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0033.JPG" }, { "id": "486f6e29-01f9-457a-8065-40c78f5d4db5", "filepath": "/mnt/temp/2016-05/100APPLE/IMG_0064.JPG" }, ... { "id": "76a7a288-e39d-49dc-9afe-6a984b2c1a86", "filepath": "/mnt/temp/2017-06-10/105CLOUD/IMG_4090.JPG" }, { "id": "ffbc681e-c6d9-4d8e-8763-5bfd709c8405", "filepath": "/mnt/temp/received_407369622784956.jpg" }, { "id": "7301bc5f-911a-4008-b64c-50d55afec3e5", "filepath": "/mnt/temp/received_407369612784957.jpg" }, { "id": "5916a55e-7cb4-46be-9555-a2fa93f6759f", "filepath": "/mnt/temp/received_407369629451622.jpg" }, { "id": "806ac9b1-470e-4b65-a9f6-8fd11f49871b", "filepath": "/mnt/temp/received_407369632784955.jpeg" }, { "id": "52ea6aed-6bfd-4c7a-9651-af07c60e5832", "filepath": "/mnt/temp/received_407369632784955.jpg" } ] } ``` ### Additional information I have also verified the same behaviour on a fresh instance without any media yet uploaded.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/immich#7496
No description provided.