From bbd4a66f111478f3e0bd0b131a9cb83df3f50ae0 Mon Sep 17 00:00:00 2001 From: Land <84073086+LandWarderer2772@users.noreply.github.com> Date: Sat, 14 Mar 2026 15:20:35 +0000 Subject: [PATCH 1/3] fix(ci): skip Sentry upload tasks when SENTRY_AUTH_TOKEN is absent Guard autoUploadProguardMapping and autoUploadSourceContext behind a null/empty check on SENTRY_AUTH_TOKEN to prevent build errors in local and dev environments. Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode) Co-authored-by: Sisyphus --- app/build.gradle | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/app/build.gradle b/app/build.gradle index 2f5f5520b0..1da8b98493 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -240,4 +240,10 @@ sentry { // this will upload your source code to Sentry to show it as part of the stack traces // disable if you don't want to expose your sources includeSourceContext = true + + // Skip all Sentry Gradle plugin tasks (source upload, mapping upload, etc.) + // if SENTRY_AUTH_TOKEN is not provided — avoids build errors in local/dev environments + def sentryAuthToken = System.getenv('SENTRY_AUTH_TOKEN') + autoUploadProguardMapping = sentryAuthToken != null && !sentryAuthToken.isEmpty() + autoUploadSourceContext = sentryAuthToken != null && !sentryAuthToken.isEmpty() } From 895209eaf7e41b47985347ecaace20057060c1d5 Mon Sep 17 00:00:00 2001 From: Land <84073086+LandWarderer2772@users.noreply.github.com> Date: Sat, 14 Mar 2026 15:20:47 +0000 Subject: [PATCH 2/3] fix: default crash analytics opt-in to false Change the crash analytics preference default from true to false across AppSettings (runtime default), sheet_welcome.xml (welcome screen checkbox), and pref_services.xml (settings UI default) so users are not automatically opted in. Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode) Co-authored-by: Sisyphus --- .../io/github/landwarderer/futon/core/prefs/AppSettings.kt | 2 +- app/src/main/res/layout/sheet_welcome.xml | 2 +- app/src/main/res/xml/pref_services.xml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/app/src/main/kotlin/io/github/landwarderer/futon/core/prefs/AppSettings.kt b/app/src/main/kotlin/io/github/landwarderer/futon/core/prefs/AppSettings.kt index ec676d8c8e..dc8de1b4b7 100644 --- a/app/src/main/kotlin/io/github/landwarderer/futon/core/prefs/AppSettings.kt +++ b/app/src/main/kotlin/io/github/landwarderer/futon/core/prefs/AppSettings.kt @@ -581,7 +581,7 @@ class AppSettings @Inject constructor(@ApplicationContext context: Context) { get() = prefs.getBoolean(KEY_STATS_ENABLED, false) var isCrashAnalyticsEnabled: Boolean - get() = prefs.getBoolean(KEY_CRASH_ANALYTICS_ENABLED, true) + get() = prefs.getBoolean(KEY_CRASH_ANALYTICS_ENABLED, false) set(value) = prefs.edit { putBoolean(KEY_CRASH_ANALYTICS_ENABLED, value) } val isAutoLocalChaptersCleanupEnabled: Boolean diff --git a/app/src/main/res/layout/sheet_welcome.xml b/app/src/main/res/layout/sheet_welcome.xml index 07a8a0509c..547d278d49 100644 --- a/app/src/main/res/layout/sheet_welcome.xml +++ b/app/src/main/res/layout/sheet_welcome.xml @@ -110,7 +110,7 @@ android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginStart="@dimen/margin_normal" - android:checked="true" /> + android:checked="false" /> diff --git a/app/src/main/res/xml/pref_services.xml b/app/src/main/res/xml/pref_services.xml index 692b65fc79..d8de8d6e63 100644 --- a/app/src/main/res/xml/pref_services.xml +++ b/app/src/main/res/xml/pref_services.xml @@ -78,7 +78,7 @@ app:icon="@drawable/ic_discord" /> Date: Sun, 15 Mar 2026 12:41:34 +0530 Subject: [PATCH 3/3] fix: update keystore fingerprint and skip Sentry source upload without auth token --- .gitignore | 3 +++ CI.md | 4 ++-- README.md | 2 +- app/build.gradle | 1 + .../io/github/landwarderer/futon/core/os/AppValidator.kt | 2 +- 5 files changed, 8 insertions(+), 4 deletions(-) diff --git a/.gitignore b/.gitignore index 0ce2c01344..f429aecdb4 100644 --- a/.gitignore +++ b/.gitignore @@ -36,3 +36,6 @@ sentry.properties # JVM crash and replay logs hs_err_pid*.log replay_pid*.log +# Keystore files — never commit signing keys +*.jks +*.keystore diff --git a/CI.md b/CI.md index 1adbf63000..c6ab8d1d9f 100644 --- a/CI.md +++ b/CI.md @@ -60,7 +60,7 @@ A new keystore was generated with: Key Alias: futon-key Keystore Password: [from setup] Key Password: [from setup] -SHA-256 Fingerprint: BB:1C:14:0D:E0:07:78:59:1F:93:D2:FB:43:AC:B3:5A:BA:86:71:3A:20:8F:6F:1A:D4:2D:29:EC:7D:3A:CD:C5 +SHA-256 Fingerprint: EF:48:B2:2E:F2:C5:40:45:53:1F:6E:76:00:C2:7E:C3:D0:3B:71:22:1E:0B:05:FF:B6:8E:33:57:CF:8E:4D:40 ``` ## Local Development Setup @@ -131,7 +131,7 @@ The workflow checks for commits since the last nightly release. If no commits ex Current release keystore SHA-256 fingerprint: ``` -BB:1C:14:0D:E0:07:78:59:1F:93:D2:FB:43:AC:B3:5A:BA:86:71:3A:20:8F:6F:1A:D4:2D:29:EC:7D:3A:CD:C5 +EF:48:B2:2E:F2:C5:40:45:53:1F:6E:76:00:C2:7E:C3:D0:3B:71:22:1E:0B:05:FF:B6:8E:33:57:CF:8E:4D:40 ``` This matches the built-in app validator check in `AppValidator.kt`. All release builds must use a keystore with this fingerprint for proper app signature validation. diff --git a/README.md b/README.md index f3b7f1bcdd..10a74bf9c5 100644 --- a/README.md +++ b/README.md @@ -139,7 +139,7 @@ Join our Discord for support, discussion, and announcements: https://discord.gg/ ### Certificate fingerprints ```plaintext -BB:1C:14:0D:E0:07:78:59:1F:93:D2:FB:43:AC:B3:5A:BA:86:71:3A:20:8F:6F:1A:D4:2D:29:EC:7D:3A:CD:C5 +EF:48:B2:2E:F2:C5:40:45:53:1F:6E:76:00:C2:7E:C3:D0:3B:71:22:1E:0B:05:FF:B6:8E:33:57:CF:8E:4D:40 ``` ### License diff --git a/app/build.gradle b/app/build.gradle index 1da8b98493..ffee743e27 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -244,6 +244,7 @@ sentry { // Skip all Sentry Gradle plugin tasks (source upload, mapping upload, etc.) // if SENTRY_AUTH_TOKEN is not provided — avoids build errors in local/dev environments def sentryAuthToken = System.getenv('SENTRY_AUTH_TOKEN') + includeSourceContext = sentryAuthToken != null && !sentryAuthToken.isEmpty() autoUploadProguardMapping = sentryAuthToken != null && !sentryAuthToken.isEmpty() autoUploadSourceContext = sentryAuthToken != null && !sentryAuthToken.isEmpty() } diff --git a/app/src/main/kotlin/io/github/landwarderer/futon/core/os/AppValidator.kt b/app/src/main/kotlin/io/github/landwarderer/futon/core/os/AppValidator.kt index 09dae44cbf..02da60edaa 100644 --- a/app/src/main/kotlin/io/github/landwarderer/futon/core/os/AppValidator.kt +++ b/app/src/main/kotlin/io/github/landwarderer/futon/core/os/AppValidator.kt @@ -21,6 +21,6 @@ class AppValidator @Inject constructor( } private companion object { - private const val CERT_SHA256 = "67e15100bb809301783edcb6348fa3bbf83034d91e62868a91053dbd70db3f18" + private const val CERT_SHA256 = "ef48b22ef2c54045531f6e7600c27ec3d03b71221e0b05ffb68e3357cf8e4d40" } }