-
Notifications
You must be signed in to change notification settings - Fork 3k
Closed
Labels
6.xIssues and PRs for version 6.xIssues and PRs for version 6.x7.xIssues and PRs for version 7.xIssues and PRs for version 7.xbugConfirmed bugConfirmed bug
Description
Describe the bug
exhaustAll
does not behave the same as exhaustMap(identity)
Expected behavior
I would expect that exhaustAll
should behave the same as exhaustMap(identity)
Reproduction code
import { exhaustAll, exhaustMap, firstValueFrom, lastValueFrom, of, identity } from 'rxjs'
const a = of(of(1))
const a1 = await firstValueFrom(a.pipe(exhaustMap(identity)))
assert.deepStrictEqual(a1, 1) // success
const a2 = await firstValueFrom(a.pipe(exhaustAll()))
assert.deepStrictEqual(a2, 1) // success
const a3 = await lastValueFrom(a.pipe(exhaustMap(identity)))
assert.deepStrictEqual(a3, 1) // success
const a4 = await lastValueFrom(a.pipe(exhaustAll()))
assert.deepStrictEqual(a4, 1) // timeout cause `a4` never resolves
Reproduction URL
No response
Version
7.5.5
Environment
No response
Additional context
No response
Metadata
Metadata
Assignees
Labels
6.xIssues and PRs for version 6.xIssues and PRs for version 6.x7.xIssues and PRs for version 7.xIssues and PRs for version 7.xbugConfirmed bugConfirmed bug