This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2021-08-23
Channels
- # babashka (22)
- # beginners (8)
- # calva (7)
- # clj-kondo (65)
- # cljdoc (9)
- # cljsrn (1)
- # clojure (53)
- # clojure-australia (4)
- # clojure-europe (49)
- # clojure-gamedev (2)
- # clojure-italy (13)
- # clojure-nl (1)
- # clojure-spec (19)
- # clojure-uk (4)
- # clojurescript (48)
- # clojureverse-ops (1)
- # core-async (3)
- # css (2)
- # cursive (15)
- # datomic (6)
- # degree9 (2)
- # depstar (4)
- # emacs (2)
- # find-my-lib (1)
- # fulcro (16)
- # graalvm (11)
- # gratitude (1)
- # honeysql (9)
- # introduce-yourself (2)
- # jobs (1)
- # joker (2)
- # livestream (2)
- # malli (16)
- # nbb (4)
- # news-and-articles (2)
- # off-topic (1)
- # pathom (7)
- # polylith (10)
- # practicalli (1)
- # re-frame (7)
- # reitit (1)
- # releases (3)
- # remote-jobs (1)
- # rewrite-clj (19)
- # shadow-cljs (10)
- # tools-build (1)
- # tools-deps (9)
- # uncomplicate (1)
- # vim (3)
- # xtdb (44)
hmm, trying to start LMDB as index store on a mac (intel) and openjdk 15 causes the process to crash... nrepl messages shows
WARNING: /usr/local/Cellar/openjdk/15.0.1/libexec/openjdk.jdk/Contents/Home/bin/java is loading libcrypto in an unsafe way
[nREPL] Connection closed unexpectedly (connection broken by remote peer)
anyone ran into this?Hi @U11SJ6Q0K am I right in thinking you are using OSX? It looks ~identical to https://github.com/juxt/crux/issues/1564 and https://github.com/juxt/crux/issues/894#issuecomment-891181861 If that's the case, then you should be able to set env vars `CRUX_DISABLE_LIBCRYPTO=true CRUX_ENABLE_BYTEUTILS_SHA1=true` to workaround it (roughly as per the suggestion in the second link)
Cool, good to know. We'll add a pointer about this in the docs since it seems to have come up enough times now(!) :thumbsup:
I for some reason didn't find that issue when googling, so a pointer in the docs might be in place
I am seeing some very strange and random behaviour related to the usage of Or clauses and predicates. I get the same logic variables
error mentioned in the documentation at random times from the same query. I can remove one of the nested ands
in the or
and insert it in a different order and some times the error goes away. All the nested ands use the same logic variables. Only the predicates used are different.
@U09UV3WP6 Is it possible to construct a small repro query you can attach to an issue? Do you think you'd need to provide a sample data set to repro as well? @U050V1N74 is out today, but he'll be back tomorrow. Hopefully it's something he can help you with quickly.
No worries. Out of curiosity, if it's difficult to create a sanitized repro query, is it an option to submit the offending code to us in private? (We wouldn't attach it to a GitHub issue, obviously.)
Awesome. Thanks!
Your more than welcome. Should I ping @U050V1N74 ?
Thanks. Do let me know if I missing something. It is a very odd problem and it is very possible I am doing something silly.
@U050V1N74 Do you need anything further from me?
@U09UV3WP6: I've got the following result for the given query:
#{[{:type :helpdesk,
:sub-type :request,
:request-id 0,
:error-category 2,
:time #inst "2021-10-13T02:55:31.846-00:00",
:crux.db/id :helpdesk-error-request-0}
{:type :helpdesk,
:sub-type :remediation-start,
:request-id 0,
:time #inst "2021-10-13T04:05:31.846-00:00",
:crux.db/id :helpdesk-error-remediation-start-0}]
[{:type :helpdesk,
:sub-type :request,
:request-id 0,
:error-category 2,
:time #inst "2021-10-13T02:55:31.846-00:00",
:crux.db/id :helpdesk-error-request-0}
{:type :helpdesk,
:sub-type :first-response,
:request-id 0,
:time #inst "2021-10-13T03:20:31.846-00:00",
:crux.db/id :helpdesk-error-first-response-0}]}
which seems correct to me?admittedly I've replaced the predicates with the following, as the example didn't seem to depend on the business logic in example.time
(they were all on the same day)
(defn diff-gt-15-mins [^Date t1 ^Date t2]
(pos? (.compareTo (.abs (Duration/between (.toInstant t1)
(.toInstant t2)))
(Duration/ofMinutes 15))))
(defn diff-gt-1-hour [^Date t1 ^Date t2]
(pos? (.compareTo (.abs (Duration/between (.toInstant t1)
(.toInstant t2)))
(Duration/ofHours 1))));
That's the correct result. The problem is that I intermittendly get the same logic variables
error mentioned in the documentation from the same query without changing anything. I have no idea what causes this.
that said, I'd be even more surprised if changing the predicates makes a difference - we don't/can't look inside the predicate in any way, so unless the predicate's non-deterministic I doubt it's that
@U09UV3WP6: have you managed to repro it on the example given? I've thrown all the cores I have at it and haven't seen it fail yet 😕
Yes, it was reproed on the example, but don'tr spend more time on it. I will get back to you if it happens again. Is there anything I can capture to make it easier to diagnose if it reoccurs?
thanks 🙂 there's debug-level logging on crux.query
but that's very chatty, I wouldn't recommend turning that on unless you get a high hit-rate
they're loosely related and use a lot of the same code, but unfortunately it's not quite just a special case of or-join
that's the common function, yep - while there's a lot in common, there's also a fair bit of branching in there based on whether it's an or
or an or-join
The ?
prefix is a convention is other Datalog dbs. Not so much in Crux. You're welcome to use it, but it doesn't affect the logic vars one way or the other.