Commit Graph

7 Commits

Author SHA1 Message Date
SoftwareApp 6d031082a3 fix: keep the scan's foreground service inside Android's start budget
ScanController called stopService() from a Dispatchers.Default coroutine right
after startForegroundService(), so a scan that finished at once or a Cancel tap
could beat the pending foreground start on the main thread. ScanService then
never reached startForeground() and Android killed the process a few seconds
later with
RemoteServiceException$ForegroundServiceDidNotStartInTimeException - a stack
with no app frames.

- ScanService enters the foreground in onCreate() and at the top of every
  onStartCommand(), before the Cancel early-return.
- A refused startForeground() (start not allowed, missing service type or
  permission, rejected notification) is logged instead of crashing, and a
  notification error can no longer kill the state collector.
- The service stops itself when it observes scanning == false; nothing outside
  it calls stopService() any more.
- New Robolectric ScanServiceTest covers onCreate, the idle and cancel paths, a
  failing startForeground() and the Android 15 onTimeout path.
- Version 1.1.2 / versionCode 7: versionCode 6 (1.1.1) is already on a Play
  track. CHANGELOG, AGENTS.md, codemap, ROADMAP and the release checklist
  (1.1.2 artefact record and paste-ready notes) are updated.
2026-11-09 00:25:56 +01:00
SoftwareApp 6ff916ba57 fix: bump the freemium release to versionCode 6 2026-10-20 16:08:11 +02:00
SoftwareApp 0803d0f5ad fix: keep WorkManager's Room database constructor in release builds 2026-10-20 10:36:20 +02:00
SoftwareApp 22091dd808 feat: turn the paid app into a freemium app with ads and Pro
- add a single AdMob anchored adaptive banner to the free tier
- add UMP consent and a privacy-options entry point before ads load
- add the one-time Play Billing product `pro_no_ads`; Pro removes the banner
  and nothing else, every scan/selection/deletion feature stays free
- cache the entitlement locally, handle pending purchases, acknowledge and
  retry acknowledgement, and restore from Play on resume
- grandfather paid installs through `legacyPro.cutoffEpochMs`, checking both
  the new package and the old paid package declared in <queries>
- move the Play identity to `de.softwareapp_hb.fotodup.finder.free` while
  keeping the Kotlin namespace `de.softwareapp_hb.fotodup.finder`
- add a debug-only Pro toggle and focused monetisation tests
- add AGENTS.md, docs/codemap.md, docs/codemap.mmd and docs/MONETIZATION.md
- update README, PRIVACY, CHANGELOG, ROADMAP, store copy and the Play checklist
- bump to 1.1.0 / versionCode 4
2026-10-20 09:28:29 +02:00
SoftwareApp 3afa7d777d fix: cut 1.0.2 with versionCode 3, because Play has already used 2
Play Console rejected the 1.0.1 bundle with "Version code 2 has already been used. Try another
version code." - the upload consumed code 2, so re-uploading that artifact can never succeed. The
next release therefore takes versionCode 3 and versionName 1.0.2, which also gives the pending
edge-to-edge fix a version of its own instead of leaving it unreleased.

Rebuilt both artefacts from the new configuration and checked them rather than assuming the bump
propagated: aapt2 dump badging on the release APK reports versionCode='3' versionName='1.0.2'
targetSdk=36, apksigner confirms the upload certificate (AA:8C:3D:6C:...:4C:7A), and the permission
set is unchanged - still no INTERNET. The AAB is 2,940,935 bytes (sha256 534e5ae9...), and the
unit suite is green: 80 tests, 0 failures, 0 errors.

The documents that carried versionCode 2 as the next upload are corrected: the checklist's
versioning step now quotes the rejection, its artifact row carries the new size and hash, ROADMAP
points at versionCode 3, and the 1.0.1 figures stay as history rather than being overwritten.

The first-upload language around pricing is no longer true either, so it is rewritten: code 2 has
already been uploaded, which means the Console pricing state has to be checked before this rollout
instead of set from scratch. If Products > App pricing still offers "Make your app paid", it has to
be done before the app is offered for free, because that switch is one-way.

CHANGELOG records the new 1.0.2 section with both the versionCode explanation and the edge-to-edge
fix, and the checklist gains a ready-to-paste 1.0.2 "What's new" block.
2026-10-18 16:59:50 +02:00
SoftwareApp bb250d1675 fix: set up edge-to-edge without Android 15's deprecated window APIs
Play's release dashboard listed Window.setStatusBarColor, Window.setNavigationBarColor and
LAYOUT_IN_DISPLAY_CUTOUT_MODE_SHORT_EDGES under "deprecated APIs or parameters for
edge-to-edge", starting in vr.b, xr.b and zr.b. None of those are app code: the R8 mapping
resolves vr/xr/zr to androidx.activity's EdgeToEdgeApi26/29/35, and a dexdump of the release
DEX finds six calls to the two colour setters, all reached through
ComponentActivity.enableEdgeToEdge(). Its per-API implementations still paint the bar scrims
(API 21/26/29) and select SHORT_EDGES on API 28/29, which Android 15 deprecates for apps
targeting SDK 35+.

MainActivity now calls ui/theme/EdgeToEdge.applyEdgeToEdge() instead. It keeps the parts that
still matter - setDecorFitsSystemWindows(false), navigation-bar contrast off, cutout mode
"always" on API 30+, and light/dark bar icons read from the system night mode - and drops the
scrim writes. The transparent bars continue to come from the XML theme, which does not
compile into a DEX call, so pre-35 devices look unchanged; API 28/29 keep the platform
default cutout mode rather than the deprecated SHORT_EDGES. The insets handling in
ScannerScreen (TopAppBar and navigationBarsPadding) is untouched.

Verified on the connected Android 12 device in both light and dark mode: the window reports
layoutInDisplayCutoutMode=always and the expected LIGHT_STATUS_BAR/LIGHT_NAVIGATION_BAR
flags, and the screenshots show content behind both bars with readable icons. The rebuilt
release APK and AAB contain zero references to setStatusBarColor/setNavigationBarColor and
no androidx.activity.EdgeToEdge classes; testDebugUnitTest and lintDebug pass (only the
pre-existing OldTargetApi warning). CHANGELOG records the change.
2026-10-18 16:48:02 +02:00
Hadrian Burkhardt 4706e2669c Initial commit: Foto Dup Finder 1.0.1
An Android duplicate-photo finder. Pure-Kotlin core (SHA-256 + dHash hashing, exact and
perceptual union-find grouping, three sensitivity presets) with MediaStore access, a
persistent SQLite hash index and a tiered ScanEngine behind a Jetpack Compose UI.
No INTERNET permission, no ads, no analytics, no account.

Ships versionCode 2 / versionName 1.0.1, carrying the scan-stall hardening (BoundedCall
breaker) and verified against a 5,363-photo device library. 80 JVM unit tests, lint clean.

Release paperwork is in docs/ (Play checklist, store listing, edge-case testing), the
upload-ready Play graphics and screenshots in store-assets/, and the generators for those
assets in tools/.
2026-10-13 23:13:39 +02:00