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

[Flight Reply] Reject any new Chunks not yet discovered at the time of reportGlobalError #31840

Merged
merged 1 commit into from
Dec 18, 2024

Conversation

sebmarkbage
Copy link
Collaborator

We might have already resolved models that are not pending and so are not rejected by aborting the stream. When those later get parsed they might discover new chunks which end up as pending. These should be errored since they will never be able to resolve later.

This avoids infinitely hanging the stream.

This same fix needs to be ported to ReactFlightClient that has the same issue.

Copy link

vercel bot commented Dec 18, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
react-compiler-playground ✅ Ready (Inspect) Visit Preview 💬 Add feedback Dec 18, 2024 8:39pm

@react-sizebot
Copy link

Comparing: 95465dc...3ff4282

Critical size changes

Includes critical production bundles, as well as any change greater than 2%:

Name +/- Base Current +/- gzip Base gzip Current gzip
oss-stable/react-dom/cjs/react-dom.production.js = 6.68 kB 6.68 kB = 1.83 kB 1.83 kB
oss-stable/react-dom/cjs/react-dom-client.production.js = 510.71 kB 510.71 kB = 91.29 kB 91.29 kB
oss-experimental/react-dom/cjs/react-dom.production.js = 6.69 kB 6.69 kB = 1.83 kB 1.83 kB
oss-experimental/react-dom/cjs/react-dom-client.production.js = 516.86 kB 516.86 kB = 92.24 kB 92.24 kB
facebook-www/ReactDOM-prod.classic.js = 592.42 kB 592.42 kB = 104.38 kB 104.37 kB
facebook-www/ReactDOM-prod.modern.js = 582.68 kB 582.68 kB = 102.82 kB 102.82 kB

Significant size changes

Includes any change greater than 0.2%:

