Skip to content

chore(release): theme integration + onboarding hotfixes#545

Open
Panosfunk wants to merge 106 commits into
masterfrom
test
Open

chore(release): theme integration + onboarding hotfixes#545
Panosfunk wants to merge 106 commits into
masterfrom
test

Conversation

@Panosfunk

@Panosfunk Panosfunk commented Nov 13, 2025

Copy link
Copy Markdown
Collaborator

Summary

Release branch carrying months of test work into master. Major themes:

  • Theme integration. Replaces the research_package theme with carp_themes_package; refreshes app styling end-to-end (Carp themes package integration #543).
  • Onboarding & study entry. Informed consent moved to backend-driven flow (no local cache flag); consent gate, configure-study loader, pull-to-refresh on invitations, sqflite/Health-Connect pre-warm — accept-to-study transition is now smooth with no UI freezes (PR feat(onboarding): consent gate, pull-to-refresh, faster study entry #583, merged into test).
  • UI polish. Status bar color fix; announcements page redesign with icon-based cards; message details page rework; Bluetooth device list visual updates; status card improvements; heart-rate tooltip fix; new Health Connect imagery.
  • Cache & stability fixes. Fix of cross-study data caching (Data is not saved across log out / log in + Negative Steps #523), "day in study" counter, persistent announcements bleeding across studies, notification-tap routing to tasks, missing iOS status bar.
  • Build / release. Partial transition from CocoaPods to Swift Package Manager on iOS; removed unused Android package; release-on-tag GitHub Action; version code/changelog bumps; translation updates.
  • Android tooling deps. Re-resolved the fastlane dependency tree in android/Gemfile.lock via a single bundle update (fastlane 2.235.0): picks up the faraday 1.10.5 CVE-2026-25765 backport, aws-sdk-s3 1.224.0, and refreshed Google Play API clients. These are CI/build-only gems (not shipped in the app) and this supersedes the per-gem dependabot PRs Bump aws-sdk-s3 from 1.124.0 to 1.208.0 in /android #554 and Bump faraday from 1.10.3 to 1.10.5 in /android #555.

Test plan

  • Fresh install end-to-end on iOS and Android: login → accept invitation → consent → permissions → StudyPage with cards
  • Returning user with cached study: launches directly into StudyPage without freezes
  • Health Connect dialog only shows when HC is genuinely not installed (test on Android <14 or after uninstall)
  • Pull-to-refresh on /invitations
  • Switch studies (leave + accept new): no stale messages, announcements, or cached data from the previous study
  • Day-in-study counter correct (Data is not saved across log out / log in + Negative Steps #523)
  • Theme renders correctly across all pages, including dark mode if used
  • iOS build via SPM still produces a working signed archive
  • Android release lane (bundle exec fastlane) runs cleanly with the updated gems

Panosfunk and others added 27 commits October 13, 2025 12:29
…sed code, ui changes to bluetoth device list, status card ui improvements, improvement of notifications not going to task, heart rate tool tip ui fix
…ary health connect page, changing UI to use icons instead of words for announcement cards
removing unused package for android
@bardram
bardram requested a review from iarata December 2, 2025 09:40

@iarata iarata left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🪴

@Zeroupper Zeroupper added the bug label May 13, 2026
Zeroupper and others added 30 commits June 15, 2026 13:12
Beyond device resolution, assert the protocol declares all expected
sensor/service/app-task Measure types and that each is provided by a
registered sampling package (SamplingPackageRegistry().dataTypes) - so
the app can actually collect every declared type. Tolerant of the
dynamic per-task 'completedapptask.<name>' lifecycle measures. Runs for
both the 1.x (alias) and native 2.x namespaces, so a data-type
registration regression in any package fails the test.

Refs #604
AppConfig is just compile-time-derived config read globally (bloc,
Sensing, CarpBackend), so there is no reason to instantiate it. Convert
it to an abstract class with static fields and drop the singleton
factory. Services no longer take an AppConfig 'config' parameter and the
bloc no longer holds a 'config' instance - everything reads
AppConfig.deploymentMode / .debugLevel / .localization directly. (Keeps
the explicit const on String.fromEnvironment so --dart-define still
applies.)

No behavior change: the static fields hold the same global mutable state
the singleton did. Verified by the full unit suite and the join-study
integration test.
…cting StudyService

ConsentService only needed StudyService to read the current study in the
backend consent check, and that check is reached only via refreshStatus,
which is called only by the bloc (the coordinator that owns StudyService).
Drop the service-to-service dependency: hasBeenAccepted/refreshStatus now
take the study as a parameter and the bloc supplies it. ConsentService is
now a focused leaf (consent manager + backend), independently testable,
with no inter-service edge - and no study plumbing through the view models.
isAnonymous is an authentication fact (set by CarpBackend's authenticate
vs authenticateWithMagicLink), so it belongs behind AuthService. Add the
getter and route the StudyPage/ProfilePage view-models and profile page
through it, removing the direct LocalSettings().isAnonymous reads from
the UI/VM layer.
The manual loop registering device types under the pre-2.x namespace
('dk.cachet.carp.common.application.devices.*') is no longer needed: the
current CAMS packages already register that backward-compat alias
themselves -
  carp_mobile_sensing 2.1.2  -> Smartphone
  carp_context_package 2.0.1 -> Location/Weather/AirQuality services
  carp_health_package 4.0.1  -> HealthService
  carp_polar_package 2.0.1   -> PolarDevice
  carp_movesense_package 2.0.1 -> MovesenseDevice
all under DeviceConfiguration.DEVICE_NAMESPACE. The original dev failure
was on earlier package versions that lacked this; the workaround is now
dead code. The 1.x/2.x protocol parse tests still pass, so they now
guard the packages' backward-compat instead of our alias.
Sensing had grown into a god class owning the study lifecycle
(deployment, status), protocol translation, and study removal on top
of its actual job. This duplicated StudyService, which claimed to be
the single owner of the active study yet delegated everything back.

Move deployment orchestration (addStudy/tryDeployment/removeStudy),
deployment-status fetching, the deployment-service selection, the
runtime controller, and protocol translation into StudyService, the
genuine study owner. Sensing now only registers sampling packages,
data managers, and task factories and configures the client manager
with a deployment service passed in by StudyService.

StudyController equality is value-based (deployment id + role), so the
persisted study resolves the same controller the client manager holds.
Remove the Health Connect READ_* permissions flagged by Google Play as
excessive, keeping only steps, heart rate and exercise. Data types are
driven by the server-side study protocol, so no source changes needed.

Refs #392
refactor(bloc): split StudyAppBLoC into coordinator and services
…types

The app is a generic research data-collection client; the health data types
a study needs are not known at build time. Declare the read permissions for
the range of types studies may request, per issue #653.

Refs #653
- Show a generic health-data disclosure on the connect screen, and an
  instructions dialog - with an app-settings shortcut and a screenshot -
  when Health Connect access is not granted, including when it was
  permanently denied and the system sheet no longer appears.
- Add pull-to-refresh on the devices page to re-check service permission
  state after granting access in settings.
- Bump app to 4.4.0+1 and carp_mobile_sensing / carp_health_package to the
  released fix versions.
fix: Health Connect permission handling and device page UX
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.

5 participants