Skip to content

Improve Live activity settings and samples#4554

Draft
bgoncal wants to merge 3 commits intomainfrom
live-activity-settings
Draft

Improve Live activity settings and samples#4554
bgoncal wants to merge 3 commits intomainfrom
live-activity-settings

Conversation

@bgoncal
Copy link
Copy Markdown
Member

@bgoncal bgoncal commented Apr 23, 2026

Summary

Screenshots

CleanShot 2026-04-23 at 15 37 09@2x

Link to pull request in Documentation repository

Documentation: home-assistant/companion.home-assistant#

Any other notes

@bgoncal bgoncal self-assigned this Apr 23, 2026
Copilot AI review requested due to automatic review settings April 23, 2026 13:37
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Exposes Live Activities settings in the main Settings UI and refactors the Live Activities screen to focus on status + activity samples, removing older privacy/frequent-update footer copy.

Changes:

  • Add Live Activities to the main Settings “General” section and mark it as a Labs feature.
  • Rework LiveActivitySettingsView to include a Samples sub-screen and fold “Frequent Updates” status into the Status section.
  • Remove now-unused Live Activity privacy and frequent-updates footer localization keys (and SwiftGen accessors).

Reviewed changes

Copilot reviewed 39 out of 39 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
Sources/Shared/Resources/Swiftgen/Strings.swift Removes SwiftGen accessors for deleted Live Activity localization keys.
Sources/App/Settings/Settings/SettingsView.swift Shows the Labs badge for the Live Activities settings row.
Sources/App/Settings/Settings/SettingsItem.swift Adds Live Activities to the General settings list; updates Mac Catalyst hidden items list.
Sources/App/Settings/LiveActivity/LiveActivitySettingsView.swift Refactors layout; adds Samples navigation and frequent updates status row; removes privacy/debug sections.
Sources/App/Settings/DebugView.swift Removes the Live Activities link from DebugView.
Sources/App/Resources/zh-Hant.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/zh-Hans.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/vi.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/uk.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/tr.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/sv.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/sl.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/ru.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/pt-BR.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/pl-PL.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/nl.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/nb.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/ml.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/ko-KR.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/ja.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/it.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/id.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/hu.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/he.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/fr.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/fi.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/et.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/es.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/es-MX.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/es-ES.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/en.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/en-GB.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/el.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/de.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/da.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/cy-GB.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/cs.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/ca-ES.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Sources/App/Resources/bg.lproj/Localizable.strings Removes unused Live Activity privacy/footer keys.
Comments suppressed due to low confidence (1)

Sources/App/Settings/LiveActivity/LiveActivitySettingsView.swift:276

  • startTestActivity requests an Activity directly with pushType: nil and doesn’t go through Current.liveActivityRegistry. However, ending activities in this screen goes through the registry (with only a “first match by tag” fallback), so starting the same sample multiple times can lead to duplicate activities that aren’t reliably ended/updated. Consider using Current.liveActivityRegistry?.startOrUpdate(tag:title:state:) for samples (or otherwise enforce unique tags and consistent start/end paths).

Comment thread Sources/App/Settings/LiveActivity/LiveActivitySettingsView.swift
Comment thread Sources/App/Settings/Settings/SettingsItem.swift
Comment thread Sources/App/Settings/LiveActivity/LiveActivitySettingsView.swift
@codecov
Copy link
Copy Markdown

codecov Bot commented Apr 23, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
⚠️ Please upload report for BASE (main@7c852db). Learn more about missing BASE report.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #4554   +/-   ##
=======================================
  Coverage        ?   43.46%           
=======================================
  Files           ?      275           
  Lines           ?    17882           
  Branches        ?        0           
=======================================
  Hits            ?     7772           
  Misses          ?    10110           
  Partials        ?        0           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@bgoncal bgoncal marked this pull request as draft April 24, 2026 13:42
@bgoncal
Copy link
Copy Markdown
Member Author

bgoncal commented Apr 24, 2026

Keeping it draft while PRs to FCM and Core repos are not merged, since this PR makes live activities settings visible to the end user.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants