ReactiveX / rxdart

The Reactive Extensions for Dart
http://reactivex.io
Apache License 2.0
3.37k stars 270 forks source link

StreamSubscription pause()/resume() with PublishSubject.stream.listen not working #708

Closed ObranS closed 1 year ago

ObranS commented 1 year ago
// I have a code 
  Stream<BleScannerState> get state => _statePublishSubject.stream;

// and
 _bleScannerSubscription = _bleScanner.state.listen(...)

// but in code when I try to do
 _bleScannerSubscription?.pause();

// and later  
_bleScannerSubscription?.resume();

// I still get isPaused == true
final isPaused = _bleScannerSubscription?.isPaused;
hoc081098 commented 1 year ago

Broadcast streams/controllers do NOT support stream pausing/resuming

ObranS commented 1 year ago

Close it as @hoc081098 explained the issue