Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AssetEntity UpdateTime/ CreationTime does not match Exif Data DateTime [Bug report] #1104

Closed
HenrikH96 opened this issue Mar 19, 2024 · 4 comments

Comments

@HenrikH96
Copy link

Version

3.0.0

Platforms

Android

Device Model

Pixel 7

flutter info

[√] Flutter (Channel stable, 3.16.9, on Microsoft Windows [Version 10.0.22631.3155], locale en-US)
    • Flutter version 3.16.9 on channel stable at C:\Users\Henrik\fvm\versions\stable
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 41456452f2 (8 weeks ago), 2024-01-25 10:06:23 -0800
    • Engine revision f40e976bed
    • Dart version 3.2.6
    • DevTools version 2.28.5

[√] Windows Version (Installed version of Windows is version 10 or higher)

[√] Android toolchain - develop for Android devices (Android SDK version 34.0.0-rc1)
    • Android SDK at C:\Users\Henrik\AppData\Local\Android\sdk
    • Platform android-34, build-tools 34.0.0-rc1
    • Java binary at: C:\Program Files\Android\Android Studio\jbr\bin\java
    • Java version OpenJDK Runtime Environment (build 17.0.6+0-b2043.56-9586694)
    • All Android licenses accepted.

[√] Chrome - develop for the web
    • Chrome at C:\Program Files (x86)\Google\Chrome\Application\chrome.exe

[√] Visual Studio - develop Windows apps (Visual Studio Community 2022 17.2.6)
    • Visual Studio at C:\Program Files\Microsoft Visual Studio\2022\Community
    • Visual Studio Community 2022 version 17.2.32630.192
    • Windows 10 SDK version 10.0.19041.0

[√] Android Studio (version 2022.2)
    • Android Studio at C:\Program Files\Android\Android Studio
    • Flutter plugin can be installed from:
       https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
       https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 17.0.6+0-b2043.56-9586694)

[√] VS Code (version 1.87.2)
    • VS Code at C:\Users\Henrik\AppData\Local\Programs\Microsoft VS Code
    • Flutter extension version 3.84.0

[√] Connected device (4 available)
    • Pixel 7 (mobile)  • 29091FDH200380 • android-arm64  • Android 14 (API 34)
    • Windows (desktop) • windows        • windows-x64    • Microsoft Windows [Version 10.0.22631.3155]
    • Chrome (web)      • chrome         • web-javascript • Google Chrome 122.0.6261.129
    • Edge (web)        • edge           • web-javascript • Microsoft Edge 122.0.2365.80

[√] Network resources
    • All expected network resources are available.

• No issues found!

How to reproduce?

If i pick an Image an extract Exif Data The "Exif DateTimeOriginal" doesn't always match the AssetEntity. createDateTime or the AssetEntity.modifiedDateTime.
I want to sort my Image by DatetimeRange with the "createTimeCond" Filteroption. Sadly the Dates doesn't really match the Gallery Dates.

Logs

No response

Example code (optional)

File? result = await galleryImage.asset.originFile;
      var xdata = await readExifFromFile(result!);```

Contact

henrik.huehn@hotmail.de

@CaiJingLong
Copy link
Member

Unfortunately, these two times are not decided by me, but by the system API. I just pass the values.

@HenrikH96
Copy link
Author

@CaiJingLong
That's disappointing :/ I developed a diary app and it would be great to filter the image gallery by date. However, at least on my Pixel 7, the creation date filter doesn't align with my gallery (and the actual datetimes) at all. Nonetheless, it's still an awesome plugin!

@mgudev7a
Copy link

@HenrikH96 Might be a timezone issue. At least this is the most obvious deviation between the AssetEntity.createDateTime and the assets meta data in e.g. Google Foto. Possibily depending on the timezone in which the asset was created and the timezone of device and or emulator you use.

@AlexV525 AlexV525 closed this as not planned Won't fix, can't repro, duplicate, stale Jun 20, 2024
@HenrikH96
Copy link
Author

@mgudev7a I don't think it's a timezone issue. The discrepancy is in years, not hours. I have two separate issues:

  1. createTimeCond does not work properly on my Android phone (Pixel):

    • I have several images from before 2022, but if I filter from 1900-2022, I don't get any results.
    • I worked around this by using updateTimeCond, but this introduces other issues.
  2. AssetEntity.createDateTime doesn't match the creation date of the file:

    • Neither the EXIF data nor the data shown in my Photos app match the creation date.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants