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] Enable owner stacks on the client when replaying logs #30473

Merged
merged 1 commit into from
Jul 31, 2024

Conversation

sebmarkbage
Copy link
Collaborator

@sebmarkbage sebmarkbage commented Jul 25, 2024

There's a special case that happens when we replay logs on the client because this doesn't happen within the context of any particular rendered component. So we need to reimplement things that would normally be handled by a full client like Fiber.

The implementation of getOwnerStackByComponentInfoInDev is the simplest version since it doesn't have any client components in it so I move it to shared/. It's only used by Flight but both react-server/ and react-client/ packages. The ReactComponentInfo type is also more generic than just Flight anyway.

In a follow up I still need to implement this in React DevTools when native tasks are not available so that it appends it to the console.

@sebmarkbage sebmarkbage requested a review from eps1lon July 25, 2024 22:45
Copy link

vercel bot commented Jul 25, 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 Jul 25, 2024 10:57pm

@facebook-github-bot facebook-github-bot added CLA Signed React Core Team Opened by a member of the React Core Team labels Jul 25, 2024
@react-sizebot
Copy link

react-sizebot commented Jul 25, 2024

Comparing: 7f217d1...ca3f835

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.82 kB 1.82 kB
oss-stable/react-dom/cjs/react-dom-client.production.js = 501.46 kB 501.46 kB = 89.98 kB 89.98 kB
oss-experimental/react-dom/cjs/react-dom.production.js = 6.69 kB 6.69 kB +0.05% 1.83 kB 1.83 kB
oss-experimental/react-dom/cjs/react-dom-client.production.js = 506.28 kB 506.28 kB = 90.68 kB 90.68 kB
facebook-www/ReactDOM-prod.classic.js = 598.90 kB 598.90 kB = 105.77 kB 105.77 kB
facebook-www/ReactDOM-prod.modern.js = 575.01 kB 575.01 kB = 102.01 kB 102.01 kB
oss-experimental/react-server-dom-esm/cjs/react-server-dom-esm-client.browser.development.js +3.93% 79.88 kB 83.01 kB +4.62% 15.00 kB 15.69 kB
oss-experimental/react-server-dom-esm/esm/react-server-dom-esm-client.browser.development.js +3.72% 112.71 kB 116.90 kB +5.43% 25.33 kB 26.71 kB
oss-experimental/react-server-dom-turbopack/cjs/react-server-dom-turbopack-client.browser.development.js +3.70% 81.84 kB 84.87 kB +4.44% 15.41 kB 16.10 kB
oss-experimental/react-server-dom-webpack/cjs/react-server-dom-webpack-client.browser.development.js +3.68% 82.30 kB 85.32 kB +4.41% 15.52 kB 16.21 kB
oss-experimental/react-server-dom-esm/cjs/react-server-dom-esm-client.node.development.js +3.56% 84.93 kB 87.95 kB +4.40% 16.05 kB 16.76 kB
oss-experimental/react-server-dom-turbopack/cjs/react-server-dom-turbopack-client.node.unbundled.development.js +3.51% 86.34 kB 89.37 kB +4.29% 16.37 kB 17.07 kB
oss-experimental/react-client/cjs/react-client-flight.development.js +3.50% 83.49 kB 86.42 kB +4.93% 15.28 kB 16.04 kB
oss-experimental/react-server-dom-turbopack/cjs/react-server-dom-turbopack-client.node.development.js +3.47% 87.15 kB 90.18 kB +4.25% 16.53 kB 17.24 kB
oss-experimental/react-server-dom-webpack/cjs/react-server-dom-webpack-client.edge.development.js +3.42% 88.52 kB 91.54 kB +4.12% 16.79 kB 17.48 kB
oss-experimental/react-server-dom-turbopack/cjs/react-server-dom-turbopack-client.edge.development.js +3.42% 88.53 kB 91.56 kB +4.12% 16.77 kB 17.47 kB
oss-experimental/react-server-dom-webpack/cjs/react-server-dom-webpack-client.node.unbundled.development.js +3.34% 90.33 kB 93.35 kB +4.08% 16.89 kB 17.58 kB
oss-experimental/react-server-dom-webpack/cjs/react-server-dom-webpack-client.node.development.js +3.31% 91.13 kB 94.14 kB +4.05% 17.06 kB 17.76 kB
oss-stable-rc/react-server-dom-esm/esm/react-server-dom-esm-client.browser.development.js +2.30% 104.77 kB 107.18 kB +3.02% 23.55 kB 24.26 kB
oss-stable-semver/react-server-dom-esm/esm/react-server-dom-esm-client.browser.development.js +2.30% 104.77 kB 107.18 kB +3.02% 23.55 kB 24.26 kB
oss-stable/react-server-dom-esm/esm/react-server-dom-esm-client.browser.development.js +2.30% 104.77 kB 107.18 kB +3.02% 23.55 kB 24.26 kB

