Releases: pointfreeco/swift-composable-architecture
0.43.0
What's Changed
- Requirement Change: Swift 5.6 is now required as of the release of the
ReducerProtocol(#1491); we'd love to support Swift 5.5 still, but need help from the community: #1494. - Deprecation/Rename: The
Reducertype alias is now hard-deprecated to be renamed toAnyReducerto help call out reducers that should be migrated (#1478). TheReducerProtocolwill be renamed toReducerin the future and this hard deprecation makes room for it. - Deprecation/Rename: The
Effecttype has been renamed to a soft-deprecatedEffectPublishertype, both generic overActionandFailure, while a temporaryEffectTasktype alias has been introduced as a replacement that is only generic overAction(#1471). This rename is in preparation for breaking changes in a forthcoming 1.0 release, where theEffectTaskwill becomeEffect, and will only be generic overAction. - Change: Some interfaces that previously required escaping closures no longer require them (#1493; thanks @tgrapperon , #1513).
- Bug fix:
ReducerProtocol.transformDependencyis now properly fused with upstream calls toReducerProtocol.dependencyandReducerProtocol.transformDependency(#1495). - Bug fix:
ViewStore.yield(while:)is now performed on the main actor (#1517). - Infrastructure: Documentation fixes (thanks @luoxiu, #1470; @qmoya, #1473; @Jager-yoo, #1475, #1490; @gohanlon, #1482; @GREENOVER, #1483; @yimajo, #1484, #1485; @roeybiran, #1479; @tgrapperon, #1509; @ts, #1504; @sillygoose, #1507; #1523); demo fixes (thanks @tgrapperon, #1492; @Jager-yoo, #1503); new benchmark for view stores (#1518).
New Contributors
- @luoxiu made their first contribution in #1470
- @qmoya made their first contribution in #1473
- @gohanlon made their first contribution in #1482
- @GREENOVER made their first contribution in #1483
- @roeybiran made their first contribution in #1479
- @ts made their first contribution in #1504
- @sillygoose made their first contribution in #1507
Full Changelog: 0.42.0...0.43.0
0.42.0
- Added:
ViewStore.init(_:observe:)has been added, to make observable view state explicit and help avoid accidentally observing too much state, which can commonly lead to performance issues (#1448). - Added: The
Dependencieslibrary can now be built on Linux (#1466). - Fixed: Chaining onto a generic reducer in a builder context with
ifLet,ifCaseLet, orforEachshould no longer lead to incorrect deprecation warnings in Swift 5.7 (#1467). - Fixed:
ReducerProtocol._printChanges(_:)is now compatible with passing static members (like.customDumpand.actionLabels) directly (#1469). - Infrastructure: Online documentation is now generated using swift-docc-plugin (#1463).
- Infrastructure: Documentation fixes (thanks @Berhtulf, via #1468).
New Contributors
Full Changelog: 0.41.2...0.41.3
0.41.2
- Fixed: Xcode's SPM integration does not allow for unsafe build flags to be configured, even when empty, for version-based releases. We've removed the empty build flag settings to fix this.
0.41.0
What's Changed
- Update example to set badge to the unread count by @hyperspacemark in #1391
- Fix the CaseStudies (UIKit) by @Czajnikowski in #1392
- Fix warnings introduced in Xcode 14.1 by @stephencelis in #1388
- Clean up the recursive case study. by @mbrandonw in #1403
- Todos demo: fix sorting filtered todos by @stephencelis in #1404
- Fix task cancellation leak by @mbrandonw in #1418
- Check in
Package.resolvedby @stephencelis in #1427 - Fix Performance.md brackets by @ddanilyuk in #1446
- ReducerProtocol by @mbrandonw in #1283
New Contributors
- @hyperspacemark made their first contribution in #1391
- @Czajnikowski made their first contribution in #1392
- @ddanilyuk made their first contribution in #1446
Full Changelog: 0.40.2...0.41.0
0.40.2
What's Changed
- Fixed: Re-entrant actions from store publisher subscriptions no longer run with the previous state (thanks @diederich, #1360).
- Fixed: The test store is now slightly more forgiving when it comes to Swift's async runtime. If you are having issues with async effects and the test store, let us know and we'll do our best to accommodate!
- Fixed: The SPM package no longer publicly vends its internal schemes.
0.40.1
- Fixed: Removed the
@StateObjectshim added in 0.40.0 to avoid a release build regression in some applications. We'll investigate on bringing it back in the future!
0.40.0
This release brings many performance improvements to the library. See our blog post for information about those changes.
- Added:
WithViewStore(_:observe:…), a new initializer that makes state observation explicit. We hope these initializers will help users avoid performance pitfalls and identify areas of their application where performance can be improved. The existing initializers have been soft-deprecated and will surface warnings in a future release. - Performance:
Effectperformance has been improved, especially with regard to merging effects (a common operation that occurs when reducers are combined), and async effects (which previously often incurred overhead from Combine). - Performance:
Store.scopeperformance has been improved for nested scopes, which no longer incur a penalty for each layer of scoping (thanks @iampatbrown). - Performance:
WithViewStorenow uses a state object under the hood, which should tie the lifecycle of a view store to a view (thanks @tgrapperon). - Performance:
ForEachStoreperformance has been improved for state updates in which element state has changed but no elements were added, removed, or moved (thanks @tgrapperon). - Fix:
Effect.run'sSendclosure is now explicitly@MainActor. - Fix: Long-living effects no longer accumulate
Taskvalues in memory for each action sent back into the store, saving memory over time. - Fix: macOS 11 compilation with the Xcode 14 release candidate.
- Fix: Actions that re-enter the store at the end of processing are now processed immediately.
- Infrastructure: README fixes (thanks @Jager-yoo).
- Infrastructure: Added benchmarks for effects, store scoping.
- Infrastructure: Fixed Todos demo's incrementing UUID helper (thanks @pitt500).
- Infrastructure: Fixed Voice Memos AV settings (thanks @entaku0818).
0.39.1
-
Fixed: Pinned Combine Schedulers to 0.7.3, which removes an errant
@_exported import Foundation.Note: This update addresses a breaking change introduced to Combine Schedulers (see the release notes for more). As a consequence, you may need to add explicit
import Foundations to your code base after updating to this version. -
Changed: Updated
Global/Localgenerics to more relativeParent/Child, or more domain-specific names. -
Infrastructure: Added Spanish language translation of the README (thanks @pitt500).
-
Infrastructure: README and documentation improvements (thanks @ole, @SevioCorrea, @kalupas226)
-
Infrastructure: Demo cleanup.
-
Infrastructure: Made test classes
final(thanks @Jager-yoo).
0.39.0
-
Added: This release includes many new tools to better support Swift concurrency. See this discussion and this pull request for more information.
Note: Many of the old Combine-centric interfaces have been soft-deprecated. Prefer using
Effect.task,Effect.run, andEffect.fireAndForgetas described in the documentation. -
Infrastructure: README, documentation, and demo app fixes (thanks @filblue, @Jager-yoo, @konomae, @yimajo).
0.38.3
-
Deprecated:
Store.uncheckedhas been deprecated. As the Composable Architecture migrates to modern Swift concurrency tools, its async endpoints must run on a consistent actor to ensure safety from data races. Because the primary use case of the Composable Architecture is driving UIs, we have chosen the@MainActorfor these endpoints, which makes them unsafe to call from unchecked stores. We believe the number of unchecked stores out in the wild is small, but in the meantime are soliciting feedback from the community with this deprecation warning.See #1206 for more information and migration paths.