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

[Bug]: Connection does not reflect updates to database state made by another connection #464

Closed
yflim opened this issue Jan 13, 2022 · 1 comment
Labels
bug Something isn't working triage

Comments

@yflim
Copy link
Collaborator

yflim commented Jan 13, 2022

What version of Datahike are you using?

0.4.0

What version of Java are you using?

java version "16.0.2" 2021-07-20

What operating system are you using?

MacOS

What database EDN configuration are you using?

{:store {:backend :mem, :id (str (UUID/randomUUID))},
:keep-history? true,
:schema-flexibility :read}

Describe the bug

(require '[datahike.api :as d]
         '[datahike.test.utils :as dtu])
(def conn1 (dtu/setup-db))
(def conn2 (d/connect (._config (d/db conn1))))
(d/transact conn1 [{:stop/id "foo"}])
(d/datoms @conn1 :eavt)

yields

(#datahike/Datom [1 :stop/id "foo" 536870913]
 #datahike/Datom [536870913
                  :db/txInstant
                  #inst "2022-01-13T22:27:30.615-00:00"
                  536870913])

but

(d/datoms @conn2 :eavt)

yields nil.

What is the expected behaviour?

(d/datoms @conn1 :eavt) and (d/datoms @conn2 :eavt) should give the same value

How can the behaviour be reproduced?

See bug description

@yflim yflim added bug Something isn't working triage labels Jan 13, 2022
@whilo
Copy link
Member

whilo commented Mar 16, 2023

This issue is solved with the merging of #332.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working triage
Projects
Status: Done
Development

No branches or pull requests

2 participants