feat: implement app upgrade screen from the entry point of the app - #586
feat: implement app upgrade screen from the entry point of the app#586ahmed-tarek-salem wants to merge 3 commits into
Conversation
e997ba8 to
687b60e
Compare
| return null; | ||
| } | ||
|
|
||
| final updateUrls = json['update_urls'] != null |
There was a problem hiding this comment.
@ahmed-tarek-salem The App Store and Play Store URLs are constant — they're fully determined by our fixed bundle ID / package name (org.qubic.wallet), so we can build them in the app instead of reading them from the remote JSON. Letting the remote payload supply the URL means anyone who can write to (or MITM) static.qubic.org can serve a forced update (show_later_button: false + show_ignore_button: false) that routes every user — on a screen they can't dismiss — to an attacker-controlled APK or seed-entry phishing page.
| @@ -1047,5 +1047,15 @@ | |||
| "androidDeprecationDialogMessageBefore": "Future updates will require Android 7.0 or higher. To continue receiving updates and ensure long-term wallet access, please ", | |||
| "androidDeprecationDialogMessageHighlight": "back up your private seeds or export your wallet vault", | |||
| "androidDeprecationDialogMessageAfter": " from Settings.", | |||
There was a problem hiding this comment.
@ahmed-tarek-salem 10 new keys added only to app_en.arb. Missing from app_de/es/fr/ru/tr/vi/zh.arb. Non-English users get fallback English on a forced upgrade gate.
| flutter_is_ios_app_on_mac: ^1.0.1 | ||
| cryptography: ^2.7.0 | ||
| no_screenshot: ^0.3.6 | ||
| version: ^3.0.0 |
There was a problem hiding this comment.
@ahmed-tarek-salem
Redundant dependency: pub_semver: ^2.1.5 is already declared two lines below and is the Dart team's official semver package — it exposes the same Version.parse, Version(0,0,0), and comparison operators that app_update_store.dart uses. We're already consuming pub_semver in wallet_content_store.dart. Drop version: ^3.0.0 and switch the import in app_update_store.dart to package:pub_semver/pub_semver.dart.
App Update Feature
Overview
Checks if a newer app version is available and prompts the user to update. Supports:
How It Works
AppUpdateStore.checkForUpdate()is calledshouldShowUpdateScreen/updateUpdate Options
Depending on the update type and API flags, the user may see:
Update Screen Behavior
API
Endpoint:
GET /wallet-app/version-check.jsonResponse example:
{ "version": "2.5.0", "release_notes": "- Bug fixes\n- Performance improvements", "show_later_button": true, "show_ignore_button": false, "platforms": ["android", "ios"], "update_urls": { "ios": "https://apps.apple.com/app/qubic-wallet/id6502265811", "android": "https://play.google.com/store/apps/details?id=org.qubic.wallet" } }Key Fields
version(required): Minimum required app versionrelease_notes: What’s new (supports line breaks)show_later_button: Allows dismissing for sessionshow_ignore_button: Allows skipping this version permanentlyplatforms: Platforms the update applies toupdate_urls: Store links per platformUser Dismissal Behavior
Edge Cases
0.0.0