Skip to content

Comments

feat: Show Android notifications when patch and manager updates are available#217

Merged
MarcaDian merged 13 commits intodevfrom
notifications
Feb 19, 2026
Merged

feat: Show Android notifications when patch and manager updates are available#217
MarcaDian merged 13 commits intodevfrom
notifications

Conversation

@MarcaDian
Copy link
Collaborator

@MarcaDian MarcaDian commented Feb 17, 2026

Overview

WorkManager with PeriodicWorkRequest is unreliable for timely update notifications. On Android 6+ devices, Doze mode delays background tasks by hours. On Xiaomi, Samsung, Huawei, and OnePlus devices, aggressive battery optimisation systems kill background processes entirely. In practice, users often never receive notifications unless they open the app manually.

What changed

Firebase Cloud Messaging (FCM) is now the primary notification delivery channel. High-priority FCM messages are delivered by Google Play Services - a system process exempt from Doze restrictions - ensuring notifications arrive even on devices with aggressive battery optimisation. WorkManager remains as a silent fallback for devices without Google Play Services.

Four-topic subscription model

Manager and patch notifications are independent, each with a stable and dev variant:

Topic Audience
morphe_updates Manager updates - stable build with prereleases OFF
morphe_updates_dev Manager updates - dev build OR prereleases ON
morphe_patches_updates Patch updates - prereleases OFF
morphe_patches_updates_dev Patch updates - prereleases ON

A device running a dev manager build with prereleases OFF subscribes to both manager topics, since a stable release (e.g. 1.5.0) is a valid upgrade from a dev build (e.g. 1.5.0-dev.1). The patches topic is determined solely by the "Use prereleases" preference, independent of the manager build variant.

Settings UI

On devices with Google Play Services, the WorkManager check frequency selector is hidden - it is not relevant when FCM handles delivery. Devices without GMS retain the full interval configuration UI.

Release workflow

FCM notifications are sent automatically from GitHub Actions after each release.

@MarcaDian MarcaDian force-pushed the notifications branch 2 times, most recently from c03b2c5 to 2836a01 Compare February 17, 2026 17:14
@MarcaDian
Copy link
Collaborator Author

MarcaDian commented Feb 17, 2026

Interestingly, with this PR, I started getting patching notifications. I've never seen them before, even upstream. Probably because permission for notification was not given.

Screenshot_2026-02-17-22-27-56-535_app.morphe.manager-edit.jpg

Screenshot_2026-02-17-22-27-35-285_app.morphe.manager-edit.jpg

@Jman-Github
Copy link

Couldn't we use something like this? There are community servers hosted too so you don't have to necessarily self host one.
https://unifiedpush.org/

@LisoUseInAIKyrios
Copy link
Contributor

A push notification service would be best.

We can later figure out something.

@MarcaDian
Copy link
Collaborator Author

I have a Xiaomi and notifications still don't come when patches are released. I'll try disabling battery optimization for the manager.

@optimatrix0
Copy link

Would it be possible to add a bubble-style notification for important updates? For example, when a new Manager version is released, a floating bubble could appear (similar to Google Messages chat heads), ensuring the user actually notices it, with a clear “Dismiss” button above it.

That would be really helpful, since critical updates could no longer be missed, especially by users who don’t regularly check the app or standard notifications. It could greatly improve visibility without requiring users to manually look for updates.

@MarcaDian MarcaDian marked this pull request as ready for review February 18, 2026 22:28
@MarcaDian
Copy link
Collaborator Author

Ready to merge?)

@LisoUseInAIKyrios
Copy link
Contributor

Yes I think so

@MarcaDian MarcaDian merged commit dced36b into dev Feb 19, 2026
10 checks passed
@MarcaDian MarcaDian deleted the notifications branch February 19, 2026 11:10
github-actions bot pushed a commit that referenced this pull request Feb 19, 2026
# app [1.8.0-dev.2](v1.8.0-dev.1...v1.8.0-dev.2) (2026-02-19)

### Features

* Show Android notifications when patch and manager updates are available ([#217](#217)) ([dced36b](dced36b))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants