Repository navigation
Sync upstream feat/tandem (Tandem Mobi pump support) into dev - #48
Merged
Merged
Conversation
Vendors jwoglom/TandemKit (main @ 50cb9f9) and wires it into the device catalog, the workspace and the app target, from jwoglom's feat/tandem. Trio-side additions on top of that: - Alert catalog resolves Tandem's <category>.<slug>.<bit> identifiers by slug prefix, so pump alarms reach the Critical tier and an unmapped bit falls back to its category instead of bypassing Device Alarms. - Package.resolved pins the SwiftECC and Digest packages TandemKit links. - Tests for the slug resolver, plus Tandem rows in the device catalog suite; the emission suite's "TandemKit issues no alerts" premise is rewritten, since the vendored driver does. - SwiftFormat skips the submodule, as it does for every other kit. - TANDEM_TESTING.md for closed-beta testers. Co-Authored-By: James Woglom <j@wogloms.net>
Picks up multi-packet response reassembly on the notification path, the temp-basal stop when the pump rescales on a schedule change, and history backfill on by default. No change to the alert slugs, plugin identifier or basal grid Trio keys on. Co-Authored-By: James Woglom <j@wogloms.net>
GitHub's New branch dialog can branch straight from the upstream repo, so testers no longer have to open and merge a pull request into their own fork. Adds why the branch name must match (build_trio.yml syncs from the upstream branch of the same name) and how to start the build.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01SAjYPvDm7NRwiKAJAMnkuQ
Dev added the SyaiKit CGM in the same places the Tandem wiring lives: submodule list, workspace, SwiftFormat excludes, device catalog imports and manufacturers, and the alert catalog's entry list. Both kits stay. Also drops the duplicate LoopAlgorithm and RoundWhiteDiscKit package product entries the pbxproj merge produced, keeping ASN1 and BigInt.
TandemKit's main has not moved since 18 Oct and is fully contained in dev, which is where the driver work lands — the pin it replaces was already a dev commit. Picks up the pairing scan following every pump it hears, sleep schedule writes, a deleted temp's remainder across a segment change, and the setup history load. The identifiers, slugs and basal grid Trio keys on are unchanged.
…o feat/tandem-next-dev # Conflicts: # TandemKit
Move the Tandem beta to LoopKit next-dev
…eta-next-dev # Conflicts: # .gitmodules # Trio/Sources/Services/Alerts/AlertCatalogRegistry.swift
TandemKit at 2bfa207a imported LoopAlgorithm and used prepareForDeactivation, both gone from dev's LoopKit. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The home screen and the Nightscout device status take the reservoir from PumpManager.currentReservoir, which had no TandemPumpManager case, so a Tandem pump showed no reservoir from the next-dev build on. Claude-Session: https://claude.ai/code/session_01XhwmAX4SHZZXz9eQdp6rch Co-authored-by: Claude <noreply@anthropic.com>
…ext-dev Resolve .gitmodules: keep SyaiKit tracking trio-next-dev as dev does, and TandemKit tracking next-dev, whose tip the submodule is pinned to. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01XhwmAYhaDeAK4ZYD8bnza2
…-dev Merge tandem-closed-beta-next-dev into tandem-closed-beta
Create Open Beta Branch for Tandem Mobi
Resolve project.pbxproj: add TandemKit framework, ASN1/BigInt products and AlertCatalogRegistryTandemTests while keeping all Tai-only references; drop upstream's BolusDisplayThreshold build file and RileyLinkKit/OmniFault entries that Tai already carries. Package.resolved keeps the union of pins.
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.
Target:
mountrcg/Tai— head branchsync/tandem-2026-11-20(636cb48) →dev(50bf488)Tandem Mobi pump support from upstream
feat/tandemWhat changed
Brings the upstream Tandem Mobi driver into the Tai fork. 13 files, +653 / −101 against
dev@50bf4889b; the branch isdevplus one merge commit (636cb48) of upstreamfeat/tandem@888326d9e.TandemKit submodule (
.gitmodules, gitlinkTandemKit)TandemKit is a public community repository and is the actual driver (Bluetooth, pairing,
pump commands, history parsing); this PR only wires it into Trio. It adds two SwiftPM
dependencies of its own, pulled in through the submodule's package:
Digest1.13.0 andSwiftECC5.5.0 (Package.resolved), plus theASN1/BigIntframework links inproject.pbxproj.Device catalog —
Trio/Sources/APS/Devices/DeviceCatalog.swiftDeviceManufacturer.tandemcase ("Tandem") between Syai and Other Sources.PumpCatalogEntry(TandemPumpManager.self, id: "TandemPumpManager", manufacturer: .tandem, name: "Tandem", supportedModels: ["Mobi"], icon: .managerBundle(asset: "tandem_mobi"), basalCapability: TandemPumpManager.onboardingSupportedBasalRates, reportsRewindEvents: true).Reservoir reporting —
Trio/Sources/APS/DeviceDataManager.swiftimport TandemKit, and acase let tandem as TandemPumpManagerin thePumpManagerextension that returns
tandem.reservoirLevel.map { Decimal($0.unitVolume) }— the sameplace Dana, Medtronic and Omnipod already read their reservoir from.
Alert catalog —
Trio/Sources/Services/Alerts/AlertCatalogRegistry.swift(+158 / −2)tandemEntriesadded to the registry chain: ~30 entries covering TandemKit's alarms(occlusion, empty/removed cartridge, auto-off, battery shutdown, temperature, altitude,
pressure, pump reset, stuck button, …) at
.critical, and its alerts (low insulin, lowpump battery, charging problem, max basal, …) at
.timeSensitive/.active.TandemPumpManagerplugin identifier, which is what TandemKitissues its alerts under, so acknowledgement reaches TandemKit's registered responder.
TandemKit mints one identifier per notification bit (
<category>.<slug>.<bit>), and thebit position moves between firmwares, so
tandemEntry(for:)strips the trailing bit andmatches on the stable
<category>.<slug>prefix;alarm.otherandmalfunctionact ascategory fallbacks.
forwards them, they duplicate Trio's own glucose alarms, and the threshold ones have no
device concept to collapse onto).
Tests
TrioTests/AlertCatalogRegistryTandemTests.swift— new (128 lines), prefix matching,severity mapping and fallbacks.
TrioTests/TandemKitAlertEmissionTests.swift— rewritten (82 / −95) for the newbit-suffixed identifiers.
TrioTests/DeviceCatalogTests.swift— +10 / −3, covers the Tandem entry.Project wiring
Trio.xcworkspace/contents.xcworkspacedata—TandemKit/TandemKit.xcodeprojreference.Trio.xcodeproj/project.pbxproj— framework reference, link + embed (CodeSignOnCopy),test target sources.
scripts/swiftformat.sh—--exclude TandemKit.TANDEM_TESTING.md— upstream's testing guide for the closed beta (unchanged from upstream).Upstream commits
Merged from
nightscout/Triofeat/tandem@888326d9e (Upstream-Trio remote):888326d9e— Merge PR #1786feat/tandem-closed-beta04edbd7d7— Merge branchfeat/tandemintofeat/tandem-closed-betaa809e6f97— Merge PR #1785feat/tandem-closed-beta-next-devf43b68dd6— Merge branchfeat/tandem-closed-betaintofeat/tandem-closed-beta-next-devWhat Tai keeps
Config.xcconfiguntouched —APP_VERSION = 1.0.2,APP_DEV_VERSION = 1.0.2.79.Testflight/WhatToTest.en-CA.txtstill reads"based on Trio dev 1.0.2.79".
APP_DISPLAY_NAME = Tai,BUNDLE_IDENTIFIER = org.nightscout.$(DEVELOPMENT_TEAM).tai,COPYRIGHT_NOTICE = autoISF,RELEASE_NOTES_REPO = mountrcg/Tai.(
AutoISF.swift+ assets), the CSF units fix inTherapySchedulePDFContent, theupstream-pump-availability home header fix, and the fork CI dispatcher in
.github/workflows/are all untouched by this merge.addition).
feat/profilesinvolvement — the upstream profiles merge stays reverted on thisbranch (96a3cdd), and this sync adds none of it back.
Known upstream rough edges carried along (documented in TANDEM_TESTING.md, not blockers for
this sync): TandemKit is pinned straight at
jwoglom/TandemKitwhile every other submodulepoints at a
loopandlearnfork (scripts/define_common_trio.shdoes not know about it), thereis no
CODEOWNERSentry, and nothing in Trio reacts to the pump's Control-IQ state. Thedoc's "pinned to
960556cofmain" line is upstream text; the pin actually in this branchis
781bedc9fonnext-dev.Verification
From the review card (t_c821f4e0), verdict PASS on all five gates:
existing submodules intact.
feat/profilesleakage — PASS: none.781bedc9funchanged and an ancestor ofnext-dev.build-for-testing→ TEST BUILD SUCCEEDED onsync/tandem-2026-11-20(636cb48), pbxproj object graph clean.Not verified yet, so not claimed here:
Checklist before merge
WhatToTest.en-CA.txtstill "based on Trio dev 1.0.2.79"781bedc9fonnext-devverifiedjwoglom/TandemKitverified public (gh api:visibility: public) — the recursiveactions/checkoutresolves the pin over HTTPS with the defaultGITHUB_TOKEN, so noGH_PATread scope on a private repo is neededsync/tandem-2026-11-20(done; CI run triggered on the fork)Tai CI→unit_tests.yml: Algorithm Package + Run Unit Tests)dev