Fork me on GitHub
#datomic
<
2015-12-06
>
magnars12:12:40

I'm seeing collisions between tempids generated by the transactor, and tempids generated by my process. I understand why it happens, but it is a scary trap to fall into.

magnars12:12:44

I could do something like this:

magnars12:12:47

(some #(when (even? (:idx %)) %)
        (repeatedly #(d/tempid :db.part/user)))

magnars12:12:00

and replace even? with odd? on the transactor

magnars12:12:06

but is that really the best way to do it?