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

defer/stream: fix flattenAsyncIterable concurrency #3710

Conversation

glasser
Copy link
Contributor

@glasser glasser commented Aug 19, 2022

Fixes the bug demonstrated in #3709 (which has already been incorporated
into the defer-stream branch).

This fix is extracted from #3703, which also updates the typing and API
around execute. This particular change doesn't affect the API (other
than making the subscribe return type more honest, as its returned
generator could yield AsyncExecutionResult before this change as well).

@github-actions
Copy link

Hi @glasser, I'm @github-actions bot happy to help you with this PR 👋

Supported commands

Please post this commands in separate comments and only one per comment:

  • @github-actions run-benchmark - Run benchmark comparing base and merge commits for this PR
  • @github-actions publish-pr-on-npm - Build package from this PR and publish it on NPM

@glasser glasser force-pushed the glasser/defer-stream-fix-flattenAsyncIteratable branch from af7e0a7 to 10a3b3e Compare August 19, 2022 21:43
@@ -143,15 +120,20 @@ describe('flattenAsyncIterable', () => {
expect(caughtError).to.equal('ouch');
});
/* c8 ignore start */
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you remove the c8 ignore wrapping this test?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

Fixes the bug demonstrated in graphql#3709 (which has already been incorporated
into the defer-stream branch).

This fix is extracted from graphql#3703, which also updates the typing and API
around execute.

This particular change doesn't affect the API, other than making the
`subscribe` return type more honest, as its returned generator could
yield AsyncExecutionResult before this change as well. (The reason the
previous version built is because every ExecutionResult is actually an
AsyncExecutionResult; fixing that fact is part of what graphql#3703 does.)
@glasser glasser force-pushed the glasser/defer-stream-fix-flattenAsyncIteratable branch from 10a3b3e to b3d4058 Compare August 19, 2022 23:06
@robrichard robrichard merged commit 4177920 into graphql:defer-stream Aug 20, 2022
robrichard pushed a commit that referenced this pull request Aug 23, 2022
Fixes the bug demonstrated in #3709 (which has already been incorporated
into the defer-stream branch).

This fix is extracted from #3703, which also updates the typing and API
around execute.

This particular change doesn't affect the API, other than making the
`subscribe` return type more honest, as its returned generator could
yield AsyncExecutionResult before this change as well. (The reason the
previous version built is because every ExecutionResult is actually an
AsyncExecutionResult; fixing that fact is part of what #3703 does.)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants