[BUG] Time buckets should use exif date/time if available #1349

Closed
opened 2026-02-05 01:22:42 +03:00 by OVERLORD · 2 comments
Owner

Originally created by @daniele-athome on GitHub (Sep 21, 2023).

The bug

The time buckets feature currently uses assets.fileCreatedAt which is the file creation date. If EXIF date/time information is available for an asset, taht should be used instead.

The OS that Immich Server is running on

Debian

Version of Immich Server

v1.79.0

Version of Immich Mobile App

(not applicable)

Platform with the issue

  • Server
  • Web
  • Mobile

Your docker-compose.yml content

(not applicable)

Your .env content

(not applicable)

Reproduction steps

1. Import some pictures with file timestamp different from exif timestamp using an external library
2. Wait for the jobs to finish and open the timeline

Additional information

No response

Originally created by @daniele-athome on GitHub (Sep 21, 2023). ### The bug The time buckets feature currently uses `assets.fileCreatedAt` which is the file creation date. If EXIF date/time information is available for an asset, taht should be used instead. ### The OS that Immich Server is running on Debian ### Version of Immich Server v1.79.0 ### Version of Immich Mobile App (not applicable) ### Platform with the issue - [X] Server - [ ] Web - [ ] Mobile ### Your docker-compose.yml content ```YAML (not applicable) ``` ### Your .env content ```Shell (not applicable) ``` ### Reproduction steps ```bash 1. Import some pictures with file timestamp different from exif timestamp using an external library 2. Wait for the jobs to finish and open the timeline ``` ### Additional information _No response_
Author
Owner

@daniele-athome commented on GitHub (Sep 21, 2023):

Sorry I was too rush. I saw that the metadata extraction job updates fileCreatedAt after extracting the tags:

    await this.assetRepository.save({
      id: asset.id,
      duration: tags.Duration ? Duration.fromObject({ seconds: tags.Duration }).toFormat('hh:mm:ss.SSS') : null,
      fileCreatedAt: exifData.dateTimeOriginal ?? undefined,
    });

It seems like a hack though, especially with new libraries feature which can now handle file system assets. Or maybe I'm overthinking it :-)

@daniele-athome commented on GitHub (Sep 21, 2023): Sorry I was too rush. I saw that the metadata extraction job updates fileCreatedAt after extracting the tags: ``` await this.assetRepository.save({ id: asset.id, duration: tags.Duration ? Duration.fromObject({ seconds: tags.Duration }).toFormat('hh:mm:ss.SSS') : null, fileCreatedAt: exifData.dateTimeOriginal ?? undefined, }); ``` It seems like a hack though, especially with new libraries feature which can now handle file system assets. Or maybe I'm overthinking it :-)
Author
Owner

@jrasm91 commented on GitHub (Sep 21, 2023):

That column has always represented when a photo was taken. Working as intended.

@jrasm91 commented on GitHub (Sep 21, 2023): That column has always represented when a photo was taken. Working as intended.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: immich-app/immich#1349