Expand to show
Name +/- Base Current +/- gzip Base gzip Current gzip
oss-stable-semver/react-server-dom-parcel/cjs/react-server-dom-parcel-server.browser.production.js +0.24% 85.74 kB 85.95 kB +0.25% 17.91 kB 17.95 kB
oss-stable/react-server-dom-parcel/cjs/react-server-dom-parcel-server.browser.production.js +0.24% 85.74 kB 85.95 kB +0.25% 17.91 kB 17.95 kB
oss-stable-semver/react-server-dom-parcel/cjs/react-server-dom-parcel-server.edge.production.js +0.24% 86.10 kB 86.31 kB +0.24% 18.01 kB 18.05 kB
oss-stable/react-server-dom-parcel/cjs/react-server-dom-parcel-server.edge.production.js +0.24% 86.10 kB 86.31 kB +0.24% 18.01 kB 18.05 kB
oss-stable-semver/react-server-dom-parcel/cjs/react-server-dom-parcel-server.node.production.js +0.23% 89.24 kB 89.44 kB +0.24% 18.65 kB 18.69 kB
oss-stable/react-server-dom-parcel/cjs/react-server-dom-parcel-server.node.production.js +0.23% 89.24 kB 89.44 kB +0.24% 18.65 kB 18.69 kB
oss-stable-semver/react-server-dom-esm/cjs/react-server-dom-esm-server.node.production.js +0.23% 89.55 kB 89.76 kB +0.23% 18.69 kB 18.74 kB
oss-stable/react-server-dom-esm/cjs/react-server-dom-esm-server.node.production.js +0.23% 89.55 kB 89.76 kB +0.23% 18.69 kB 18.74 kB
oss-experimental/react-server-dom-parcel/cjs/react-server-dom-parcel-server.browser.production.js +0.23% 90.11 kB 90.32 kB +0.25% 18.60 kB 18.64 kB
oss-experimental/react-server-dom-parcel/cjs/react-server-dom-parcel-server.edge.production.js +0.23% 90.56 kB 90.76 kB +0.23% 18.72 kB 18.76 kB
oss-stable-semver/react-server-dom-turbopack/cjs/react-server-dom-turbopack-server.browser.production.js +0.22% 93.00 kB 93.21 kB +0.24% 19.06 kB 19.11 kB
oss-stable/react-server-dom-turbopack/cjs/react-server-dom-turbopack-server.browser.production.js +0.22% 93.00 kB 93.21 kB +0.24% 19.06 kB 19.11 kB
oss-stable-semver/react-server-dom-turbopack/cjs/react-server-dom-turbopack-server.edge.production.js +0.22% 93.36 kB 93.57 kB +0.25% 19.18 kB 19.22 kB
oss-stable/react-server-dom-turbopack/cjs/react-server-dom-turbopack-server.edge.production.js +0.22% 93.36 kB 93.57 kB +0.25% 19.18 kB 19.22 kB
oss-stable-semver/react-server-dom-webpack/cjs/react-server-dom-webpack-server.browser.production.js +0.22% 93.42 kB 93.62 kB +0.23% 19.17 kB 19.22 kB
oss-stable/react-server-dom-webpack/cjs/react-server-dom-webpack-server.browser.production.js +0.22% 93.42 kB 93.62 kB +0.23% 19.17 kB 19.22 kB
oss-stable-semver/react-server-dom-webpack/cjs/react-server-dom-webpack-server.edge.production.js +0.22% 93.43 kB 93.64 kB +0.23% 19.20 kB 19.24 kB
oss-stable/react-server-dom-webpack/cjs/react-server-dom-webpack-server.edge.production.js +0.22% 93.43 kB 93.64 kB +0.23% 19.20 kB 19.24 kB
oss-experimental/react-server-dom-parcel/cjs/react-server-dom-parcel-server.node.production.js +0.22% 93.56 kB 93.77 kB +0.23% 19.34 kB 19.39 kB
oss-experimental/react-server-dom-esm/cjs/react-server-dom-esm-server.node.production.js +0.22% 93.88 kB 94.08 kB +0.22% 19.39 kB 19.44 kB
oss-stable-semver/react-server-dom-webpack/cjs/react-server-dom-webpack-server.node.unbundled.production.js +0.21% 95.53 kB 95.73 kB +0.22% 19.64 kB 19.68 kB
oss-stable/react-server-dom-webpack/cjs/react-server-dom-webpack-server.node.unbundled.production.js +0.21% 95.53 kB 95.73 kB +0.22% 19.64 kB 19.68 kB
oss-stable-semver/react-server-dom-turbopack/cjs/react-server-dom-turbopack-server.node.production.js +0.21% 96.52 kB 96.73 kB +0.23% 19.85 kB 19.90 kB
oss-stable/react-server-dom-turbopack/cjs/react-server-dom-turbopack-server.node.production.js +0.21% 96.52 kB 96.73 kB +0.23% 19.85 kB 19.90 kB
oss-stable-semver/react-server-dom-webpack/cjs/react-server-dom-webpack-server.node.production.js +0.21% 96.58 kB 96.78 kB +0.23% 19.86 kB 19.91 kB
oss-stable/react-server-dom-webpack/cjs/react-server-dom-webpack-server.node.production.js +0.21% 96.58 kB 96.78 kB +0.23% 19.86 kB 19.91 kB
oss-experimental/react-server-dom-turbopack/cjs/react-server-dom-turbopack-server.browser.production.js +0.21% 97.37 kB 97.58 kB +0.22% 19.78 kB 19.82 kB
oss-experimental/react-server-dom-webpack/cjs/react-server-dom-webpack-server.browser.production.js +0.21% 97.79 kB 97.99 kB +0.22% 19.94 kB 19.98 kB
oss-experimental/react-server-dom-turbopack/cjs/react-server-dom-turbopack-server.edge.production.js +0.21% 97.82 kB 98.03 kB +0.22% 19.95 kB 20.00 kB
oss-experimental/react-server-dom-webpack/cjs/react-server-dom-webpack-server.edge.production.js +0.21% 97.89 kB 98.09 kB +0.22% 19.97 kB 20.01 kB
oss-experimental/react-server-dom-webpack/cjs/react-server-dom-webpack-server.node.unbundled.production.js +0.20% 99.85 kB 100.06 kB +0.21% 20.34 kB 20.38 kB
oss-experimental/react-server-dom-turbopack/cjs/react-server-dom-turbopack-server.node.production.js +0.20% 100.85 kB 101.05 kB +0.47% 20.56 kB 20.66 kB
oss-experimental/react-server-dom-webpack/cjs/react-server-dom-webpack-server.node.production.js +0.20% 100.90 kB 101.11 kB +0.21% 20.62 kB 20.66 kB

Generated by 🚫 dangerJS against 3a713c5

