Medvedev91 / timeto.me

App with pomodoro, checklists, goals, tasks, repetitive, calendar and time tracking.
https://timeto.me
GNU General Public License v3.0
218 stars 13 forks source link

F-Droid can't build #3

Closed licaon-kter closed 7 months ago

licaon-kter commented 7 months ago

ref: https://gitlab.com/fdroid/fdroiddata/-/jobs/5948810622#L5805

licaon-kter commented 7 months ago

Sounds like https://gitlab.com/fdroid/fdroiddata/-/issues/3138

Diff log: time461.log

@appstome how do you build exactly?

Medvedev91 commented 7 months ago

It shouldn't be 3138, it's already fixed.

According to pipeline:

ERROR: APK Signature Scheme v2 signer #1: APK integrity check failed. CHUNKED_SHA256 digest mismatch. Expected: <4e9762ef04667db0a19b7119af9d5901ff7a667ea31f570d595c4e9ed336bd8f>, actual: <f2c86e6c8e5977776d6be31ef6f6530ccec35f3fdf703e0c375fa39f32b5015f>


I was surprised that f-droid automatically build releases from GitHub. For f-droid I make special releases. How to release to f-droid only in manual mode?

Medvedev91 commented 7 months ago

On the other hand I can create a special buildType and apk for f-droid. I'll try to do that soon.

licaon-kter commented 7 months ago

I was surprised that f-droid automatically build releases from GitHub.

You want only some tags? We can make it skip some, eg. pick up only those that end up in -fdroid

Pipeline says: .dex is different, focus on that and on the diff log :)

Medvedev91 commented 7 months ago

I have no idea what the problem is. 3138 was the problem, but I fixed it. There is nothing special in the build process.

Anyway, is it possible for fdroid to use a special flavor "fdroid"? I've already setup this. The apk file will be called "fdroid-release.apk".

licaon-kter commented 7 months ago

3138 was the problem, but I fixed it.

Right, so we thought

I have no idea what the problem is

Same here

Anyway, is it possible for fdroid to use a special flavor "fdroid"?

Yes, ping us when you release such a version. What will be different?

licaon-kter commented 7 months ago

@appstome how do you build exactly?

OS? IDE? command line? CI?

Medvedev91 commented 7 months ago

https://github.com/appstome/timetome-app/releases/tag/v2024.01.19.462

What will be different?

New apk name is "fdroid-release.apk" instead of "android_app-release.apk";

New tags with leading "v" like "v2024.01.19.462" instead of "2024.01.19.462";

Build variant (flavor) "fdroidRelease".

OS? IDE? command line? CI?

IntelliJ IDEA 2023.2.5 (Ultimate Edition) Build #IU-232.10227.8, built on November 9, 2023 Runtime version: 17.0.9+7-b1000.46 aarch64 VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o. macOS 13.5.2 GC: G1 Young Generation, G1 Old Generation Memory: 4096M Cores: 10 Metal Rendering is ON Registry: debugger.new.tool.window.layout=true ide.experimental.ui=true

Non-Bundled Plugins: dev.j-a.swift (0.19.0.167-232) AceJump (3.8.17) IdeaVIM (2.7.5) org.jetbrains.IdeaVim-EasyMotion (1.10) com.intellij.nativeDebug (232.10203.2) com.jetbrains.packagesearch.intellij-plugin (232.9921.28) org.jetbrains.kotlin (232-1.9.21-release-633-IJ10072.27) org.jetbrains.compose.desktop.ide (1.5.11) com.squareup.sqldelight (2.0.1)

Kotlin: 232-1.9.21-release-633-IJ10072.27

licaon-kter commented 7 months ago

Metal Rendering is ON Runtime version: 17.0.9+7-b1000.46 aarch64

So macOS on Arm?

Medvedev91 commented 7 months ago

Arm M1 Pro. The environment is the same as the last successful release. How can I reproduce the error on my local machine to try to solve the problem myself?

licaon-kter commented 7 months ago

Interesting, we had another macos built app recently have the same issue: https://github.com/realOxy/M3UAndroid/issues/75#issuecomment-1895446912

Can you do one test? build the APK 2 times and compare sha256 sums

Medvedev91 commented 7 months ago

(base) ➜ timetome-app git:(main) shasum -a 256 android_app/fdroid/release/fdroid-release.apk a5cd60a415ba34d97cf03de2e43f5c8df27f4b3f35c85a7ce1a51b062d50cb96 android_app/fdroid/release/fdroid-release.apk (base) ➜ timetome-app git:(main) shasum -a 256 android_app/fdroid/release/fdroid-release.apk 6ffd03c56f187f883e7f26a8d80f580f0d260e6c25eb0cf4834caab059eaecc6 android_app/fdroid/release/fdroid-release.apk (base) ➜ timetome-app git:(main) shasum -a 256 android_app/fdroid/release/fdroid-release.apk 6cf46af154863f57c9095ae56acaa1dc30031f1b8205863fe8892c520d89d9e4 android_app/fdroid/release/fdroid-release.apk

Yes, after deleting the "/build" folder and rebuilding this changes.

licaon-kter commented 7 months ago

Ok so the tooling is faulty on macOS :(

fyi @linsui

licaon-kter commented 7 months ago

@appstome you're building in the IDE (pressing Build->etc) or command line?

linsui commented 7 months ago

Oh, the apks built on MacOS are not reproducible themselves?

Medvedev91 commented 7 months ago

you're building in the IDE (pressing Build->etc) or command line?

Yes, Build->Generate Signed Bundle / Apk

Tried on IntelliJ IDEA and Android Studio.

Medvedev91 commented 7 months ago

Oh, the apks built on MacOS are not reproducible themselves?

I'am not a gradle-expert, I'am a developer :). I think I do something wrong with the build, but I have no clues to dig into it.

linsui commented 7 months ago

Can you share the apks?

Medvedev91 commented 7 months ago

fdroid-release-79c4193e024018fc445250381082dfb50257cf68a53f5b3a4650eb6aec26aa39.apk.zip

fdroid-release-f1969d2039cc4eb00d5bf4571c19a6f654e0b464ddcb57bba36c5000b8ded520.apk.zip

Apks with sha256-names.

licaon-kter commented 7 months ago

17e3f5c5d0bc52856e4dc1df229787c2ec454a3e hence the APK in https://github.com/appstome/timetome-app/releases/tag/v2024.01.19.462 verified locally https://gitlab.com/fdroid/fdroiddata/-/commit/22fd4ee306cffd51fdae3814dddb43b6e312e4a2 :tada:

@appstome what did you do special?

Medvedev91 commented 7 months ago

17e3f5c

Ups, the wrong commit message. It should be v2024.01.19.462

what did you do special?

Nothing. But before building, I deleted the "/build" folder from all modules manually.

licaon-kter commented 7 months ago

Maybe that's the trick