🚀 I just released Swift Streamable Actors v1.0!
If you’ve ever wanted to observe changes to a Swift Actor's state as an AsyncStream without writing 30 lines of boilerplate for every property, this macro is for you.
Key highlights: ✅ 100% Type-safe (no type-erasure/AnyKeyPath) ✅ Memory safe (static factories avoid strong reference cycles) ✅ Clean API: @Streamable does it all.
Check out the code: https://github.com/malhal/swift-streamable-actors
Looked at code using Swift Concurrency:
Immediately found a bug:
state = .working(progress: 0)
await doSomething() { percent in
state = .working(progress: percent)
}
state = .done
What’s the value of `state` now?
(“Surely `.done`” is the wrong answer)
Fucking Approachable Swift Concurrency
https://fuckingapproachableswiftconcurrency.com/en/
#HackerNews #FuckingApproachableSwiftConcurrency #SwiftConcurrency #Programming #DeveloperCommunity #TechNews
What do robot toddlers and coloring pages teach us about data races? First in a series building concrete mental models for Swift Concurrency. Feedback welcome!
https://krishna.github.io/posts/understanding-data-races-visual-guide/
Notifications crashing with concurrency errors? Replace unsafe 𝑛𝑜𝑡𝑖𝑓𝑦() calls with 𝘔𝘢𝘪𝘯𝘈𝘤𝘵𝘰𝘳𝘔𝘦𝘴𝘴𝘢𝘨𝘦 and 𝘈𝘴𝘺𝘯𝘤𝘔𝘦𝘴𝘴𝘢𝘨𝘦. Thread-safe, modern, and built for async/await.
🔗 https://www.avanderlee.com/concurrency/mainactormessage-asyncmessage-concurrency-safe-notifications/ by Antoine van der Lee (@swiftlee)
Struggling with protocol conformance across actor isolation boundaries? Swift 6.2 introduces isolated conformances and protocol isolation features that can be tricky to navigate. This step-by-step breakdown helps you understand when and how to use these patterns correctly, making your concurrent code safer and more maintainable.
🔗: https://www.massicotte.org/step-by-step-conforming-to-protocols by Matt Massicotte (@mattiem)
If there’s one topic that I find intimidating, it’s protocols. They are very powerful and in extremely wide use. But I’m sitting here, trying to figure out how to lead into this discussion and I’m already getting overwhelmed. That’s because protocols can be incredibly complicated.
Are your singletons causing concurrency headaches in Swift 6? A breakdown of thread-safety challenges and practical patterns for making singletons work with modern Swift Concurrency.
🔗: https://www.massicotte.org/singletons by Matt Massicotte (@mattiem)
I see singletons used a lot in Swift projects. These things are, by definition, global state. That means they can be accessed from any context - any thread or actor - at any time. And this property makes them a common source of problems when used with Concurrency.
Want to adopt new Swift features without breaking your code? Swift's migration tooling is essential for safe, gradual transitions. Learn how to leverage it for upcoming Swift features.
🔗: https://www.avanderlee.com/concurrency/swift-migration-tooling-upcoming-swift-features/ by Antoine van der Lee (@swiftlee)