notPermitted
A task scheduling error that indicates the app isn’t permitted to launch the task.
Declaration
static var notPermitted: BGTaskScheduler.Error.Code { get }Discussion
There are two causes for this error:
The app didn’t set the appropriate mode in the UIBackgroundModes array.
The task identifier of the submitted task wasn’t in the BGTaskSchedulerPermittedIdentifiers array in The Info.plist File.