Fork me on GitHub
#datomic
<
2020-01-06
>
Socks02:01:45

Indeed the answer was to upgrade

philip21:01:25

Hello everyone, I am seeing a very confusing side effect when I upgrade to the latest datomic version. When I upgrade to com.datomic/datomic-pro "0.9.6014" it breaks my cljs test compilation with this error:

clojure.lang.ExceptionInfo: failed compiling file:out/cljs/test.cljs {:file #object[.File 0x6759042b "out/cljs/test.cljs"], :clojure.error/phase :compilation}
...
Caused by: clojure.lang.ExceptionInfo: Reader tag must be a symbol {:type :reader-exception, :line 376, :column 13, :file "/asdf/out/cljs/test.cljs"}
Here is the offending line: https://github.com/clojure/clojurescript/blob/master/src/main/cljs/cljs/test.cljs#L376 For some reason it can't read the ##NaN. The tests are run via lein-cljsbuild/doo and karma-cljs-test I have verified just changing between 0.9.6014 and 5981 causes this issue. I also checked the new datomic-pro version doesn't bring in a new version of clojurescript or anything, the only transitive dependency it updates is com.datomic/client-api. I upgraded all dependencies that are possibly involved (clojurescript, karma, etc) and that didn't help.

philip21:01:16

Does anyone have any idea what could cause clojurescript to forget about NaN?

favila21:01:32

Older CLJSs don’t understand this; perhaps your dep tree got shook up in such a way that it ended up downgrading cljs?

philip21:01:56

hmm thanks. lein deps :tree shows I'm using org.clojure/clojurescript "1.10.597" but it's possibly I don't completely understand how lein doo and cljsbuild work and they're using an older version?

favila21:01:38

lein with-profile test deps :tree should force the test profile on and you can see if the tree is different

favila21:01:52

1.10.597 shouldn’t be giving this problem though

favila21:01:29

could also be cljs is on the classpath multiple times and it’s picking up older compiled classes and newer non-classes. try cleaning target and out?

philip21:01:15

Any version of 1.10 should be fine with ##NaN right? with-profile shows the same clojurescript deps, and looking at the classpath printed by lein I don't see any clojurescript jar that's not clojurescript-1.10.597.jar . Although it does fetch clojurescript-1.10.238 when I fetch deps in a new docker container. From figwheel it looks like

favila22:01:14

yeah any 10 should be fine iirc

favila22:01:22

hm, maybe it’s tools.reader

philip22:01:40

same story there where something is causing it to fetch tools.reader-1.0.0-beta3.jar but only 1.3.2 (the latest) appears on the classpath.

philip22:01:49

the confusing thing is that the only thing in the dep tree that changes is com.datomic/datomic-pro and com.datomic/client-api. A diff plain old diff is identical except those two lines.