bundletool icon indicating copy to clipboard operation
bundletool copied to clipboard

Incorrect timestamp when unzipping universal apk

Open MartinGonzalez opened this issue 2 years ago • 4 comments

Describe the bug When using command bundletool.jar build-apks the output zip, containing the apk, will provide an apk with the timestamp set in 1981.

Bundletool version(s) affected Version: All

Stacktrace Copy all of the output of the command, including the stacktrace if visible.

To Reproduce

  • Run
java -jar ./bundletool.jar build-apks --bundle="./resources/example.aab" --output="./bundletool_temp/output.apks" --mode=universal 
  • Extrack the universal apk
  • Check timestamp

Expected behavior Expected to have at current date or at least the date the aab was created.

Known workaround You can use touch command to update the Modified date.

image

MartinGonzalez avatar Feb 16 '23 16:02 MartinGonzalez

I am experiencing the same issue. Touch command updates "modified" date, but "created" date remains in 1981

slavdok avatar Feb 16 '23 18:02 slavdok

bundletool does this intentionally to have deterministic output which allows to compare hashes of generated .apks file and ensure that output is the same.

Does it cause any problems for you?

ymakhno avatar Aug 09 '23 23:08 ymakhno

bundletool does this intentionally to have deterministic output which allows to compare hashes of generated .apks file and ensure that output is the same.

Does it cause any problems for you?

No, I'm not having problems with it, but just wanted to know if this was intentional or not because looked odd. Thanks!

Martin-Gonzalez90 avatar Aug 10 '23 06:08 Martin-Gonzalez90

I had a small issue where my company's storage automatically deleted old files, but I fixed it by changing timestamp

Artman12 avatar Apr 26 '24 06:04 Artman12