Question: @samir so this is a schema issue with the new cljs version then?

Asked By
Asked At
2018-03-04 19:20:17

Found 11 possible answers.

User Answered At Possible Answer
sekao 2018-03-04 19:31:14 yep it seems so
mikerod 2018-03-04 19:33:28 Alright. Hmm. I guess schema needs to get fixed...
sekao 2018-03-04 19:33:55 is it still actively maintained?
mikerod 2018-03-04 20:49:42 @sekao yeah I wasn’t sure on that. I think they at least probably still take pull requests
alex.furmanov 2018-03-14 18:20:48 Why this code
(ns experiments.a
creates infinite recursion?
(rules/fire-rules)) (-> (rules/mk-session) (rules/insert! (->A "a"))) (println "creating A") => [:not [A]] "" (rules/defrule create-a-if-not-exists (defrecord A [id]) [clojure.pprint :refer [pprint]])) (:require [clara.rules :as rules]
ethanc 2018-03-14 18:27:40 The initial state of the session makes the LHS of your rule evaluate as true thus it inserts an A , @alex.furmanov forever repeat which then makes your rule's LHS evaluate as false causing the truth maintenance of clara to logically retract the A that was insert.
zylox 2018-03-14 18:28:41 "ok i'll insert a if there is no A. Inserting. Ok now lets look at the state of things. Oh there is an A. Retract That thing i inserted. Ok now lets look at the state of things. Oh there is no A. Time to insert A...." repeat ad infinitum truth maintenance is the name of the game
alex.furmanov 2018-03-14 18:35:04 Thanks!
dave.dixon 2018-03-18 15:10:36 The trace listener feature is very helpful for finding the cause of loops.
talgiat 2018-03-21 16:01:02 is there a way to query for all types but one?
mikerod 2018-03-21 16:05:10 @talgiat the main problem I’d see with doing something like that is that the query may become a performance problem If you have a custom :fact-type-fn you could still accomplish similar
  [:test (not (isa? (type ?o) ExcludedType))])
  [?o <- Object]
You could probably do what you ask though:
(r/defquery [] It would be heavily hit since it’s working memory will change any time any fact in working memory is inserted/retracted (including from truth maintenance)

Related Questions