Skip to content

Releases: ReactiveX/rxdart

0.28.0-dev.2

30 Mar 10:26
Compare
Choose a tag to compare

Feedback on this change appreciated as this is a dev release before 0.28.0 stable!

Changed

  • Breaking: Rename ForkJoinStream.combine2..combine9 to ForkJoinStream.join2..join9.
  • Breaking: Rx.using/UsingStream
    • Convert all required positional parameters to required named parameters.
    • The disposer is now called after the future returned from StreamSubscription.cancel completes.

0.28.0-dev.1

27 Jan 06:59
6a10dc7
Compare
Choose a tag to compare
0.28.0-dev.1 Pre-release
Pre-release

https://pub.dev/packages/rxdart/versions/0.28.0-dev.1

Feedback on this change appreciated as this is a dev release before 0.28.0 stable!

Changed

  • switchMap: when cancelling the previous inner subscription,
    switchMap will pause the outer subscription and and wait for the inner subscription to be completely canceled.
    It will then resume the outer subscription, and listen to the next inner Stream.
    Any errors from canceling the previous inner subscription will now be forwarded to the resulting Stream.

Documentation

  • Replace deprecated "dart pub run" with "dart run" (thanks to @tatsuyafujisaki).

What's Changed

New Contributors

Full Changelog: 0.28.0-dev.0...0.28.0-dev.1

0.28.0-dev.0

26 Jul 06:28
18fd718
Compare
Choose a tag to compare
0.28.0-dev.0 Pre-release
Pre-release

https://pub.dev/packages/rxdart/versions/0.28.0-dev.0

Feedback on this change appreciated as this is a dev release before 0.28.0 stable!

New

  • ValueStream:

    • Add lastEventOrNull getter to ValueStream,
      which returns the last emitted event (either data/value or error event), or null.
    • Add isLastEventValue, isLastEventError and errorAndStackTraceOrNull
      extension getters to ValueStream, to check the kind of the last emitted event is data/value or error.
    • Update documentation.
  • ReplayStream:

    • Add errorAndStackTraces to ReplayStream, which returns a list of emitted ErrorAndStackTraces.
  • Rename Notification and Kind to better reflect their purpose,
    and to avoid confusion with Flutter's Notification class.

    • Rename Notification to StreamNotification
      • Notification.onData to StreamNotification.data.
      • Notification.onDone to StreamNotification.done.
      • Notification.onError to StreamNotification.error.
    • Rename Kind to NotificationKind
      • Kind.onData to NotificationKind.data.
      • Kind.onError to NotificationKind.error.
      • Kind.onDone to NotificationKind.done.
    • Introduce DataNotification, ErrorNotification and DoneNotification as the subclasses of StreamNotification.
    • Convert isOnData, isOnError, isOnDone, requireData to extension getters on StreamNotification,
      they are now named isData, isError, isDone and requireDataValue.
    • Add extensions on StreamNotification: dataValueOrNull, requireErrorAndStackTrace, errorAndStackTraceOrNull getters and when method.

Changed

  • Accept Dart SDK versions above 3.0.

Documentation


What's Changed

New Contributors

Full Changelog: 0.27.7...0.28.0-dev.0

0.27.7

16 Nov 10:04
3d1b6c0
Compare
Choose a tag to compare

https://pub.dev/packages/rxdart/versions/0.27.7

Fixed

  • Subject
    • Only call onAdd and onError if the subject is not closed.
      This ensures BehaviorSubject and ReplaySubject do not update their values after they have been closed.

    • Subject.stream now returns a read-only Stream.
      Previously, Subject.stream was identical to the Subject, so we could add events to it, for example: (subject.stream as Sink<T>).add(event).
      This behavior is now disallowed, and will throw a TypeError if attempted. Use Subject.sink/Subject itself for adding events.

    • Change return type of ReplaySubject<T>.stream to ReplayStream<T>.

    • Internal refactoring of Subject.addStream.


What's Changed

  • fix(subject): only call onAdd and onError if the subject is not closed by @hoc081098 in #698
  • refactor(subject): Subject.stream now returns a read-only Stream by @hoc081098 in #699
  • refactor(subject): addStream by @hoc081098 in #700
  • chore(publish): prepare for v0.27.7 by @hoc081098 in #701

Full Changelog: 0.27.6...0.27.7

0.27.6

11 Nov 11:43
8916c7c
Compare
Choose a tag to compare

https://pub.dev/packages/rxdart/versions/0.27.6

  • Rx.using/UsingStream: resourceFactory can now return a Future.
    This allows for asynchronous resource creation.

  • Rx.range/RangeStream: ensure RangeStream is only listened to once.


What's Changed

  • fix(range): make sure RangeStream can only be listened to once by @hoc081098 in #690
  • fix(range): ensure RangeStream is only listened to once by @hoc081098 in #694
  • refactor(Rx.using): resourceFactory can return a Future by @hoc081098 in #696
  • chore(publish): prepare for v0.27.6 by @hoc081098 in #697

Full Changelog: 0.27.5...0.27.6

0.27.5

16 Jul 11:24
e13dad0
Compare
Choose a tag to compare

https://pub.dev/packages/rxdart/versions/0.27.5

Bug fixes

  • Fix issue #683: Throws runtime type error when using extension
    methods on a Stream<R> but its type annotation is Stream<T>, R is a subtype of T
    (covariance issue with StreamTransformer).

    Stream<num> s1 = Stream<int>.fromIterable([1, 2, 3]);
    // throws "type 'SwitchMapStreamTransformer<num, num>' is not a subtype of type 'StreamTransformer<int, num>' of 'streamTransformer'"
    s1.switchMap((v) => Stream.value(v));
    
    Stream<int?> s2 = Stream<int>.fromIterable([1, 2, 3]);
    // throws "type 'SwitchMapStreamTransformer<int?, int?>' is not a subtype of type 'StreamTransformer<int, int?>' of 'streamTransformer'"
    s2.switchMap((v) => Stream.value(v));

    Extension methods were previously implemented via stream.transform(streamTransformer), now
    via streamTransformer.bind(stream) to avoid this issue.

  • Fix concatEager: activeSubscription should be changed to next subscription.

Code refactoring

  • Change return type of pairwise to Stream<List<T>>.

What's Changed

New Contributors

Full Changelog: 0.27.4...0.27.5

0.27.4

29 May 16:36
dfae6fa
Compare
Choose a tag to compare

https://pub.dev/packages/rxdart/versions/0.27.4

Bug fixes

  • withLatestFrom should iterate over Iterable<Stream>s only once when the stream is listened to.
  • Fix analyzer warnings when using Dart 2.16.0.

Features

  • Add mapNotNull/MapNotNullStreamTransformer.
  • Add whereNotNull/WhereNotNullStreamTransformer.

Documentation


What's Changed

New Contributors

Full Changelog: 0.27.3...0.27.4

0.27.3

21 Nov 06:12
b8076e6
Compare
Choose a tag to compare

https://pub.dev/packages/rxdart/versions/0.27.3

Bug fixes

  • flatMap now creates inner Streams lazily.
  • combineLatest, concat, concatEager, forkJoin, merge, race, zip iterate over Iterable<Stream>s only once
    when the stream is listened to.
  • Disallow mixing autoConnect, connect and refCount together, only one of them should be used.

Features

  • Introduce AbstractConnectableStream, base class for the ConnectableStream implementations.
  • Improve CompositeSubscription (thanks to @BreX900)
    • CompositeSubscription's dispose, clear, and remove methods now return a completion future.
    • Fixed an issue where a stream not present in CompositeSubscription was canceled.
    • Added the ability not to cancel the stream when it is removed from CompositeSubscription.
    • CompositeSubscription implements StreamSubscription.
    • CompositeSubscription.add will throw a StateError instead of a String if this composite was disposed.

Documentation

  • Fix Connectable examples.
  • Update Web example to null safety.
  • Fix Flutter example: SearchResultItem.fromJson type error (thanks to @WenYeh)

Code refactoring

  • Simplify takeLast implementation.
  • Migrate from pedantic to lints and flutter_lints.
  • Refactor BehaviorSubject, ReplaySubject implementations by using "Sentinel object"s instead of ValueWrappers.

New Contributors

Full Changelog: 0.27.2...0.27.3

0.27.2

03 Sep 21:25
5b1c702
Compare
Choose a tag to compare

https://pub.dev/packages/rxdart/versions/0.27.2

Bug fixes

  • onErrorReturnWith now does not drop the remaining data events after the first error.
  • Disallow changing handlers of ConnectableStreamSubscription.

Features

  • Add delayWhen operator.
  • Add optional parameter maxConcurrent to flatMap.
  • groupBy
    • Rename GroupByStream to GroupedStream.
    • Add optional parameter durationSelector, which used to determine how long each group should exist.
  • ignoreElements
    • Remove @deprecated annotation (ignoreElements should not be marked as deprecated).
    • Change return type to Stream<Never>.

Documentation

Code refactoring

  • Refactoring Stream Transformers, using Stream.multi internally.

0.27.1

30 May 08:14
b77ce50
Compare
Choose a tag to compare

https://pub.dev/packages/rxdart/versions/0.27.1

  • Bugfix: ForkJoinStream throws Null check operator used on a null value when using nullable-type.
  • Bugfix: delay operator
    • Pause and resume properly.
    • Cancel all timers after it has been cancelled.