From 2a3729e3bb900e022230f9efc283665c702f2965 Mon Sep 17 00:00:00 2001 From: Luke Redpath Date: Tue, 1 Apr 2025 11:32:51 +0100 Subject: [PATCH 1/3] fix: Enable binding workaround in release builds --- Sources/ComposableArchitecture/Core.swift | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/Sources/ComposableArchitecture/Core.swift b/Sources/ComposableArchitecture/Core.swift index 0ba6e99d76f8..e4fe86deb4b1 100644 --- a/Sources/ComposableArchitecture/Core.swift +++ b/Sources/ComposableArchitecture/Core.swift @@ -268,11 +268,9 @@ final class IfLetCore: Core { @inlinable @inline(__always) func send(_ action: Action) -> Task? { - #if DEBUG - if BindingLocal.isActive && isInvalid { - return nil - } - #endif + if BindingLocal.isActive && isInvalid { + return nil + } return base.send(actionKeyPath(action)) } @inlinable From f2f54ef34a58047cdd9e5e6cd238d5732715638d Mon Sep 17 00:00:00 2001 From: Stephen Celis Date: Tue, 1 Apr 2025 15:32:08 -0700 Subject: [PATCH 2/3] Address flaky test --- Tests/ComposableArchitectureTests/EffectRunTests.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Tests/ComposableArchitectureTests/EffectRunTests.swift b/Tests/ComposableArchitectureTests/EffectRunTests.swift index cd1595e1bce9..ae61f10dd7e1 100644 --- a/Tests/ComposableArchitectureTests/EffectRunTests.swift +++ b/Tests/ComposableArchitectureTests/EffectRunTests.swift @@ -166,6 +166,6 @@ final class EffectRunTests: BaseTCATestCase { await store.send(.tap).finish() await queue.advance(by: .seconds(1)) - try await Task.sleep(nanoseconds: 100_000_000) + try await Task.sleep(nanoseconds: 1_000_000_000) } } From 39855d4202f55a6c8865ca58ecd3744cd75d045b Mon Sep 17 00:00:00 2001 From: Stephen Celis Date: Tue, 1 Apr 2025 16:24:16 -0700 Subject: [PATCH 3/3] Make flakey tests easier to troubleshoot --- .github/workflows/ci.yml | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ff460ca721a3..ecffae62a713 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -132,21 +132,21 @@ jobs: - name: Update mtime for incremental builds uses: chetan/git-restore-mtime-action@v2 - name: CaseStudies (SwiftUI) - run: make DERIVED_DATA_PATH=~/.derivedData SCHEME="CaseStudies (SwiftUI)" xcodebuild + run: make DERIVED_DATA_PATH=~/.derivedData SCHEME="CaseStudies (SwiftUI)" xcodebuild-raw - name: CaseStudies (UIKit) - run: make DERIVED_DATA_PATH=~/.derivedData SCHEME="CaseStudies (UIKit)" xcodebuild + run: make DERIVED_DATA_PATH=~/.derivedData SCHEME="CaseStudies (UIKit)" xcodebuild-raw - name: Search - run: make DERIVED_DATA_PATH=~/.derivedData SCHEME="Search" xcodebuild + run: make DERIVED_DATA_PATH=~/.derivedData SCHEME="Search" xcodebuild-raw - name: SyncUps - run: make DERIVED_DATA_PATH=~/.derivedData SCHEME="SyncUps" xcodebuild + run: make DERIVED_DATA_PATH=~/.derivedData SCHEME="SyncUps" xcodebuild-raw - name: SpeechRecognition - run: make DERIVED_DATA_PATH=~/.derivedData SCHEME="SpeechRecognition" xcodebuild + run: make DERIVED_DATA_PATH=~/.derivedData SCHEME="SpeechRecognition" xcodebuild-raw - name: TicTacToe - run: make DERIVED_DATA_PATH=~/.derivedData SCHEME="TicTacToe" xcodebuild + run: make DERIVED_DATA_PATH=~/.derivedData SCHEME="TicTacToe" xcodebuild-raw - name: Todos - run: make DERIVED_DATA_PATH=~/.derivedData SCHEME="Todos" xcodebuild + run: make DERIVED_DATA_PATH=~/.derivedData SCHEME="Todos" xcodebuild-raw - name: VoiceMemos - run: make DERIVED_DATA_PATH=~/.derivedData SCHEME="VoiceMemos" xcodebuild + run: make DERIVED_DATA_PATH=~/.derivedData SCHEME="VoiceMemos" xcodebuild-raw check-macro-compatibility: name: Check Macro Compatibility