fix(ui): SOS exit, iOS glass polish, Family Circle demo#121
Open
NITISH-R-G wants to merge 5 commits into
Open
Conversation
… HTTP 401 Honest correction. My earlier 'Gemma 4 is ungated' claim was based on a stale web-search hit that reported gated=false. Re-tested with curl: GET https://huggingface.co/google/gemma-4-E4B-it-GGUF/resolve/main/ gemma-4-e4b-it-Q4_K_M.gguf -> HTTP/2 401 'Invalid username or password.' Google's official repo still requires HF login + terms acceptance even though the weights themselves are Apache 2.0. Anonymous downloads are rejected at the resolve endpoint. Users were correctly seeing: 'Gemma 4 download paused — Hugging Face refused the request (HTTP 401)' Fix: redirect downloads to the community mirrors which DO allow anonymous fetches (verified 302 -> CDN on a clean curl): primary : https://huggingface.co/unsloth/gemma-4-E4B-it-GGUF fallback : https://huggingface.co/ggml-org/gemma-4-E4B-it-GGUF fallback : https://huggingface.co/bartowski/google_gemma-4-E4B-it-GGUF These hold the IDENTICAL model bytes under the same Apache 2.0 license. Unsloth is the most-downloaded Gemma GGUF publisher; ggml-org is the llama.cpp upstream community; bartowski is a long-running, trusted quant-pack maintainer. * lib/services/gemma_model_manager.dart - modelDownloadUrl points at Unsloth (anonymous fetch ok). - New modelDownloadFallbackUrls const w/ ggml-org + bartowski. - downloadModel() now iterates over [primary, ...fallbacks] and fails over on 401/403/404/429. Other HTTP errors bubble immediately so the caller sees a clean message. - Refactored the actual byte-streaming into _downloadFromUrl() so each candidate URL gets the full resumable-with-Range treatment. - Error copy no longer claims the model is 'Apache 2.0 + ungated' — it correctly explains the mirror failed + the next will be tried. - hfModelCardUrl points at the Unsloth model card (matches the URL we actually download from, so 'View model card' opens cleanly). Verification: ✅ curl -sI https://huggingface.co/unsloth/gemma-4-E4B-it-GGUF/ resolve/main/gemma-4-E4B-it-Q4_K_M.gguf -> HTTP/2 302 -> Location: cas-bridge.xethub.hf.co/... (anonymous fetch succeeds, redirects to CDN). ✅ flutter analyze -> 0 issues across the workspace. ✅ flutter test -> 17/17 passing. ✅ flutter build apk --debug -> 254 MB APK produced in 13 s. Co-authored-by: Nitish R.G. <NITISH-R-G@users.noreply.github.com>
- Retry transient ClientException/connection-closed up to 5x per mirror with Range resume, then fail over across Unsloth/ggml-org/bartowski. - User-facing errors strip long signed CDN URLs from the banner. - Tap Gemma banner to retry; auto-retry on Wi-Fi after failed state. - Remove duplicate StatusIndicatorBar from Safety Tools tab (kept in app bar). Co-authored-by: Nitish R.G. <NITISH-R-G@users.noreply.github.com>
- endSosSession() clears persisted sos_active; no trap on app restart - End session in app bar, bottom bar, active view, pipeline cancel - Frosted glass nav + tool cards (BackdropFilter); liquid_glass_easy dep - Family Circle demo preview + isSelf fix + Cupertino-style chrome - Teardown mesh + family publish on SOS end Co-authored-by: Nitish R.G. <NITISH-R-G@users.noreply.github.com>
- Remove Demo Mode tool and all demo/simulated UI copy - Family Circle auto-creates Home Circle or shows local layout silently - Drop fake Nearby Services dispatch channel; unify Family Circle naming - Single Medical ID entry (Profile tab only); remove duplicate from Tools Co-authored-by: Nitish R.G. <NITISH-R-G@users.noreply.github.com>
- Keep endSosSession, no demo UI, Family Circle auto-setup, glass polish - Keep gemma download retry/resume from branch - Integrate main: shield branding, real nearby_services broadcast, launcher icons Co-authored-by: Nitish R.G. <NITISH-R-G@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Critical fix — SOS stuck after restart
Root cause:
sos_activein SharedPreferences restoredSOSPhase.activeon every cold start with no way to exit.Fix:
endSosSession()— full teardown (prefs, wake lock, beacon, mesh, family publish, notification)sos_activeinstead of re-entering full-screen SOSUI polish (iOS / liquid glass)
RoadSosGlassPanel+liquid_glass_easydependency for future lens effects)Family Circle
isSelf(compare auth uid, not owner role)Verify