GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
GeezerVison is showing github.com — [compiler runtime] repro: infinite render with useMemoCache + render phase updates by mofeiZ · Pull Request #30849 · react/react Conversation
|
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
Comparing: 61739a8a0fd23adf18336d96f9c307a1cd897354...c173745680ff89b2d145eaa78f34d41baa89b5ce Critical size changesIncludes critical production bundles, as well as any change greater than 2%:
Significant size changesIncludes any change greater than 0.2%: (No significant changes) |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
thanks for the repro! let's land and we can work on a fix
Sorry, something went wrong.
There was an error while loading. Please reload this page.
**breaking change for canary users: Bumps peer dependency of React from `19.0.0-rc-7771d3a7-20240827` to `19.0.0-rc-94e652d5-20240912`** [diff react/react@7771d3a7...94e652d5](react/react@7771d3a...94e652d) <details> <summary>React upstream changes</summary> - react/react#30952 - react/react#30950 - react/react#30946 - react/react#30934 - react/react#30947 - react/react#30945 - react/react#30938 - react/react#30936 - react/react#30879 - react/react#30888 - react/react#30931 - react/react#30930 - react/react#30832 - react/react#30929 - react/react#30926 - react/react#30925 - react/react#30905 - react/react#30900 - react/react#30910 - react/react#30906 - react/react#30899 - react/react#30919 - react/react#30708 - react/react#30907 - react/react#30897 - react/react#30896 - react/react#30895 - react/react#30887 - react/react#30889 - react/react#30893 - react/react#30892 - react/react#30891 - react/react#30882 - react/react#30881 - react/react#30870 - react/react#30849 - react/react#30878 - react/react#30865 - react/react#30869 - react/react#30875 - react/react#30800 - react/react#30762 - react/react#30831 - react/react#30866 - react/react#30853 - react/react#30850 - react/react#30847 - react/react#30842 - react/react#30837 - react/react#30848 - react/react#30844 - react/react#30839 - react/react#30802 - react/react#30841 - react/react#30827 - react/react#30826 - react/react#30825 - react/react#30824 - react/react#30840 - react/react#30838 - react/react#30836 - react/react#30819 - react/react#30816 - react/react#30814 - react/react#30813 - react/react#30812 - react/react#30811 </details> --------- Co-authored-by: vercel-release-bot <[email protected]>
…phase updates (react#30849) Repro for an infinite render bug we found when testing internally. See equivalent codesandbox repro [here](https://codesandbox.io/p/sandbox/epic-euclid-mr7lm3). When render phase updates cause a re-render, useMemoCache arrays for the fiber are [cleared](https://github.com/facebook/react/blob/main/packages/react-reconciler/src/ReactFiberHooks.js#L819) and [recreated on every retry](https://github.com/facebook/react/blob/main/packages/react-reconciler/src/ReactFiberHooks.js#L1223) while hook state is preserved. This pattern (queuing re-renders on the current fiber during render) is perfectly valid. I believe this is a bug as React compiler currently replaces `useMemo`s with `useMemoCache` calls and inlined instructions, taking care to preserve existing memoization dependencies. This should be the identity transform, but runtime implementation differences mean that uncompiled code behaves as expected (no infinite render) while compiled code fails to render.
6a1722d1
Deployed
There was an error while loading. Please reload this page.
Successfully merging this pull request may close these issues.
There was an error while loading. Please reload this page.