-
-
Notifications
You must be signed in to change notification settings - Fork 643
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(vanilla): Returning the same Promise twice from an atom getter causes Promise chaining cycle. #2152
fix(vanilla): Returning the same Promise twice from an atom getter causes Promise chaining cycle. #2152
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
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 4369b53:
|
Co-authored-by: Daishi Kato <[email protected]>
Co-authored-by: Daishi Kato <[email protected]>
Tried the CodeSandbox CI build in our project where the bug was initially found, this change fixed the issue. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Thanks for your contribution!
It was a regression caused by #1933. |
Related Issues or Discussions
Fixes #2151
Summary
Wrote a unit test reproducing this bug
![image](https://private-user-images.githubusercontent.com/7166752/270981440-1f159ea8-b096-4a3c-88d5-b3283114b70f.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3Mzk0NzY4NTAsIm5iZiI6MTczOTQ3NjU1MCwicGF0aCI6Ii83MTY2NzUyLzI3MDk4MTQ0MC0xZjE1OWVhOC1iMDk2LTRhM2MtODhkNS1iMzI4MzExNGI3MGYucG5nP1gtQW16LUFsZ29yaXRobT1BV1M0LUhNQUMtU0hBMjU2JlgtQW16LUNyZWRlbnRpYWw9QUtJQVZDT0RZTFNBNTNQUUs0WkElMkYyMDI1MDIxMyUyRnVzLWVhc3QtMSUyRnMzJTJGYXdzNF9yZXF1ZXN0JlgtQW16LURhdGU9MjAyNTAyMTNUMTk1NTUwWiZYLUFtei1FeHBpcmVzPTMwMCZYLUFtei1TaWduYXR1cmU9MzBhZjcxZjdjN2FhNzlmODFjODg0ZDUwOWNhZGE2Y2FiOGY3MTg3ZTJkYzY2ZGEyMWFiZDAwOTQ1ZGI3YTBmOCZYLUFtei1TaWduZWRIZWFkZXJzPWhvc3QifQ.mEcZVbxO79vG-MlJkN576q50p7Kk8Lsb_Wco1sIS0RU)
Checking if the previous promise is different from the next before cancelling it fixes the issue.
Check List
yarn run prettier
for formatting code and docs