Repository navigation
Conversation
Android treated a missing aw-notify setting as default-on, while the webui panel (ActivityWatch/aw-webui#1057) shows a missing enabled flag as off. Existing installs therefore saw notifications as disabled while alerts still fired. Write the flag once (ActivityWatch/activitywatch#1435, Phase 4): - missing setting: enabled=true on upgrade, enabled=false on a fresh install (opt-in per the spec) - object without enabled: mark enabled (it was being honored) - explicit flags, legacy arrays and malformed values: untouched An enabled config without an alerts key now uses the default alerts, matching aw-notify-rs, so the migration does not freeze today's defaults into user configs. Requires setSetting from ActivityWatch/aw-server-rust#816. Git-Session-Id: 32917eef-fbfb-4163-ac3f-2cdd64971ee1
|
Git-Session-Id: 92f0709c-4d1d-53e8-9e34-1d33dea3a33b
🤖 AI code reviewSafe to merge — no P0/P1 findings on latest reviewUpdated after inline dispositions on finding threads — this is the current state; the verdict below is frozen at review time and is kept as the historical record of that pass. Finding disposition
Needs a look — P2 onlyConfidence 4/5 3 findings ·
|
|
@greptileai review |
The setSetting JNI binding merged in ActivityWatch/aw-server-rust#816. This unblocks the migrateNotifyOptIn migration which was crashing with UnsatisfiedLinkError at runtime. Git-Session-Id: 9a2f21f3-9f6b-44b7-8971-bd677dab0aaa
|
ActivityWatch/aw-server-rust#816 ( PR remains draft pending device verification (as noted in the description). |
|
Device verification on an x86_64 emulator (API 36,
Durability window (non-blocking, follow-up): the datastore worker does not force a commit on |
Phase 4 of the aw-notify opt-in architecture (ActivityWatch/activitywatch#1435): make the shared
enabledflag explicit on Android.Draft: depends on ActivityWatch/aw-server-rust#816 (
setSettingJNI). Theaw-server-rustsubmodule bump goes into this PR once that merges. Until then the native symbol is missing and the migration call would fail. Device verification is still required before this draft is ready.Problem
Android treats a missing
aw-notifysetting as default-on (preserved in #329). The already-pinned webui panel reads a missingenabledas off. Existing installs therefore see “Notifications: off” while alerts fire; fresh installs are not opt-in.Change
A one-shot migration on service start writes the flag:
aw-notify{"enabled":true}{"enabled":false}alerts, withoutenabled"enabled":truealerts, explicit flag, legacy array, malformed valuelastUpdateTime > firstInstallTime; lookup failure preserves upgrade behavior.enabled=truewithoutalertsselects default alerts, matching the canonical Rust setting. Explicitalerts=[]suppresses alerts. This intentionally changes the previously fail-closed enabled-without-alerts shape;{}and unrelated-key objects remain fail-closed.Known limitations before readiness
Verification
Fix commit
4ad9d20b2a76addresses both original Greptile findings: empty-object promotion and startup consent race.:mobile:testStandardDebugUnitTest: 263 tests across 27 suites, zero failures/errors.