@gnoff gnoff merged commit ef979d4 into facebook:main Dec 18, 2024
187 checks passed
github-actions bot pushed a commit that referenced this pull request Dec 18, 2024
…f reportGlobalError (#31840)

We might have already resolved models that are not pending and so are
not rejected by aborting the stream. When those later get parsed they
might discover new chunks which end up as pending. These should be
errored since they will never be able to resolve later.

This avoids infinitely hanging the stream.

This same fix needs to be ported to ReactFlightClient that has the same
issue.

DiffTrain build for [ef979d4](ef979d4)
gnoff pushed a commit to gnoff/react that referenced this pull request Dec 18, 2024
…f reportGlobalError (facebook#31840)

We might have already resolved models that are not pending and so are
not rejected by aborting the stream. When those later get parsed they
might discover new chunks which end up as pending. These should be
errored since they will never be able to resolve later.

This avoids infinitely hanging the stream.

This same fix needs to be ported to ReactFlightClient that has the same
issue.
gnoff pushed a commit to gnoff/react that referenced this pull request Dec 18, 2024
…f reportGlobalError (facebook#31840)

We might have already resolved models that are not pending and so are
not rejected by aborting the stream. When those later get parsed they
might discover new chunks which end up as pending. These should be
errored since they will never be able to resolve later.

This avoids infinitely hanging the stream.

This same fix needs to be ported to ReactFlightClient that has the same
issue.
gnoff added a commit that referenced this pull request Dec 18, 2024
cherry-picks #31840 into the base version of React in latest Next.js 14
release

Co-authored-by: Sebastian Markbåge <sebastian@calyptus.eu>
gnoff pushed a commit to gnoff/react that referenced this pull request Dec 18, 2024
…f reportGlobalError (facebook#31840)

We might have already resolved models that are not pending and so are
not rejected by aborting the stream. When those later get parsed they
might discover new chunks which end up as pending. These should be
errored since they will never be able to resolve later.

This avoids infinitely hanging the stream.

This same fix needs to be ported to ReactFlightClient that has the same
issue.
gnoff added a commit that referenced this pull request Dec 18, 2024
…at the time of reportGlobalError (#31840) (#31845)

We might have already resolved models that are not pending and so are
not rejected by aborting the stream. When those later get parsed they
might discover new chunks which end up as pending. These should be
errored since they will never be able to resolve later.

This avoids infinitely hanging the stream.

This same fix needs to be ported to ReactFlightClient that has the same
issue.

Co-authored-by: Sebastian Markbåge <sebastian@calyptus.eu>
gnoff pushed a commit to gnoff/react that referenced this pull request Dec 19, 2024
…f reportGlobalError (facebook#31840)

We might have already resolved models that are not pending and so are
not rejected by aborting the stream. When those later get parsed they
might discover new chunks which end up as pending. These should be
errored since they will never be able to resolve later.

This avoids infinitely hanging the stream.

This same fix needs to be ported to ReactFlightClient that has the same
issue.
sebmarkbage added a commit to sebmarkbage/react that referenced this pull request Dec 19, 2024
sebmarkbage added a commit that referenced this pull request Dec 19, 2024
…rtGlobalError (#31851)

Same as #31840 but for the Flight Client.
ztanner added a commit to vercel/next.js that referenced this pull request Dec 19, 2024
…218 (#74117)

[diff
facebook/react@7283a213...65e06cb7](facebook/react@7283a21...65e06cb)

<details>
<summary>React upstream changes</summary>

- [Merge 4af40315c864c4467aa1a2fb61b9c05b7d180e3e into
7283a213dbbc31029e65005276f12202558558fc
facebook/react@65e06cb77](facebook/react@65e06cb)
(Josh Story)
- facebook/react#31840

</details>
github-actions bot pushed a commit to code/lib-react that referenced this pull request Dec 19, 2024
github-actions bot pushed a commit to code/lib-react that referenced this pull request Dec 19, 2024
github-actions bot pushed a commit to AreaLayer/react that referenced this pull request Dec 19, 2024
github-actions bot pushed a commit to AreaLayer/react that referenced this pull request Dec 19, 2024
gnoff pushed a commit to gnoff/react that referenced this pull request Dec 20, 2024
…f reportGlobalError (facebook#31840)

We might have already resolved models that are not pending and so are
not rejected by aborting the stream. When those later get parsed they
might discover new chunks which end up as pending. These should be
errored since they will never be able to resolve later.

This avoids infinitely hanging the stream.

This same fix needs to be ported to ReactFlightClient that has the same
issue.
gnoff added a commit that referenced this pull request Dec 20, 2024
…at the time of reportGlobalError (#31840) (#31872)

We might have already resolved models that are not pending and so are
not rejected by aborting the stream. When those later get parsed they
might discover new chunks which end up as pending. These should be
errored since they will never be able to resolve later.

This avoids infinitely hanging the stream.

This same fix needs to be ported to ReactFlightClient that has the same
issue.

Co-authored-by: Sebastian Markbåge <sebastian@calyptus.eu>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed React Core Team Opened by a member of the React Core Team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants