Repository navigation
https://pub.dev/packages/dart_either/versions/2.4.0
Either operations
-
Relocated
flatMap,getOrElse,getOrHandle,handleError,
andhandleErrorWithfromEitherinstance members to exported generic extensions.- Statically typed dot-call syntax and behavior are unchanged,
while analyzer-valid widened receivers no longer fail at a covariant virtual
method boundary. - Selective imports must include the relevant extension type,
anddynamicreceivers no longer dispatch to these operations.
- Statically typed dot-call syntax and behavior are unchanged,
-
Split every value-operation extension exported by
either_extensions.dart
into a method-named source file. This file split changes only the source
layout; public exports, call syntax, and behavior remain unchanged, so no
consumer migration is required for the split.
Either.parSequenceN and Either.parTraverseN
-
Fixed
Either.parSequenceNandEither.parTraverseNwith finite concurrency
so functions still waiting for a permit are not invoked after the first
observedLeft, thrown error, or failed future.- A
Leftis returned when it is observed first;
an ordinary error observed first is propagated with its stack trace. - Already-running functions remain non-cancellable and may finish their side effects.
- A
-
A non-null
maxConcurrentless than or equal to zero now throws an
ArgumentErrorsynchronously, before inputs are traversed, the
parTraverseNmapper is called, or callbacks are invoked. -
Errors thrown while iterating the input or invoking the
parTraverseN
mapper now propagate synchronously instead of completing the returned future
with an error. No asynchronous operation callback is invoked if this input
preparation fails.
What's Changed
Full Changelog: 2.3.0...2.4.0