datascript icon indicating copy to clipboard operation
datascript copied to clipboard

Listener notifications might arrive out-of-order

Open tonsky opened this issue 8 years ago • 0 comments

I’m seeing transactions come in to my d/listen! listener in the wrong order when another listener commits a transaction. Here’s the output from both listeners printing (:tx-data tx-report)

"listener 1" [#datascript/Datom [0 :modal/open :new-outing t true]]
;; inside listener 1 - transacts [[:db/add 0 :modal/open :sign-up]]
"listener 1" [#datascript/Datom [0 :modal/open :new-outing t false] #datascript/Datom [0 :modal/open :sign-up t true]]
"listener 2" [#datascript/Datom [0 :modal/open :new-outing t false] #datascript/Datom [0 :modal/open :sign-up t true]]
"listener 2" [#datascript/Datom [0 :modal/open :new-outing t true]]

tonsky avatar Feb 01 '17 07:02 tonsky