tolitius / mount

managing Clojure and ClojureScript app state since (reset)
Eclipse Public License 1.0
1.22k stars 88 forks source link

stop-except does not work as Described #86

Closed paulrd closed 7 years ago

paulrd commented 7 years ago

I have a very simple mount app using boot-clj. I'm in dev namespace and I try to do a stop-except followed by start. The defstate still gets restarted. Is this a bug or am I doing something wrong. The docs say that a state that hasn't been stopped will not be restarted.

To reproduce;


;; in app.core.clj:
(defstate ^{:on-reload :noop} token :start (println "starting"))
;; in dev.clj:
(mount/stop-except #'app.core/token)
(mount/start)
;; "starting" gets printed
{:started ["#'app.core/token"]}
paulrd commented 7 years ago

Hmm, maybe this is a case of #81, I will try snapshot instead of 0.1.11.

paulrd commented 7 years ago

Ah yes, this was fixed in 0.1.12-SNAPSHOT.