Significant size changes

Includes any change greater than 0.2%:

Expand to show
Name +/- Base Current +/- gzip Base gzip Current gzip
oss-experimental/react-server-dom-esm/cjs/react-server-dom-esm-client.browser.development.js +3.93% 79.88 kB 83.01 kB +4.62% 15.00 kB 15.69 kB
oss-experimental/react-server-dom-esm/esm/react-server-dom-esm-client.browser.development.js +3.72% 112.71 kB 116.90 kB +5.43% 25.33 kB 26.71 kB
oss-experimental/react-server-dom-turbopack/cjs/react-server-dom-turbopack-client.browser.development.js +3.70% 81.84 kB 84.87 kB +4.44% 15.41 kB 16.10 kB
oss-experimental/react-server-dom-webpack/cjs/react-server-dom-webpack-client.browser.development.js +3.68% 82.30 kB 85.32 kB +4.41% 15.52 kB 16.21 kB
oss-experimental/react-server-dom-esm/cjs/react-server-dom-esm-client.node.development.js +3.56% 84.93 kB 87.95 kB +4.40% 16.05 kB 16.76 kB
oss-experimental/react-server-dom-turbopack/cjs/react-server-dom-turbopack-client.node.unbundled.development.js +3.51% 86.34 kB 89.37 kB +4.29% 16.37 kB 17.07 kB
oss-experimental/react-client/cjs/react-client-flight.development.js +3.50% 83.49 kB 86.42 kB +4.93% 15.28 kB 16.04 kB
oss-experimental/react-server-dom-turbopack/cjs/react-server-dom-turbopack-client.node.development.js +3.47% 87.15 kB 90.18 kB +4.25% 16.53 kB 17.24 kB
oss-experimental/react-server-dom-webpack/cjs/react-server-dom-webpack-client.edge.development.js +3.42% 88.52 kB 91.54 kB +4.12% 16.79 kB 17.48 kB
oss-experimental/react-server-dom-turbopack/cjs/react-server-dom-turbopack-client.edge.development.js +3.42% 88.53 kB 91.56 kB +4.12% 16.77 kB 17.47 kB
oss-experimental/react-server-dom-webpack/cjs/react-server-dom-webpack-client.node.unbundled.development.js +3.34% 90.33 kB 93.35 kB +4.08% 16.89 kB 17.58 kB
oss-experimental/react-server-dom-webpack/cjs/react-server-dom-webpack-client.node.development.js +3.31% 91.13 kB 94.14 kB +4.05% 17.06 kB 17.76 kB
oss-stable-rc/react-server-dom-esm/esm/react-server-dom-esm-client.browser.development.js +2.30% 104.77 kB 107.18 kB +3.02% 23.55 kB 24.26 kB
oss-stable-semver/react-server-dom-esm/esm/react-server-dom-esm-client.browser.development.js +2.30% 104.77 kB 107.18 kB +3.02% 23.55 kB 24.26 kB
oss-stable/react-server-dom-esm/esm/react-server-dom-esm-client.browser.development.js +2.30% 104.77 kB 107.18 kB +3.02% 23.55 kB 24.26 kB
oss-stable-rc/react-server-dom-esm/cjs/react-server-dom-esm-client.browser.development.js +0.83% 74.50 kB 75.11 kB +0.96% 14.03 kB 14.16 kB
oss-stable-semver/react-server-dom-esm/cjs/react-server-dom-esm-client.browser.development.js +0.83% 74.50 kB 75.11 kB +0.96% 14.03 kB 14.16 kB
oss-stable/react-server-dom-esm/cjs/react-server-dom-esm-client.browser.development.js +0.83% 74.50 kB 75.11 kB +0.96% 14.03 kB 14.16 kB
oss-stable-rc/react-server-dom-turbopack/cjs/react-server-dom-turbopack-client.browser.development.js +0.81% 76.35 kB 76.97 kB +1.00% 14.42 kB 14.57 kB
oss-stable-semver/react-server-dom-turbopack/cjs/react-server-dom-turbopack-client.browser.development.js +0.81% 76.35 kB 76.97 kB +1.00% 14.42 kB 14.57 kB
oss-stable/react-server-dom-turbopack/cjs/react-server-dom-turbopack-client.browser.development.js +0.81% 76.35 kB 76.97 kB +1.00% 14.42 kB 14.57 kB
oss-stable-rc/react-server-dom-webpack/cjs/react-server-dom-webpack-client.browser.development.js +0.80% 76.81 kB 77.42 kB +0.96% 14.54 kB 14.68 kB
oss-stable-semver/react-server-dom-webpack/cjs/react-server-dom-webpack-client.browser.development.js +0.80% 76.81 kB 77.42 kB +0.96% 14.54 kB 14.68 kB
oss-stable/react-server-dom-webpack/cjs/react-server-dom-webpack-client.browser.development.js +0.80% 76.81 kB 77.42 kB +0.96% 14.54 kB 14.68 kB
oss-stable-rc/react-server-dom-esm/cjs/react-server-dom-esm-client.node.development.js +0.77% 79.59 kB 80.21 kB +0.92% 15.03 kB 15.16 kB
oss-stable-semver/react-server-dom-esm/cjs/react-server-dom-esm-client.node.development.js +0.77% 79.59 kB 80.21 kB +0.92% 15.03 kB 15.16 kB
oss-stable/react-server-dom-esm/cjs/react-server-dom-esm-client.node.development.js +0.77% 79.59 kB 80.21 kB +0.92% 15.03 kB 15.16 kB
oss-stable-rc/react-server-dom-turbopack/cjs/react-server-dom-turbopack-client.node.unbundled.development.js +0.76% 81.00 kB 81.62 kB +0.94% 15.34 kB 15.48 kB
oss-stable-semver/react-server-dom-turbopack/cjs/react-server-dom-turbopack-client.node.unbundled.development.js +0.76% 81.00 kB 81.62 kB +0.94% 15.34 kB 15.48 kB
oss-stable/react-server-dom-turbopack/cjs/react-server-dom-turbopack-client.node.unbundled.development.js +0.76% 81.00 kB 81.62 kB +0.94% 15.34 kB 15.48 kB
oss-stable-rc/react-client/cjs/react-client-flight.development.js +0.76% 78.04 kB 78.63 kB +1.15% 14.30 kB 14.46 kB
oss-stable-semver/react-client/cjs/react-client-flight.development.js +0.76% 78.04 kB 78.63 kB +1.15% 14.30 kB 14.46 kB
oss-stable/react-client/cjs/react-client-flight.development.js +0.76% 78.04 kB 78.63 kB +1.15% 14.30 kB 14.46 kB
oss-stable-rc/react-server-dom-turbopack/cjs/react-server-dom-turbopack-client.node.development.js +0.75% 81.81 kB 82.43 kB +0.90% 15.51 kB 15.65 kB
oss-stable-semver/react-server-dom-turbopack/cjs/react-server-dom-turbopack-client.node.development.js +0.75% 81.81 kB 82.43 kB +0.90% 15.51 kB 15.65 kB
oss-stable/react-server-dom-turbopack/cjs/react-server-dom-turbopack-client.node.development.js +0.75% 81.81 kB 82.43 kB +0.90% 15.51 kB 15.65 kB
oss-stable-rc/react-server-dom-webpack/cjs/react-server-dom-webpack-client.edge.development.js +0.74% 83.18 kB 83.79 kB +0.89% 15.80 kB 15.94 kB
oss-stable-semver/react-server-dom-webpack/cjs/react-server-dom-webpack-client.edge.development.js +0.74% 83.18 kB 83.79 kB +0.89% 15.80 kB 15.94 kB
oss-stable/react-server-dom-webpack/cjs/react-server-dom-webpack-client.edge.development.js +0.74% 83.18 kB 83.79 kB +0.89% 15.80 kB 15.94 kB
oss-stable-rc/react-server-dom-turbopack/cjs/react-server-dom-turbopack-client.edge.development.js +0.74% 83.19 kB 83.81 kB +0.89% 15.78 kB 15.92 kB
oss-stable-semver/react-server-dom-turbopack/cjs/react-server-dom-turbopack-client.edge.development.js +0.74% 83.19 kB 83.81 kB +0.89% 15.78 kB 15.92 kB
oss-stable/react-server-dom-turbopack/cjs/react-server-dom-turbopack-client.edge.development.js +0.74% 83.19 kB 83.81 kB +0.89% 15.78 kB 15.92 kB
oss-experimental/react-server/cjs/react-server-flight.development.js +0.71% 99.25 kB 99.95 kB +0.57% 18.25 kB 18.36 kB
oss-stable-rc/react-server-dom-webpack/cjs/react-server-dom-webpack-client.node.unbundled.development.js +0.66% 84.92 kB 85.48 kB +0.59% 15.86 kB 15.96 kB
oss-stable-semver/react-server-dom-webpack/cjs/react-server-dom-webpack-client.node.unbundled.development.js +0.66% 84.92 kB 85.48 kB +0.59% 15.86 kB 15.96 kB
oss-stable/react-server-dom-webpack/cjs/react-server-dom-webpack-client.node.unbundled.development.js +0.66% 84.92 kB 85.48 kB +0.59% 15.86 kB 15.96 kB
oss-stable-rc/react-server-dom-webpack/cjs/react-server-dom-webpack-client.node.development.js +0.65% 85.71 kB 86.27 kB +0.57% 16.04 kB 16.14 kB
oss-stable-semver/react-server-dom-webpack/cjs/react-server-dom-webpack-client.node.development.js +0.65% 85.71 kB 86.27 kB +0.57% 16.04 kB 16.14 kB
oss-stable/react-server-dom-webpack/cjs/react-server-dom-webpack-client.node.development.js +0.65% 85.71 kB 86.27 kB +0.57% 16.04 kB 16.14 kB
oss-stable-rc/react-server/cjs/react-server-flight.development.js +0.61% 85.28 kB 85.80 kB +0.47% 15.85 kB 15.93 kB
oss-stable-semver/react-server/cjs/react-server-flight.development.js +0.61% 85.28 kB 85.80 kB +0.47% 15.85 kB 15.93 kB
oss-stable/react-server/cjs/react-server-flight.development.js +0.61% 85.28 kB 85.80 kB +0.47% 15.85 kB 15.93 kB
oss-experimental/react-server-dom-esm/cjs/react-server-dom-esm-server.node.development.js +0.50% 139.99 kB 140.70 kB +0.36% 25.90 kB 25.99 kB
oss-experimental/react-server-dom-turbopack/cjs/react-server-dom-turbopack-server.browser.development.js +0.49% 142.97 kB 143.67 kB +0.37% 26.41 kB 26.51 kB
oss-experimental/react-server-dom-webpack/cjs/react-server-dom-webpack-server.browser.development.js +0.49% 143.59 kB 144.30 kB +0.36% 26.59 kB 26.68 kB
oss-experimental/react-server-dom-turbopack/cjs/react-server-dom-turbopack-server.edge.development.js +0.48% 145.76 kB 146.47 kB +0.33% 26.82 kB 26.91 kB
oss-experimental/react-server-dom-webpack/cjs/react-server-dom-webpack-server.edge.development.js +0.48% 145.91 kB 146.62 kB +0.33% 26.89 kB 26.97 kB
oss-experimental/react-server-dom-turbopack/cjs/react-server-dom-turbopack-server.node.unbundled.development.js +0.48% 146.36 kB 147.07 kB +0.35% 26.87 kB 26.96 kB
oss-experimental/react-server-dom-webpack/cjs/react-server-dom-webpack-server.node.unbundled.development.js +0.48% 146.52 kB 147.23 kB +0.35% 26.93 kB 27.03 kB
oss-experimental/react-server-dom-turbopack/cjs/react-server-dom-turbopack-server.node.development.js +0.48% 147.48 kB 148.18 kB +0.36% 27.14 kB 27.24 kB
oss-experimental/react-server-dom-webpack/cjs/react-server-dom-webpack-server.node.development.js +0.48% 147.62 kB 148.33 kB +0.36% 27.20 kB 27.30 kB
oss-stable-rc/react-server-dom-esm/cjs/react-server-dom-esm-server.node.development.js +0.41% 125.29 kB 125.81 kB +0.27% 23.40 kB 23.46 kB
oss-stable-semver/react-server-dom-esm/cjs/react-server-dom-esm-server.node.development.js +0.41% 125.29 kB 125.81 kB +0.27% 23.40 kB 23.46 kB
oss-stable/react-server-dom-esm/cjs/react-server-dom-esm-server.node.development.js +0.41% 125.29 kB 125.81 kB +0.27% 23.40 kB 23.46 kB
oss-stable-rc/react-server-dom-turbopack/cjs/react-server-dom-turbopack-server.browser.development.js +0.40% 129.05 kB 129.56 kB +0.29% 23.98 kB 24.05 kB
oss-stable-semver/react-server-dom-turbopack/cjs/react-server-dom-turbopack-server.browser.development.js +0.40% 129.05 kB 129.56 kB +0.29% 23.98 kB 24.05 kB
oss-stable/react-server-dom-turbopack/cjs/react-server-dom-turbopack-server.browser.development.js +0.40% 129.05 kB 129.56 kB +0.29% 23.98 kB 24.05 kB
oss-stable-rc/react-server-dom-webpack/cjs/react-server-dom-webpack-server.browser.development.js +0.40% 129.67 kB 130.19 kB +0.29% 24.16 kB 24.23 kB
oss-stable-semver/react-server-dom-webpack/cjs/react-server-dom-webpack-server.browser.development.js +0.40% 129.67 kB 130.19 kB +0.29% 24.16 kB 24.23 kB
oss-stable/react-server-dom-webpack/cjs/react-server-dom-webpack-server.browser.development.js +0.40% 129.67 kB 130.19 kB +0.29% 24.16 kB 24.23 kB
oss-stable-rc/react-server-dom-turbopack/cjs/react-server-dom-turbopack-server.edge.development.js +0.40% 130.25 kB 130.77 kB +0.27% 24.20 kB 24.26 kB
oss-stable-semver/react-server-dom-turbopack/cjs/react-server-dom-turbopack-server.edge.development.js +0.40% 130.25 kB 130.77 kB +0.27% 24.20 kB 24.26 kB
oss-stable/react-server-dom-turbopack/cjs/react-server-dom-turbopack-server.edge.development.js +0.40% 130.25 kB 130.77 kB +0.27% 24.20 kB 24.26 kB
oss-stable-rc/react-server-dom-webpack/cjs/react-server-dom-webpack-server.edge.development.js +0.40% 130.40 kB 130.92 kB +0.27% 24.27 kB 24.33 kB
oss-stable-semver/react-server-dom-webpack/cjs/react-server-dom-webpack-server.edge.development.js +0.40% 130.40 kB 130.92 kB +0.27% 24.27 kB 24.33 kB
oss-stable/react-server-dom-webpack/cjs/react-server-dom-webpack-server.edge.development.js +0.40% 130.40 kB 130.92 kB +0.27% 24.27 kB 24.33 kB
oss-stable-rc/react-server-dom-turbopack/cjs/react-server-dom-turbopack-server.node.unbundled.development.js +0.39% 131.66 kB 132.18 kB +0.27% 24.35 kB 24.42 kB
oss-stable-semver/react-server-dom-turbopack/cjs/react-server-dom-turbopack-server.node.unbundled.development.js +0.39% 131.66 kB 132.18 kB +0.27% 24.35 kB 24.42 kB
oss-stable/react-server-dom-turbopack/cjs/react-server-dom-turbopack-server.node.unbundled.development.js +0.39% 131.66 kB 132.18 kB +0.27% 24.35 kB 24.42 kB
oss-stable-rc/react-server-dom-webpack/cjs/react-server-dom-webpack-server.node.unbundled.development.js +0.39% 131.82 kB 132.34 kB +0.27% 24.42 kB 24.48 kB
oss-stable-semver/react-server-dom-webpack/cjs/react-server-dom-webpack-server.node.unbundled.development.js +0.39% 131.82 kB 132.34 kB +0.27% 24.42 kB 24.48 kB
oss-stable/react-server-dom-webpack/cjs/react-server-dom-webpack-server.node.unbundled.development.js +0.39% 131.82 kB 132.34 kB +0.27% 24.42 kB 24.48 kB
oss-stable-rc/react-server-dom-turbopack/cjs/react-server-dom-turbopack-server.node.development.js +0.39% 132.77 kB 133.29 kB +0.28% 24.62 kB 24.69 kB
oss-stable-semver/react-server-dom-turbopack/cjs/react-server-dom-turbopack-server.node.development.js +0.39% 132.77 kB 133.29 kB +0.28% 24.62 kB 24.69 kB
oss-stable/react-server-dom-turbopack/cjs/react-server-dom-turbopack-server.node.development.js +0.39% 132.77 kB 133.29 kB +0.28% 24.62 kB 24.69 kB
oss-stable-rc/react-server-dom-webpack/cjs/react-server-dom-webpack-server.node.development.js +0.39% 132.92 kB 133.44 kB +0.28% 24.69 kB 24.75 kB
oss-stable-semver/react-server-dom-webpack/cjs/react-server-dom-webpack-server.node.development.js +0.39% 132.92 kB 133.44 kB +0.28% 24.69 kB 24.75 kB
oss-stable/react-server-dom-webpack/cjs/react-server-dom-webpack-server.node.development.js +0.39% 132.92 kB 133.44 kB +0.28% 24.69 kB 24.75 kB
oss-experimental/react-html/cjs/react-html.react-server.development.js +0.34% 491.54 kB 493.22 kB +0.31% 88.60 kB 88.87 kB

Generated by 🚫 dangerJS against 65c5048

@sebmarkbage sebmarkbage merged commit 12e9579 into facebook:main Jul 31, 2024
187 checks passed
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