background-processing

Community

Master iOS background tasks with reliability.

AuthorderKlinke
Version1.0.0
Installs0

System Documentation

What problem does it solve?

iOS background execution is constrained and unpredictable. This Skill provides comprehensive guidance to implement, debug, and verify BGTaskScheduler tasks so they run reliably across app launches and system conditions.

Core Features & Use Cases

  • Registration and scheduling for BGAppRefreshTask, BGProcessingTask, BGContinuedProcessingTask, beginBackgroundTask, and Background URLSession.
  • Expiration handling, progressive task completion, and issues diagnosis with WWDC-backed scheduling factors.
  • Swift 6 cancellation integration to bridge expiration with cooperative cancellation in async code.

Quick Start

  1. Register a task in didFinishLaunchingWithOptions: BGTaskScheduler.shared.register(forTaskWithIdentifier: "com.yourapp.refresh", using: nil) { task in self.handleAppRefresh(task: task as! BGAppRefreshTask) }
  2. Schedule the task when the app goes to background: let request = BGAppRefreshTaskRequest(identifier: "com.yourapp.refresh") request.earliestBeginDate = Date(timeIntervalSinceNow: 15 * 60) try BGTaskScheduler.shared.submit(request)
  3. Implement the handler with an expirationHandler and completion: func handleAppRefresh(task: BGAppRefreshTask) { task.expirationHandler = { self.currentOperation?.cancel() } self.fetchLatestContent { _ in task.setTaskCompleted(success: true) } }

Dependency Matrix

Required Modules

None required

Components

Standard package

💻 Claude Code Installation

Recommended: Let Claude install automatically. Simply copy and paste the text below to Claude Code.

Please help me install this Skill:
Name: background-processing
Download link: https://github.com/derKlinke/codex-config/archive/main.zip#background-processing

Please download this .zip file, extract it, and install it in the .claude/skills/ directory.
View Source Repository

Agent Skills Search Helper

Install a tiny helper to your Agent, search and equip skill from 223,000+ vetted skills library on demand.