Edge case where derived atoms that depend on stable derived atoms are re-computed #2738
Unanswered
Pinpickle
asked this question in
Bug report
Replies: 1 comment 2 replies
-
Thanks for reporting. |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Bug Description
This is a weird one... I've managed to find a situation where atoms that depend on stable derived atoms (that is, they return a stable value) end up re-evaluating.
Rather than try to explain what's going on, here's a failing test case:
From what I can tell, it's due to the combination of the dependency order changing and the
force
being passed byrecomputeDependents
:jotai/src/vanilla/store.ts
Line 548 in b415826
Reproduction Link
https://stackblitz.com/github/Pinpickle/jotai/tree/stable-dependency-bug
Beta Was this translation helpful? Give feedback.
All reactions