Skip to content

Open source Grok Bot alternative, Bring your own agent and subscription: message Claude Code, Codex, Gemini CLI, Cursor, Copilot and 40+ AI agents as bots on your own computer, from iPhone, Mac, Windows, Linux or terminal. Agent-agnostic and free. Also a Muse and Dots alternative. Built in Rust.

fix: skip Live Activity start in background, reduce polling to 5s

libokai92091425978c
diff --git a/Codync-iOS/Services/CloudKitReceiver.swift b/Codync-iOS/Services/CloudKitReceiver.swift
index 720d83e1..a261aefd 100644
--- a/Codync-iOS/Services/CloudKitReceiver.swift
+++ b/Codync-iOS/Services/CloudKitReceiver.swift
@@ -47,8 +47,8 @@ final class CloudKitReceiver: ObservableObject {
func startPolling() {
guard pollTimer == nil else { return }
- logger.info("Starting CloudKit polling (1s interval)")
- pollTimer = Timer.scheduledTimer(withTimeInterval: 1, repeats: true) { [weak self] _ in
+ logger.info("Starting CloudKit polling (5s interval)")
+ pollTimer = Timer.scheduledTimer(withTimeInterval: 5, repeats: true) { [weak self] _ in
Task { @MainActor in
await self?.fetch()
}
diff --git a/Codync-iOS/Services/LiveActivityManager.swift b/Codync-iOS/Services/LiveActivityManager.swift
index f566e848..bc36621f 100644
--- a/Codync-iOS/Services/LiveActivityManager.swift
+++ b/Codync-iOS/Services/LiveActivityManager.swift
@@ -1,6 +1,7 @@
import ActivityKit
import CloudKit
import Foundation
+import UIKit
import UserNotifications
import CodyncShared
import os
@@ -182,6 +183,12 @@ final class LiveActivityManager: ObservableObject {
guard !isTracking(sessionId: session.sessionId) else { return }
guard trackedSessionIds.count < Self.maxActivities else { return }
+ // Can only START Live Activities when app is in foreground
+ guard UIApplication.shared.applicationState == .active else {
+ logger.debug("Skipping Live Activity start — app in background")
+ return
+ }
+
let attributes = CodyncAttributes(
sessionId: session.sessionId,
projectName: session.projectName