Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(mergeMap): fix nested mergeMaps #4072

Merged
merged 4 commits into from
Aug 31, 2018
Merged

Conversation

cartant
Copy link
Collaborator

@cartant cartant commented Aug 31, 2018

Description:

This PR should fix the nested concatMap/mergeMap regression. The problem seems to have been related to a subscriber being added to itself as a parent.

Related issue (if exists): #4071

@filipesilva
Copy link
Contributor

The Appveyor CI is failing on the new test:


  1) mergeMap
       should support nested merges:
      Uncaught AssertionError: expected [] to deeply equal [ 3, 'done' ]
      + expected - actual
      -[]
      +[
      +  3
      +  "done"
      +]
      
      at Proxy.assertEqual (node_modules\chai\lib\chai\core\assertions.js:1020:19)
      at Proxy.methodWrapper (node_modules\chai\lib\chai\utils\addMethod.js:57:25)
      at Timeout._onTimeout (spec\operators\mergeMap-spec.ts:737:31)

Odd it didn't fail on other platforms. Might be a race condition.

@cartant
Copy link
Collaborator Author

cartant commented Aug 31, 2018

Might be a race condition.

Most likely. I've changed that test to use the micro task scheduler, so the setTimeout should always happen last, now.

@benlesh
Copy link
Member

benlesh commented Aug 31, 2018

Thanks @cartant! You saved me some work this morning for sure. That was first on my agenda today. <3

@benlesh benlesh merged commit 0ab701b into ReactiveX:master Aug 31, 2018
@lock lock bot locked as resolved and limited conversation to collaborators Sep 30, 2018
@cartant cartant deleted the issue-4071 branch September 24, 2020 07:07
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants