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(core): handle returning infinite promise in derived atoms #1089

Merged
merged 2 commits into from
Apr 9, 2022

Conversation

dai-shi
Copy link
Member

@dai-shi dai-shi commented Apr 9, 2022

close #1054.

@vercel
Copy link

vercel bot commented Apr 9, 2022

This pull request is being automatically deployed with Vercel (learn more).
To see the status of your deployment, click below or on the icon next to each commit.

🔍 Inspect: https://vercel.com/pmndrs/jotai/3whygxVbAAg6APVmbF9aV591gYzr
✅ Preview: https://jotai-git-fix-issue-1054-pmndrs.vercel.app

@codesandbox-ci
Copy link

codesandbox-ci bot commented Apr 9, 2022

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit d1164ce:

Sandbox Source
React Configuration
React Typescript Configuration
React Browserify Configuration
React Snowpack Configuration
Next.js Configuration
Next.js with custom Babel config Configuration
React with custom Babel config Configuration
nervous-fermi-j89jhw Issue #1054

@github-actions
Copy link

github-actions bot commented Apr 9, 2022

Size Change: +41 B (0%)

Total Size: 132 kB

Filename Size Change
dist/esm/index.js 5.45 kB +5 B (0%)
dist/index.js 6.25 kB +7 B (0%)
dist/system/index.development.js 5.68 kB +5 B (0%)
dist/system/index.production.js 3.05 kB +8 B (0%)
dist/umd/index.development.js 6.35 kB +7 B (0%)
dist/umd/index.production.js 3.29 kB +9 B (0%)
ℹ️ View Unchanged
Filename Size
dist/babel/plugin-debug-label.js 881 B
dist/babel/plugin-react-refresh.js 1.1 kB
dist/babel/preset.js 1.33 kB
dist/devtools.js 3.25 kB
dist/esm/babel/plugin-debug-label.js 711 B
dist/esm/babel/plugin-react-refresh.js 924 B
dist/esm/babel/preset.js 1.15 kB
dist/esm/devtools.js 2.48 kB
dist/esm/immer.js 616 B
dist/esm/optics.js 661 B
dist/esm/query.js 1.25 kB
dist/esm/redux.js 251 B
dist/esm/urql.js 1.5 kB
dist/esm/utils.js 4.75 kB
dist/esm/valtio.js 526 B
dist/esm/xstate.js 1.13 kB
dist/esm/zustand.js 284 B
dist/immer.js 732 B
dist/optics.js 938 B
dist/query.js 1.36 kB
dist/redux.js 314 B
dist/system/babel/plugin-debug-label.development.js 818 B
dist/system/babel/plugin-debug-label.production.js 619 B
dist/system/babel/plugin-react-refresh.development.js 1.02 kB
dist/system/babel/plugin-react-refresh.production.js 798 B
dist/system/babel/preset.development.js 1.25 kB
dist/system/babel/preset.production.js 986 B
dist/system/devtools.development.js 2.64 kB
dist/system/devtools.production.js 1.83 kB
dist/system/immer.development.js 739 B
dist/system/immer.production.js 461 B
dist/system/optics.development.js 765 B
dist/system/optics.production.js 456 B
dist/system/query.development.js 1.4 kB
dist/system/query.production.js 963 B
dist/system/redux.development.js 339 B
dist/system/redux.production.js 217 B
dist/system/urql.development.js 1.65 kB
dist/system/urql.production.js 1.19 kB
dist/system/utils.development.js 5.08 kB
dist/system/utils.production.js 3.31 kB
dist/system/valtio.development.js 639 B
dist/system/valtio.production.js 402 B
dist/system/xstate.development.js 1.25 kB
dist/system/xstate.production.js 805 B
dist/system/zustand.development.js 372 B
dist/system/zustand.production.js 235 B
dist/umd/babel/plugin-debug-label.development.js 1.03 kB
dist/umd/babel/plugin-debug-label.production.js 776 B
dist/umd/babel/plugin-react-refresh.development.js 1.24 kB
dist/umd/babel/plugin-react-refresh.production.js 931 B
dist/umd/babel/preset.development.js 1.47 kB
dist/umd/babel/preset.production.js 1.12 kB
dist/umd/devtools.development.js 3.38 kB
dist/umd/devtools.production.js 2.26 kB
dist/umd/immer.development.js 878 B
dist/umd/immer.production.js 576 B
dist/umd/optics.development.js 1.08 kB
dist/umd/optics.production.js 671 B
dist/umd/query.development.js 1.5 kB
dist/umd/query.production.js 1.03 kB
dist/umd/redux.development.js 454 B
dist/umd/redux.production.js 322 B
dist/umd/urql.development.js 1.71 kB
dist/umd/urql.production.js 1.17 kB
dist/umd/utils.development.js 6.11 kB
dist/umd/utils.production.js 3.78 kB
dist/umd/valtio.development.js 722 B
dist/umd/valtio.production.js 500 B
dist/umd/xstate.development.js 1.33 kB
dist/umd/xstate.production.js 845 B
dist/umd/zustand.development.js 479 B
dist/umd/zustand.production.js 334 B
dist/urql.js 1.56 kB
dist/utils.js 5.94 kB
dist/valtio.js 586 B
dist/xstate.js 1.19 kB
dist/zustand.js 344 B

compressed-size-action

@dai-shi dai-shi added this to the v1.6.3 milestone Apr 9, 2022
@dai-shi dai-shi merged commit 5bcb3c0 into main Apr 9, 2022
@dai-shi dai-shi deleted the fix/issue-1054 branch April 9, 2022 12:44
hirokibeta added a commit to hirokibeta/jotai that referenced this pull request Apr 24, 2022
dai-shi pushed a commit that referenced this pull request Apr 28, 2022
… in some cases (#1118)

* add failing test

* revert #1089 to fix infinite loop
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.

Derived atom getting stuck in suspense when initial value is a Promise that does not resolve
1 participant