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

[Bug]: File creation date wrong #469

Closed
3 tasks done
borlottie opened this issue Sep 7, 2024 · 4 comments · Fixed by #472
Closed
3 tasks done

[Bug]: File creation date wrong #469

borlottie opened this issue Sep 7, 2024 · 4 comments · Fixed by #472
Labels
Priority: Medium An issue that shouldn't be be saved for last System: macOS For the macOS operating system Type: Bug Something isn't working as intended
Milestone

Comments

@borlottie
Copy link

Checklist

  • I am using an up-to-date version.
  • I have read the documentation.
  • I have searched existing issues.

TagStudio Version

9.4.0

Operating System & Version

MacOS 14.5

Description

For many of my files, the listed creation and modification dates are seemingly in the wrong order, or further do not match what my file explorer lists for the same files.

TagStudio info panel - creation date (1 Sep 2024) is I think the date I moved the file into the directory? And modification date (11 Aug 2020) is on its own correct, but well before the file's listed creation date.
Screenshot 2024-09-08 at 8 52 42 AM

Finder's info panel - showing creation date should be 31 July 2020
Screenshot 2024-09-08 at 8 51 58 AM

Expected Behavior

A file's listed modification date should be chronologically after its creation date, and both dates should match with the system's native file explorer.

Steps to Reproduce

  1. Move a file into the library folder
  2. Select the file in TagStudio and inspect its listed creation date
  3. Compare with native file explorer's listed creation date

Logs

No response

@borlottie borlottie added the Type: Bug Something isn't working as intended label Sep 7, 2024
@CyanVoxel
Copy link
Member

Is the Finder properties panel a screenshot of the file in the exact same location, or did you move/copy the file from iCloud Drive to your Documents folder for TagStudio?

If it was moved/copied then this could update the file's creation date, even if it's chronologically newer than the modification date. I often have this issue on Windows and a good chunk of my files have creation dates several years newer than their modification dates.

And if you're curious for technical reasons, TagStudio is reading from the files' mtime property for the date modified and its ctime for date created.

@borlottie
Copy link
Author

The properties panel is the file in the exact same location - I accessed the finder file by clicking the filepath in tagstudio to reveal in finder.

@CyanVoxel
Copy link
Member

Upon further research it appears that macOS uses the birthtime stat to store a more accurate creation date rather than Windows which uses the ctime (change time). This person explains it in more detail: https://stackoverflow.com/a/39501288

This should mean that this is fixable though, as we can just pull from the birthtime on macOS and continue to use ctime elsewhere.

@CyanVoxel CyanVoxel added Priority: Medium An issue that shouldn't be be saved for last System: macOS For the macOS operating system labels Sep 7, 2024
@CyanVoxel
Copy link
Member

Fixed in #472, will come in the next patch (v9.4.1)

@CyanVoxel CyanVoxel added this to the Alpha v9.4.1 milestone Sep 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Priority: Medium An issue that shouldn't be be saved for last System: macOS For the macOS operating system Type: Bug Something isn't working as intended
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants