swift-concurrency

Featured

Diagnose data races, convert callback-based code to async/await, implement actor isolation patterns, resolve Sendable conformance issues, and guide Swift 6 migration. Use when developers mention: (1) Swift Concurrency, async/await, actors, or tasks, (2) "use Swift Concurrency" or "modern concurrency patterns", (3) migrating to Swift 6, (4) data races or thread safety issues, (5) refactoring closures to async/await, (6) @MainActor, Sendable, or actor isolation, (7) concurrent code architecture or performance optimization, (8) concurrency-related linter warnings (SwiftLint or similar; e.g. async_without_await, Sendable/actor isolation/MainActor lint).

Code & Development 1,509 stars 93 forks Updated 3 weeks ago MIT

Install

View on GitHub

Quality Score: 91/100

Stars 20%
100
Recency 20%
90
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
50
License 10%
100
Description 5%
100

Skill Content

# Swift Concurrency ## Fast Path Before proposing a fix: 1. Analyze `Package.swift` or `.pbxproj` to determine Swift language mode, strict concurrency level, default isolation, and upcoming features. Do this always, not only for migration work. 2. Capture the exact diagnostic and offending symbol. 3. Determine the isolation boundary: `@MainActor`, custom actor, actor instance isolation, or `nonisolated`. 4. Confirm whether the code is UI-bound or intended to run off the main actor. Project settings that change concurrency behavior: | Setting | SwiftPM (`Package.swift`) | Xcode (`.pbxproj`) | |---|---|---| | Language mode | `swiftLanguageVersions` or `-swift-version` (`// swift-tools-version:` is not a reliable proxy) | Swift Language Version | | Strict concurrency | `.enableExperimentalFeature("StrictConcurrency=targeted")` | `SWIFT_STRICT_CONCURRENCY` | | Default isolation | `.defaultIsolation(MainActor.self)` | `SWIFT_DEFAULT_ACTOR_ISOLATION` | | Upcoming features | `.enableUpcomingFeature("NonisolatedNonsendingByDefault")` | `SWIFT_UPCOMING_FEATURE_*` | If any of these are unknown, ask the developer to confirm them before giving migration-sensitive guidance. Do not guess. Guardrails: - Do not recommend `@MainActor` as a blanket fix. Justify why the code is truly UI-bound. - Prefer structured concurrency over unstructured tasks. Use `Task.detached` only with a clear reason. - If recommending `@preconcurrency`, `@unchecked Sendable`, or `nonisolated(unsafe)`, require...

Details

Author
AvdLee
Repository
AvdLee/Swift-Concurrency-Agent-Skill
Created
4 months ago
Last Updated
3 weeks ago
Language
N/A
License
MIT

Similar Skills

Semantically similar based on skill content — not just same category

Web & Frontend Solid

apple-engineer-superpowers

Use when writing Swift code for Apple platforms - iOS, macOS, visionOS. Covers Swift 6 concurrency, actors, Sendable, async/await, SwiftUI, MVVM architecture, Metal GPU programming, RealityKit ECS, visionOS scenes, interpolation/animation, advanced collection types, property wrappers, Combine bridging, error handling, testing, and API design patterns.

23 Updated 2 months ago
piemonte
AI & Automation Solid

swift-

专为 iOS/macOS 现代开发打造的代码分析规范。全面剖析 SwiftUI 响应式模式、ARC 强引用循环破除、以及 Swift 5.5+ 下基于 Actor 与 async/await 的全新并发架构。

40 Updated today
microwind
Testing & QA Solid

swift-testing-expert

Expert guidance for Swift Testing: test structure, #expect/#require macros, traits and tags, parameterized tests, test plans, parallel execution, async waiting patterns, and XCTest migration. Use when writing new Swift tests, modernizing XCTest suites, debugging flaky tests, or improving test quality and maintainability in Apple-platform or Swift server projects.

392 Updated 1 months ago
AvdLee
API & Backend Featured

stellar-ios-sdk

Build Stellar blockchain applications in Swift using stellar-ios-mac-sdk. Use when generating Swift code for transaction building, signing, Horizon API queries, Soroban RPC, smart contract deployment and invocation, XDR encoding/decoding, and SEP protocol integration. Covers 26+ operations, 50 Horizon endpoints, 12 RPC methods, and 17 SEP implementations with Swift async/await and callback-based streaming patterns. Full Swift 6 strict concurrency support (all types Sendable).

129 Updated today
Soneso
Data & Documents Solid

pokeswift-extractor-contract-change

Investigate, implement, and validate PokeSwift extraction or shared-contract changes without breaking the source-driven pipeline. Use when work touches `PokeExtractCLI`, `PokeDataModel`, `PokeContent`, generated `Content/Red` artifacts, or any bug where the issue may be in extracted data, schema shape, content loading, or extractor-to-runtime contract drift.

348 Updated 2 months ago
Dimillian