All of my apps stopped working with WeatherKit this morning. They all return an "Error Domain=WeatherDaemon.WDSJWTAuthenticatorServiceListener.Errors Code=2" error.
I am certain that the WeatherKit capability added (in project) and enabled as a Capability & App Service (on developer portal for the identifier). All other iCloud features of my apps are working as expected. I have also done all the normal troubleshooting using codesign / security cms, etc. to verify entitlements.
I created the following simple project to verify the integration.
import WeatherKit
import CoreLocation
struct ContentView: View {
@State private var temp: Measurement<UnitTemperature>? = nil
var body: some View {
VStack {
if let t = temp {
Text("\(t.value.rounded())°\(t.unit.symbol)")
} else {
Text("Fetching…")
.task {
let service = WeatherService()
do {
let location = CLLocation(latitude: 50.318668, longitude: -114.917710)
let weather = try await service.weather(for: location, including: .current)
temp = weather.temperature
} catch {
print("Error:", error)
}
}
}
}
}
}
Any ideas what may be happening?
General
RSS for tagDelve into the world of built-in app and system services available to developers. Discuss leveraging these services to enhance your app's functionality and user experience.
Selecting any option will automatically load the page
Post
Replies
Boosts
Views
Activity
We are currently developing a VoIP application that supports Local Push extention.
I would like to ask for your advice on how the extension works when the iPhone goes into sleep mode.
Our App are using GCD (Grand Central Dispatch) to perform periodic processing within the extension, creating a cycle by it.
[sample of an our source]
class LocalPushProvider: NEAppPushProvider {
let activeQueue: DispatchQueue = DispatchQueue(label: "com.myapp.LocalPushProvider.ActiveQueue", autoreleaseFrequency: .workItem)
var activeSchecule: Cancellable?
override func start(completionHandler: @escaping (Error?) -> Void) {
:
self.activeSchecule = self.activeQueue.schedule(
after: .init(.now() + .seconds(10)), // start schedule after 10sec
interval: .seconds(10) // interval 10sec
) {
self.activeTimerProc()
}
completionHandler(nil)
}
}
However In this App that we are confirming that when the iPhone goes into sleep mode, self.activeTimerProc() is not called at 10-second intervals, but is significantly delayed (approximately 30 to 180 seconds).
What factors could be causing the timer processing using GCD not to be executed at the specified interval when the iPhone is in sleep mode?
Also, please let us know if there are any implementation errors or points to note.
I apologize for bothering you during your busy schedule, but I would appreciate your response.
I am trying to implement Apple Login on the web.
The language I am using is PHP.
I have created the App ID, Service ID, and Key.
In the Service ID, I clicked the Configure button for Sign In With Apple and entered the domain and return URL.
However, when I click the login button, I only get an "invalid_client" error screen.
Topic:
App & System Services
SubTopic:
General
Tags:
Sign in with Apple REST API
Sign in with Apple
Sign in with Apple JS
I have a SwiftUI document-based app that for the sake of this discussion stores accounting information: chart of accounts, transactions, etc. Each document is backed by a SwiftData DB.
I'd like to incorporate search into the app so that users can find transactions matching certain criteria, so I went to Core Spotlight. Indexing & search within the app seem to work well.
The issue is that Spotlight APIs appear to be App based & not Document based. I can't find a way to separate Spotlight data by document.
I've tried having each document maintain a UUID as a document-specific identifier and include the identifier in every CSSearchableItem. When performing a query I filter the results with CSUserQueryContext.filterQueries that filter by the document identifier. That works to limit results to the specific file for search operations.
Index updates via CSSearchableIndexDelegate.reindex* methods seem to be App-centric. A user may have file #1 open, but the delegate is being asked to update CSSearchableItems for IDs in other files.
Is there a proper way to use Spotlight for in-app search with a document-based app?
Is there a way to keep Spotlight-indexed data local within the app & not make it available across the system? I.e. I'd like to search within the app only. System-level searches should not surface this data.
I just adding a way to donate my app's data to Core Spotlight using CSSearchableIndex, but I'm finding that spotlight is only searching for the title of the CSSearchableItem I create. I know the index is working, because it always finds the item through the title property, but nothing else.
This is how I'm creating the CSSearchableItem:
- (CSSearchableItem *) createSearchableItem {
CSSearchableItemAttributeSet* attributeSet = [[CSSearchableItemAttributeSet alloc] initWithContentType: UTTypeText];
attributeSet.title = [self titleForIndex];
attributeSet.displayName = [self titleForIndex];
attributeSet.contentDescription = [self contentDescriptionForIndex];
attributeSet.thumbnailData = [self thumbnailDataForIndex];
attributeSet.textContent = [self contentDescriptionForIndex];
CSSearchableItem *item = [[CSSearchableItem alloc] initWithUniqueIdentifier: [self referenceURLString] domainIdentifier:@"com.cjournal.cjournal-Logs" attributeSet:attributeSet];
item.expirationDate = [NSDate distantFuture];
return item;
}
There's a lot of confusing tips around which say specifying the 'textContent' should work, and/or setting the displayName is essential, but none of these are working.
Is there something I'm missing with my setup?
Thanks.
We have an application which is written in Swift, which activates Transparent Proxy network extension. We are using Jamf MDM profile for deployment.
To avoid the user deleting / disabling the extension from General -> LogIn Items & Extension -> Network Extensions screen, we are using "Non-removable system extensions from UI" attribute under Allowed System Extensions and Teams IDs section.
In new Mac OS 26 (Tahoe), user can also enable/disable the extension from General -> LogIn Items & Extension -> Apps tab. The "Non-removable system extensions from UI" attribute set in Jamf MDM profile does not apply to this tab.
Same attribute is working for General -> LogIn Items & Extension -> Extensions tab and there the slider is greyed out and Remove option is not available under more menu.
Is there any new key/configuration defined to disable the slider from General -> LogIn Items & Extension -> Apps tab?
Created https://feedbackassistant.apple.com/feedback/18198031 - FB18198031 feedback assistant ticket as well.
Topic:
App & System Services
SubTopic:
General
Tags:
Network Extension
System Extensions
Device Management
Could someone please explain how to use a custom sound when setting up an alarm using AlarmKit? It keeps playing a default sound.
Also, I keep having an issue where the alarm sound plays but doesn’t show the alarm interface buttons unless the screen is locked.
Topic:
App & System Services
SubTopic:
General
Hi All, I’m puzzled by this issue: my app uses WeatherKit to fetch hourly UV-index and temperature forecasts. The same build, running on the latest iOS, succeeds on most devices but consistently fails on a few. Strangely, the paired Apple Watch version retrieves the data without problems. Could WeatherKit be applying per-user throttling? Any insight would be greatly appreciated.
How to programmatically check if ApplicationToken or ActivityCategoryToken is expired in FamilyActivityPicker?
I'm building a Screen Time-based parental control app using FamilyControls and ManagedSettings. We use FamilyActivityPicker to allow the user to select apps and categories to restrict, and we apply the shield using:
store.shield.applications = .specific(selection.applicationTokens)
store.shield.applicationCategories = .specific(selection.categoryTokens)
Sometimes, we observe that the shield silently fails to apply — no error is thrown, but the restrictions aren't enforced. I suspect this may be due to expired or invalid tokens, possibly if the app was removed or the selection became stale.
My Questions:
Can ApplicationToken or ActivityCategoryToken expire or become invalid over time?
If yes, is there a supported or recommended way to detect whether a token is still valid before applying it to the shield?
Is comparing the current shield values (store.shield.applications and store.shield.applicationCategories) after applying them a reliable validation method?
What's the best practice to handle expired tokens (e.g. re-prompt the FamilyActivityPicker, or show a fallback)?
What Is the Expiration Duration of Tokens from FamilyActivityPicker?
Any guidance or insight from the Screen Time/FamilyControls team would be greatly appreciated!
Thank you!
How to use wifi-aware to connect third-party device with iPhone?
The document mention that "Your app can use the Wi-Fi Aware framework to connect with Wi-Fi Aware certified accessories", but How to be Wi-Fi Aware certified accessories?
it there any detail?
Topic:
App & System Services
SubTopic:
General
I have installed the macOS 26 WWDC beta on a secondary volume, and set it up with two user accounts (both administrators).
However, the options for switching users without fully logging out are nowhere to be found.
The topic is still included in macOS Help and is shown when searching for “fast” in System Settings, however, the option is hidden/missing in the pref pane when selected.
Filed FB18155517 (macOS 26 beta: No Fast User Switching?)
I have hosted my AASA file in https://powerbrowser.app/.well-known/apple-app-site-association in signed format as per documentation.
I still can not see open in app button when open a link by long press.
By the way i have activated 'Associated Domains' and put proper entitlements as per documantation.
Hi I'm trying to build a screen time app and the Apple docs and APIs really leave something to be desired. I want to block apps on a schedule. That's it. To do this I need my DeviceActivityMonitorExt to know which apps to block. I need to somehow pass a DeviceActivitySelection from the main app into this DeviceActivityMonitorExt. How can I do this?
How can I use the Screen Time API to set a restriction for a child account from my app running on the parent’s account?
I’m creating an app with the Screen Time API and I would like to know how to make the app show a parental control editing view for parents and a view for child accounts that shows which apps are blocked. How can I do this?
Is there any way to use the screen time API on Mac?
Hey folks!
I'm working on a macOS app which has a Finder Quick Action extension. It's all working fine, but I'm hitting a weird struggle with getting the icon rendering how I would like, and the docs haven't been able to help me.
I want to re-use a custom SF Symbol from my app, so I've copied that from the main app's xcassets bundle to the one in the extension, and configured it for Template rendering.
The icon renders in the right click menu in Finder, the Finder preview pane and the Extensions section of System Settings, but all of them render with the wrong colour in dark mode. In light mode they look fine, but in dark mode I would expect a templated icon to be rendered in white, not black.
I've attached a variety of screenshots of the icons in the UI and how things are set up in Xcode (both for the symbol in the xcassets bundle, and the Info.plist)
I tried reading the docs, searching Google, searching GitHub and even asking the dreaded AI, but it seems like there's not really very much information available about doing icons for Finder extensions, especially ones using a custom SF Symbol, so I would love to know if anyone here has been able to solve this in the past!
Finder preview pane in light mode:
Finder preview pane in dark mode:
Finder quick action context menu:
System Settings extension preferences:
The custom symbol in my .xcassets bundle:
The finder extension's Info.plist:
I've made working Spotlight Import Extension with in macOS 15.5 (24F74). mdimport confirm it's installed, and working. The problem is related to accessing data inside document bundles (package directory)
class ImportExtension: CSImportExtension {
override func update(_ attributes: CSSearchableItemAttributeSet, forFileAt url: URL) throws {
// ERROR: The file "QuickSort.notepad" couldn't be opened because you don't have permission to view it.
let fileWrapper = try FileWrapper(url: url)
}
}
forFileAt url points to a bundle. In order to read the metadata the extension needs to load the bundle from url and access its content, however in the sandbox environment,t the url allows only access to the bundle directory itself in particular NSFileWrapper(url: url) fails with error "The file "name.extension" couldn't be opened because you don't have permission to view it.", and effectively prevent from providing useful metadata.
Is there a way to access the Document Bundle content in order to read the metadata for Spotlight?
My app already has UI that allows the user to show/hide a menubar icon. If the user disallows my app's icon via System Settings > Menu Bar > Allow in the menu bar, I'd like to customize my own UI to reflect that. Does macOS provide a way for me to determine the "Allow in the menu bar" state for my application?
My use case is a Repeat Timer app.
The user can configure a repeating timer, say:
8 minutes with 3 sets
So I would like to configure either 3 alarms (8mins, 16mins, 24mins) or a repeating alarm (8mins every 3 mins)
BUT...
I would like the first and second alarms to break through but only for 5 seconds for example, and then stop (so the user doesn't need to tap the screen to silence the alarm).
I don't think this is possible after reading the API docs, but am asking the question anyway.
Thanks for any advice or guidance here, and happy WWDC!
Topic:
App & System Services
SubTopic:
General