         }
 
         recurInputProducer(SignalProducer(inputSignal), strategy: strategy)
-            .flatMap(.merge) { fromState, input -> SignalProducer<Reply<State, Input>, NoError> in
-                if let (toState, _) = mapping(fromState, input) {
-                    return .init(value: .success(input, fromState, toState))
-                }
-                else {
-                    return .init(value: .failure(input, fromState))
-                }
-            }
+
             .startWithSignal { replySignal, disposable in
                 self._disposable = disposable
 


        /// Recursive input-producer that sends inputs from `inputSignal`
        /// and also from additional effect generated by `EffectMapping`.
        func recurInputProducer(_ inputProducer: SignalProducer<Input, NoError>, strategy: FlattenStrategy) -> SignalProducer<(State, Input), NoError>
        {
            return SignalProducer<(State, Input), NoError> { observer, disposable in
                inputProducer
                    .withLatest(from: stateProperty.producer)
                    .map { input, fromState in
                        return (input, fromState, mapping(fromState, input)?.1)
                    }
                    .startWithSignal { mappingSignal, mappingSignalDisposable in
                        //

                        // inner producers of `flatMap(strategy)` in `successSignal` don't get interrupted by mapping failure.
                        //
                        let successSignal = mappingSignal
                            .filterMap { input, fromState, mapped in
                                return mapped.map { (input, fromState, $0) }
                            }
                            .flatMap(strategy) { input, fromState, mapped -> SignalProducer<Reply<State, Input>, NoError> in
                                let (toState, effect) = mapped
                                return recurInputProducer(effect, strategy: strategy)
                                    .prefix(value: .success(input, fromState, toState))
                            }

                        let failureSignal = mappingSignal
                            .filterMap { input, fromState, effect -> Reply<State, Input>? in
                                return effect == nil ? .failure(input, fromState) : nil
                            }

                        let mergedProducer = SignalProducer(values: failureSignal, successSignal).flatten(.merge)
