#MainActor
Quick #swift question:

MainActor object has an async function. Function is called from MainActor SwiftUI View in Task.immediate and the function doesn't encounter any await (it checks a guard statement and returns). Is this functionally equivalent to a simple non-async function?
October 27, 2026 at 12:33 PM
This is very very cool, thank you! May I request the option to prefix structs with nonisolated for those of use who, for some reason, enabled default MainActor?
October 27, 2026 at 10:52 PM
A benefit of defining your app’s business logic using “Nonisolated Core, Isolated Shell” is that you can take advantage of Swift Testing’s parallelization in ways you can’t when all your code is isolated to the MainActor. This can lead to a test suite that runs 10⨉ faster!
October 15, 2026 at 6:37 PM
This week we started reaping the benefits of "nonisolated core, isolated shell". We write features a single time, without thinking about isolation, then wrap the feature in the isolation we need. @‌MainActor for SwiftUI, arbitrary actor for tests!

www.pointfree.co/collections/...
October 14, 2026 at 2:19 PM
Is #swiftui Observable broken in Xcode 27.0?

I've this (simplified)

struct State: Equatable {
var unsavedChanges = false
// ...
}

(at)Observable
(at)dynamicMemberLookup
(at)MainActor
public final class Store {
private(set) public var state: State
// ...
}

An instance […]
Original post on sfba.social
sfba.social
October 6, 2026 at 9:31 PM
I was recently inspired to take another look at something that has caused lots of problems: marking just a method MainActor vs the whole type.
Revisiting "Split Isolation"
The pattern was so common and so problematic I gave it a name. But, does is it actually bad?
www.massicotte.org
October 5, 2026 at 2:22 PM
Me, in a patronizing tone: you are too afraid of running stuff on the main thread

Also me: I should keep working on a years-long project to make it easier to avoid using MainActor in this one incredibly esoteric case
October 5, 2026 at 11:07 AM
The MainActor is TomCruise FYI.
October 5, 2026 at 11:10 AM
⚡ 𝑆𝑤𝑖𝑓𝑡 6 𝐺𝑎𝑣𝑒 𝑀𝑒 𝑍𝑒𝑟𝑜 𝑊𝑎𝑟𝑛𝑖𝑛𝑔𝑠, 𝑏𝑢𝑡 𝑇𝑤𝑜 𝑂𝑏𝑗𝑒𝑐𝑡𝑖𝑣𝑒-𝐶 𝐶𝑎𝑙𝑙𝑏𝑎𝑐𝑘𝑠 𝑆𝑡𝑖𝑙𝑙 𝐶𝑟𝑎𝑠ℎ𝑒𝑑 𝑎𝑡 𝑅𝑢𝑛𝑡𝑖𝑚𝑒 by Amana

Swift 6 strict concurrency can still leave a nasty hole when Objective-C APIs take…

#iOSDev #Concurrency #Testing

hackernoon.com/swift-6-gave...
Swift 6 Gave Me Zero Warnings, but Two Objective-C Callbacks Still Crashed at Runtime
Swift 6 strict concurrency can still leave a nasty hole when Objective-C APIs take plain callback blocks and run them on queues the Swift type system cannot see. The crashes here come from `BGTaskScheduler` and PhotoKit callbacks created inside `@MainActor` code, then invoked off the main actor before the `Task { @MainActor in ... }` body even gets a chance to run. That is the kind of bug that looks “obviously handled” in review, which is why the concrete grep targets and testing advice are useful. If our apps bridge into older Apple frameworks — and of course they do — this is worth reading with crash logs open.
hackernoon.com
September 28, 2026 at 6:00 AM
Xcodeに怒られないためだけにFixをぽちぽちとSendableや@MainActorをつけていたのですが、データ競合をどうすると防げるのかがわかりやすく勉強になりました

クイズ形式でダメなパターンの理解が深まり、これからはXcodeに怒られなくて済みそうです

ありがとうございました🙇‍♀️
September 25, 2026 at 12:14 PM
突然ですが久々に明日の夜にSwiftConcurrencyの解説をDiscordでやります
どこも登壇させてくれそうにないから自分でやるスタイル!
20時から!

ios-torikoboshi.connpass.com/event/407847/
みんなのもやもやを吹き飛ばす Swift Concurrency (2026/09/25 20:00〜)
# みんなのもやもやを吹き飛ばす Swift Concurrency 「async/await は書けるけど、Sendable のエラーがよく分からない」 「actor と MainActor の違いをうまく説明できない」 「とりあえず @MainActor を付けたらビルドが通った……」 そんなもやもやを、図を使いながらほどいていく勉強会です。 ## この勉強会で話すこと Swift C...
ios-torikoboshi.connpass.com
September 24, 2026 at 1:55 PM
Background task registration closure inferred as MainActor-isolated caused a pre-execution main-actor check failure, triggering EXC_BREAKPOINT crashes in background.
Save What Matters
Curate Feeds | Make Collections | Customize Email Briefs
briefly.co
September 22, 2026 at 4:18 PM
Background task registration closure inferred as MainActor-isolated caused a pre-execution main-actor check failure, triggering EXC_BREAKPOINT crashes in background.
Save What Matters
Curate Feeds | Make Collections | Customize Email Briefs
briefly.co
September 22, 2026 at 4:15 PM
Just Apple SDK things...
```swift
@MainActor
@Observable
final class ATProtoOAuthService: NSObject, ASWebAuthenticationPresentationContextProviding {
```
September 12, 2026 at 3:25 AM
One thing I really don't enjoy is how inference of MainActor isolation from the type is applied to methods.

Yes I save typing the MainActor attribute.

But I need to look at the quick help to know what a method in an extension in another file is doing all the time.
August 22, 2026 at 6:19 AM
Doing so, even though the function is @MainActor, URLSession.shared.data(from:) inside addTask is fine. Child tasks in a TaskGroup don’t inherit the actor context so the network calls run off the main actor automatically. I will update the post in the day-light. It’s 02:45am here in Turkey😂
May 7, 2026 at 11:47 PM
It’s an honor for me to hear this from you, Matt! Since textLabel is a UI element, the cleaner approach is to mark the function itself @MainActor rather than using MainActor.run or the corresponding class.
May 7, 2026 at 11:47 PM
„Note: This class performs network operations and should NOT be @MainActor isolated to avoid blocking the UI thread. Network calls run on background threads.“ does this advice make sense? The network calls are all non-blocking, aren’t they?
November 30, 2025 at 10:37 AM
Did you ever solve this? The only thing I could come up with was to use the biggest hammer and add MainActor to the Speaker class.
January 17, 2025 at 1:53 AM
This Swift 6 code crashes in _dispatch_assert_queue_fail(), even if the installTap() closure is empty. If I remove the MainActor annotation on the class, it works. Anybody else seen and/or worked around this?

#swift #concurrency #AVFoundation
February 27, 2025 at 3:22 PM
Discover how Swift 6's MainActor isolation impacts XCTest, with tips on handling concurrency warnings for view controller testing. https://qualitycoding.org/xctest-mainactor/
XCTest Meets @MainActor: How to Fix Strict Concurrency Warnings
Discover how Swift 6's @MainActor isolation impacts XCTest, with tips on handling concurrency warnings for view controller testing.
qualitycoding.org
July 8, 2026 at 5:58 PM
Are you struggling to fix Swift strict concurrency warnings with XCTest-based tests? I was! https://qualitycoding.org/xctest-mainactor/
December 9, 2024 at 9:07 PM