Repository navigation
sync(trio): merge upstream/dev at 4cc5e7b0e (Syai Ultra CGM, TIR rename, 60 commits) - #39
Merged
Merged
Conversation
Persist LoopKit's DoseEntry.wasProgrammedByPumpUI on BolusStored as isPumpUI (optional, default NO; covered by lightweight migration) on both the insert and the mutable-bolus finalize paths, and show a "Pump UI" secondary label on the treatment row next to "External". Rows stored before this change stay unlabelled, since the flag was never persisted for them. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Fpqi9Wu9PGTDMKdoD8PSfA
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Fpqi9Wu9PGTDMKdoD8PSfA
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01FL5GiaxDEST1SqpMm7pnSM
Editing a meal deleted the old entry and inserted the replacement as two separate Core Data commits. If the insert failed the delete was already durable, and because the save error was only printed the edit still reported success, so the meal was dropped locally and then from Nightscout, Apple Health and Tidepool. A crash between the two commits had the same effect. Add CarbsStorage.replaceCarbs, which deletes the old meal root and its carb equivalents and inserts the new ones on one context, committed by a single save(). Deletes and inserts go through the context rather than batch requests, which would commit on their own. CarbEntryMutationService uses it for replaceMeal, so a failure now leaves the old meal in place and skips the remote deletes.
Saving an edited override awaited uploadProfiles() before it disabled the previous active override, refreshed the configuration and dismissed the form. When the upload threw (e.g. unknown host, non-200 reply), the edit was saved but the form stayed open and the follow-up steps never ran. Upload the profiles after the dismiss, in their own do/catch, and log the error like the other profile editors do. Fixes #1601
- G7SensorKit: flag unusable readings as a sensor issue - OmnipodKit: shared signal-loss test, simplified PKA view - EversenseKit: 365 GetTxCertificate retry with inverted tx_flags - LoopAlgorithm: per-point correction range, emulation options - Pin G7SensorKit to feat/trio-g7-direct in the update script, matching .gitmodules
Carries next-dev's Core Data model (v4 to v8) and its migration. Trio instantiates no LoopKit PersistenceController, so nothing migrates.
…ansaction fix: replace carb entry in a single transaction
Record the CC0 licence for the alarm sounds
The status tag was gated behind the arc's 48h-to-expiry window, so a warning or critical highlight — sensor issue, signal loss, connection refused, sensor failed — could not reach the home screen until the last two days of a session. Until then the user saw a stale reading and a timestamp with no reason for either.
Surfaces CGM sensor problems that were reaching the user as silence.
Updates "TIR Type" setting with newer terminology for improved clarity and accuracy.
Persist wasProgrammedByPumpUI for boluses
…smiss Close the Edit Override form when the Nightscout profile upload fails
Unblocks local builds: the format phase aborted on this package and then reformatted excluded submodule sources.
Add Syai Ultra X1 as CGM
Boluses programmed on the pump itself are stored as BolusStored.isProgrammedByPumpUI but were not included in the Nightscout treatment payload. Send it as isProgrammedByPumpUI on bolus treatments (omitted when false), re-upload an uploaded row when the flag changes on finalization, and include it in the upload-stamp check. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_012tnAW2LeHupxFWSc9HjqUg
Rebuild glucose target profiles when the chart window passes their end
Upload pump-programmed bolus flag to Nightscout
Bump RoundWhiteDiscKit for the SwiftFormat parse fix
Upstream 75e44e2 corrected the inverted SMB low temp rate for sub-30m zero temps (basal * (30 - d) / 30). Four autoISF-off scenarios recorded under the old formula now differ in rate/duration/reason only; the "no temp required" branch flips accordingly. No algorithm source changes.
5 tasks
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.
sync(trio): merge upstream/dev at 4cc5e7b (Syai Ultra CGM, TIR rename, 60 commits)
Source branch:
sync/trio-2026-10-25→ target:devMerge commit:
804801c50cd444b2787f2f4b4c506e6f655f8427(parents781f22efe+4cc5e7b0e)Baseline
dev:781f22efe79d515e8cf82d9dfc7bfa6de536cf38Incoming:
upstream/dev4cc5e7b0ecfa09766f90bf93f898828eacb29b51— 60 commits, 12 merged upstream PRsDiff scope: 46 changed paths (10 submodule gitlinks included), +807 / −100
Summary
Routine upstream sync of
upstream/devinto Taidev, cutting in upstream Trio fromf5cdbfa8bup to4cc5e7b0e(APP_DEV_VERSION1.0.2.14 → 1.0.2.26). The 60 incoming commits add Syai Ultra CGM supportvia the new
SyaiKitsubmodule, move the CGM/pump-bolus and TIR surfaces forward, and bump ten kitsubmodules. All ten conflicts were resolved against the architecture spec; the branch is committed
locally and has not been pushed. Nothing is built locally — CI is the build gate.
What the 60 commits bring
New submodule: SyaiKit
SyaiKit(https://github.com/nightscout/SyaiKit, pinned816108980650863b637934367dc5e35212001956,dev)is added to
.gitmodulesand as an Xcode subproject, withSyaiKit/SyaiKitUIframeworks linked andembedded and included in
Trio.xcworkspace— Syai Ultra CGM support (#1618).Submodule pointer bumps (11 including the new one)
devea224e771776543fcadeve157a861ceadb9fefcdeve1bb6faf0e7a1850fddev5c0fc075af45545185feat/trio-g7-direct82c92f2cfa76748161legacy-loopkit-compat4604ee36f7ef67243amainf974241f5ff8c30e28trioef866fa68c33699595dev928bb79500c6d68b00deve66da6cc37dd6396f0main81610898devFeatures and fixes
lifecycle alerts cataloged.
feat/trio-g7-direct(SystemMemoryReset reconnect fix), LibreLoop to
legacy-loopkit-compat, RoundWhiteDiscKit bumped forthe SwiftFormat parse fix.
TIR Lower Thresholdrename andhelp text,
TimeInRangeTypemodel update, settings-search targets, Stat chart touch-ups.BolusStored.isPumpUIrenamedisProgrammedByPumpUI; pump iconand accessibility label in History → Treatments; the flag is uploaded with Nightscout treatments.
CarbEntryMutationService,CarbsStorage.insertCarbEntry(_:into:areFetchedFromRemote:).documented deviation from the oref JS in
DosingEngine.ACKNOWLEDGEMENTS.mdupdated.scripts/define_common_trio.sh(G7SensorKit branch),scripts/swiftformat.shexcludesSyaiKit.CI version progression
Fork-owned
APP_DEV_VERSIONwas bumped 12 times in range, 1.0.2.15 through 1.0.2.26; the mergedConfig.xcconfigcarries1.0.2.26.Conflicts resolved (10)
Trio/Sources/APS/Storage/CarbsStorage.swiftTrio/Sources/Modules/Home/View/Header/CurrentGlucoseView.swiftstatusDemandsAttentionfix ported for warning/critical only.Trio/Sources/Modules/Settings/SettingItems.swift"Time in Range Type"keys deleted (duplicate dictionary keys crash at runtime).Trio/Sources/Modules/UserInterfaceSettings/View/UserInterfaceSettingsRootView.swift.listRowBackground(Color.chart)) with upstream's TIR rename and hints.Trio/Sources/Modules/History/View/HistoryRootView+Treatments.swift(modify/delete)HistoryRootView.swift.TrioTests/OpenAPSSwiftTests/Parity/goldens/*/determination.jsoncheckout --ours); not hand-merged.Trio.xcodeproj/project.pbxprojAlertCatalogRegistryOmniFaultTestsmembership restored, allConfigEditorrefs purged (Tai removed the feature ind21a90cf5a), stale upstream-removed refs dropped, pre-existing duplicate definitions/memberships fixed (SettingsSearchTests, RileyLinkKit, CalibrationsTests, ContainerResolutionTests,alarm.caf, CriticalAlertAlarmScheduler).Documented deviations from the architecture directive (all reviewed and accepted):
CurrentGlucoseView.swift: a leaked upstreamguard shouldShowArc else { return nil }had landedoutside the markers in Tai's non-optional color getter (compile error) and was removed.
CurrentGlucoseView.swift: thestatusDemandsAttentionport is gated on warning/critical rather thanon any CGM status, so Tai's normal-tier sand-colour/hourglass progression inside the 48-hour window is
unchanged while upstream's fix applies at any sensor age.
UserInterfaceSettingsRootView.swift: upstream's Home Statistics Panel section was not taken verbatim —Tai already carries that section (moved, with a Tai-specific hint) and upstream did not change it in
this range, so taking it would have rendered the picker twice.
project.pbxproj: no secondAlertEntry.swiftbuild file — Tai already compiles the file through492B88F5, a second entry would compile it twice.project.pbxproj: theMKRingProgressView.frameworkfile reference was not kept (no group child inTai's project, it would be an orphan); the SPM product reference stays.
Verification
781f22efe+4cc5e7b0e), single merge commit, correct message, noco-author/tool-attribution trailers.
git diff --checkclean; no unexpected deletions —both the HEAD→worktree and first-parent→merge deletion lists are empty.
plutil -lintonproject.pbxprojpasses; object definitions are unique, every build file sits inexactly one phase list, every file reference in exactly one group, no dangling file/product/list refs
(checked independently by coder and reviewer).
xcrun swiftc -parsepasses on all five resolved Swift files (syntax only).Trio/Sources/Localizations/Main/Localizable.xcstringsis byte-identical to upstream(blob
7bc0ec1180b6bea9fe1405e8939b4959ae8eddc1).(
git ls-remote, all eleven).dev; four conflicteddetermination.jsonfiles retain Tai'svalues. Upstream's low-temp rate/reason change is in the merged engine, so these fixtures may be stale —
the CI parity run must confirm or regenerate them. This is a follow-up, not evidence that parity passes.
49250fe5is notan ancestor; the older local alpha commit
4e5703f4was already part of thedevbaseline andremains so.
Known limitation: Garmin watch-command and autoISF localized strings
Tai's own localized strings for the Garmin/watch-command feature and for autoISF are absent from
dev'sLocalizable.xcstrings. This predates this sync: an earlier sync resolved the localization fileto upstream, and the re-add shipped on
mainin release 1.0.2 but was never backported todev.This sync again takes upstream's file unchanged, so those keys deliberately remain absent — verified at
804801c50: keys such asEnable Watch Commands,Allow Bolus Commands,Bolus from watch is disabled.andOverride started.are missing, and the catalog contains no autoISFkeys at all. Consequence: those UI surfaces fall back to the English source literal in every language.
Re-adding the strings (extracting Tai's fork strings into the catalog) is a separate
devfix and isout of scope for this sync.
CI checklist
git submodule update --init --recursive) —SyaiKitis newand ten pointers moved; local working copies currently differ from the committed pointers.
Trio.xcworkspace, schemeTrio(not the project file).AlertCatalogRegistryOmniFaultTests.determination.jsonfixtures are confirmed or regenerated.SyaiKitexcluded inscripts/swiftformat.sh).Robert merges after CI is green. The orchestrator does not merge.
Full commit list
All 60 incoming commits, oldest first (`origin/dev`..`upstream/dev`)