Data gehituta duen map-a erabili

Data gehituta duen map-a erabili

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/lnmnd/magnet.zer.git/'


remove old example code

remove old example code

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/modnakasta/weasel.git/'


Be less sensitive to the cwd

Be less sensitive to the cwd

--- support/build-support/src/main/clojure/immutant/build/tools.clj
+++ support/build-support/src/main/clojure/immutant/build/tools.clj
@@ -92,14 +92,15 @@
                (System/getenv "M2_REPO")
                (str (System/getenv "HOME") "/.m2/repository")))

-(def ^:dynamic root-dir nil)
-(def ^:dynamic build-dir nil)
-(def immutant-dir (memoize #(io/file build-dir "immutant")))
+(def ^:dynamic assembly-dir nil)
+(def root-dir (memoize #(-> assembly-dir .getParentFile .getParentFile)))
+(def build-dir (memoize #(io/file assembly-dir "target/stage")))
+(def immutant-dir (memoize #(io/file (build-dir) "immutant")))
 (def jboss-dir (memoize #(io/file (immutant-dir) "jboss")))
 (def versions
   (memoize
-   #(assoc (extract-versions (io/file root-dir "pom.xml") version-paths)
-      :jboss (System/getProperty "version.jbossas"))))
+    #(assoc (extract-versions (io/file (root-dir) "pom.xml") version-paths)
+       :jboss (System/getProperty "version.jbossas"))))

 (defn jboss-zip-file []
   (str m2-repo "/org/jboss/as/jboss-as-dist/"
@@ -123,7 +124,7 @@
               {:file       file
                :subsystem? (subsystem-module? file)}))
           {}
-          (glob/glob (str (.getAbsolutePath root-dir)
+          (glob/glob (str (.getAbsolutePath (root-dir))
                           "/modules/*/target/*-module"))))

 (defn immutant-subsystems []
@@ -132,8 +133,7 @@
        (map first)))

 (defmacro with-assembly-root [assembly-root & body]
-  `(binding [root-dir  (-> ~assembly-root .getCanonicalFile .getParentFile .getParentFile)
-             build-dir (io/file (.getCanonicalFile ~assembly-root) "target/stage")]
+  `(binding [assembly-dir  (-> ~assembly-root .getCanonicalFile)]
      ~@body))

 (defn attr= [attr val loc]
@@ -549,13 +549,13 @@
 (defn copy-static-config [slim?]
   (let [type (if slim? "slim" "full")]
     (with-message "Copying config files"
-      (io/copy (io/file (format "src/resources/standalone.%s.xml" type))
+      (io/copy (io/file assembly-dir (format "src/resources/standalone.%s.xml" type))
         (io/file (jboss-dir) "standalone/configuration/standalone.xml"))
-      (io/copy (io/file (format "src/resources/logging-standalone.properties" type))
+      (io/copy (io/file assembly-dir (format "src/resources/logging-standalone.properties" type))
                (io/file (jboss-dir) "standalone/configuration/logging.properties"))
-      (io/copy (io/file (format "src/resources/standalone-ha.%s.xml" type))
+      (io/copy (io/file assembly-dir (format "src/resources/standalone-ha.%s.xml" type))
                (io/file (jboss-dir) "standalone/configuration/standalone-ha.xml"))
-      (io/copy (io/file (format "src/resources/domain.%s.xml" type))
+      (io/copy (io/file assembly-dir (format "src/resources/domain.%s.xml" type))
                (io/file (jboss-dir) "domain/configuration/domain.xml"))
-      (io/copy (io/file (format "src/resources/host.%s.xml" type))
+      (io/copy (io/file assembly-dir (format "src/resources/host.%s.xml" type))
                (io/file (jboss-dir) "domain/configuration/host.xml")))))


add conexp.fca.graph with graph<->lattice conversions and (co)comparability

fatal: unable to access 'https://github.com/fcatools/conexp-clj.git/': The requested URL returned error: 403


only keywordize language if it exists

only keywordize language if it exists

fatal: unable to access 'https://github.com/democracyworks/voter-registration-http-api.git/': The requested URL returned error: 403


seems ok

seems ok

fatal: remote error: upload-pack: not our ref 6cd951a261ae7dbb0df3d4f45a9bee5fb14a8833
fatal: the remote end hung up unexpectedly


Adds an information model file for Kafka.

error: pathspec 'src/onyx/kafka/information_model.cljc' did not match any file(s) known to git

--- src/onyx/kafka/information_model.cljc
+++ src/onyx/kafka/information_model.cljc
@@ -0,0 +1,79 @@
+(ns onyx.kafka.information-model)
+
+(def model
+  {:catalog-entry
+   {:model {:kafka/topic
+            {:doc "The topic name to read from or write to."
+             :type :string}
+
+            :kafka/partition
+            {:doc "Partition to read from if auto-assignment is not used."
+             :type :string
+             :optional? true}
+
+            :kafka/group-id
+            {:doc "The consumer identity to store in ZooKeeper."
+             :type :string}
+
+            :kafka/zookeeper
+            {:doc "The ZooKeeper connection string."
+             :type :string}
+
+            :kafka/offset-reset
+            {:doc "Offset bound to seek to when not found - `:smallest` or `:largest`."
+             :type :keyword}
+
+            :kafka/force-reset?
+            {:doc "Force to read from the beginning or end of the log, as specified by `:kafka/offset-reset`. If false, reads from the last acknowledged messsage if it exists."
+             :type :boolean}
+
+            :kafka/chan-capacity
+            {:doc "The buffer size of the Kafka reading channel."
+             :type :long
+             :default 1000
+             :optional? true}
+
+            :kafka/fetch-size
+            {:doc "The size in bytes to request from ZooKeeper per fetch request."
+             :type :long
+             :default 307200
+             :optional? true}
+
+            :kafka/empty-read-back-off
+            {:doc "The amount of time to back off between reads when nothing was fetched from a consumer."
+             :type :long
+             :default 500
+             :optional? true}
+
+            :kafka/commit-interval
+            {:doc "The interval in milliseconds to commit the latest acknowledged offset to ZooKeeper."
+             :type :long
+             :default 2000
+             :optional? true}
+
+            :kafka/serializer-fn
+            {:doc "A keyword that represents a fully qualified namespaced function to serialize a message. Takes one argument - the segment."
+             :type :keyword}
+
+
+            :kafka/deserializer-fn
+            {:doc "A keyword that represents a fully qualified namespaced function to deserialize a message. Takes one argument, which must be a byte array."
+             :type :keyword}
+
+            :kafka/wrap-with-metadata?
+            {:doc "Wraps message into map with keys `:offset`, `:partitions`, `:topic` and `:message` itself."
+             :type :boolean
+             :default false
+             :optional? true}
+
+            :kafka/request-size
+            {:doc "The maximum size of request messages.  Maps to the `max.request.size` value of the internal kafka producer."
+             :type :long
+             :default 307200
+             :optional? true}
+
+            :kafka/no-seal?
+            {:doc "Do not write :done to the topic when task receives the sentinel signal (end of batch job)."
+             :type :boolean
+             :default false
+             :optional? true}}}})


Formatting

Formatting

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/physion/ovation-webapi.git/'


Add attribution in jetty.clj

Add attribution in jetty.clj

--- src/async_ring/adapters/jetty.clj
+++ src/async_ring/adapters/jetty.clj
@@ -11,6 +11,8 @@
             [ring.util.response :refer (response status)]
             [clojure.tools.logging :as log]
             [ring.util.servlet :as servlet]))
+
+;; This code is adapted from https://github.com/ninjudd/ring-async

 (defn to-jetty
   [async-handler]


SSL update

SSL update

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/couragelabs/coachbot.git/'


Add interop ns for tricky js interop calls.

fatal: unable to access 'https://github.com/studiospring/uxbox.git/': The requested URL returned error: 403


Fix generate-feeds to create the objects as public

This should fix #743.

fatal: unable to access 'https://github.com/tobias/clojars-web.git/': The requested URL returned error: 403


Added a consts file.

Added a consts file.

error: pathspec 'src/simulacrum/const.clj' did not match any file(s) known to git

--- src/simulacrum/const.clj
+++ src/simulacrum/const.clj
@@ -0,0 +1,7 @@
+(ns simulacrum.const)
+
+
+;; The following are the values provided by users when they take the inventory.
+(def min-value 1)
+(def mid-value 3)
+(def max-value 5)


expression problem with multimethods

expression problem with multimethods

error: pathspec 'src/sandbox/visitor/multimethod.clj' did not match any file(s) known to git

--- src/sandbox/visitor/multimethod.clj
+++ src/sandbox/visitor/multimethod.clj
@@ -0,0 +1,31 @@
+(ns sandbox.visitor.multimethod)
+;; expression problem
+
+;; initial domain
+(defmulti perimeter (fn [shape] (:shape-name shape)))
+
+(defmethod perimeter :circle [circle]
+  (* 2 Math/PI (:radius circle)))
+(defmethod perimeter :rectangle [rectangle]
+  (+ (* 2 (:width rectangle)) (* 2 (:height rectangle))))
+
+(def some-shapes [{:shape-name :circle :radius 4}
+                  {:shape-name :rectangle :width 2 :height 2}])
+
+;; extend method
+(defmulti area (fn [shape] (:shape-name shape)))
+
+(defmethod area :circle [circle]
+  (* Math/PI (:radius circle) (:radius circle)))
+(defmethod area :rectangle [rectangle]
+  (* (:width rectangle) (:height rectangle)))
+
+;; extend type
+(defmethod perimeter :square [square]
+  (* 4 (:side square)))
+(defmethod area :square [square]
+  (* (:side square) (:side square)))
+
+(def more-shapes (conj some-shapes
+                       {:shape-name :square :side 4}))
+


Change version to 0.7.0

Change version to 0.7.0

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/magoyette/marcandregoyette.com.git/'


Version 98-SNAPSHOT

Version 98-SNAPSHOT

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/tobias/clojars-web.git/'


Upgrade kehaar to 0.10.3

Upgrade kehaar to 0.10.3

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/democracyworks/scheduled-message-works.git/'


Version 1.8.2-SNAPSHOT

Version 1.8.2-SNAPSHOT

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/starcity-properties/odin.git/'


:arrow_up: Upgrade dependencies

:arrow_up: Upgrade dependencies

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/maoo/bot-unfurl.git/'


Exclude org.apache.httpcomponents/httpclient

See: https://github.com/aws/aws-sdk-java/issues/1919

fatal: unable to access 'https://github.com/democracyworks/electorate-works.git/': The requested URL returned error: 403


Make pulse card link open in new tab

Make pulse card link open in new tab

--- src/metabase/pulse.clj
+++ src/metabase/pulse.clj
@@ -294,7 +294,9 @@
 (defn render-pulse-card
   [card data render-img include-title include-buttons]
   (try
-    [:a {:href (card-href card) :style (str section-style "margin: 16px; margin-bottom: 16px; display: block; text-decoration: none;")}
+    [:a {:href (card-href card)
+         :target "_blank"
+         :style (str section-style "margin: 16px; margin-bottom: 16px; display: block; text-decoration: none;")}
       (if include-title
           [:div {:style "margin-bottom: 8px;"}
             [:span {:style header-style}


insertR

insertR

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/carolove/clojure-ring-app.git/'


Add export to Mathematica.

Add export to Mathematica.

error: pathspec 'src/algebolic/expression/mma.clj' did not match any file(s) known to git

--- src/algebolic/expression/mma.clj
+++ src/algebolic/expression/mma.clj
@@ -0,0 +1,22 @@
+(ns algebolic.expression.mma
+  "Some functions for using Mathematica with algebolic expressions."
+  (:require [algebolic.expression.core :as expression]))
+
+(defn fullform
+  "Transform an algebolic expression to a string in Mathematica format. Useful for copying expressions
+  into Mathematica when you're stuck!"
+  [expr]
+  (cond
+    (expression/non-terminal? expr) (case (first expr)
+                                      :plus (str "Plus[" (fullform (nth expr 1)) ", "
+                                                 (fullform (nth expr 2)) "]")
+                                      :minus (str "Subtract[" (fullform (nth expr 1)) ", "
+                                                  (fullform (nth expr 2)) "]")
+                                      :times (str "Times[" (fullform (nth expr 1)) ", "
+                                                  (fullform (nth expr 2)) "]")
+                                      :sin (str "Sin[" (fullform (nth expr 1)) "]")
+                                      :cos (str "Cos[" (fullform (nth expr 1)) "]")
+                                      ;; make sure we notice if something has gone wrong
+                                      (println "Throw[\"Unknown expression: " expr "\"]"))
+    (symbol? expr) (str expr)
+    (number? expr) (str expr)))


abstractions

abstractions

fatal: unable to access 'https://github.com/clojure-ml/cml.git/': The requested URL returned error: 403


[incomplete] Add the lambda lifting tests

fatal: unable to access 'https://github.com/arrdem/oxcart.git/': The requested URL returned error: 403


Add boot ns

Add boot ns

error: pathspec 'src/net/sekao/nightcode/boot.clj' did not match any file(s) known to git

--- src/net/sekao/nightcode/boot.clj
+++ src/net/sekao/nightcode/boot.clj
@@ -0,0 +1,6 @@
+(ns net.sekao.nightcode.boot
+  (:require [boot.core :as core]
+            [boot.task.built-in :as built-in]))
+
+(defn new-project [project-name]
+  (core/boot (built-in/speak)))


more printing

more printing

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/OttoJursch/sched-system.git/'


need to monkeypatch goog.writeScriptTag_

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/modnakasta/weasel.git/'


Add code generation tests for the defentity macro

error: pathspec 'src/test/workflo/macros/entity_test.clj' did not match any file(s) known to git

--- src/test/workflo/macros/entity_test.clj
+++ src/test/workflo/macros/entity_test.clj
@@ -0,0 +1,68 @@
+(ns workflo.macros.entity-test
+  (:require [clojure.spec :as s]
+            [clojure.test :refer [deftest is]]
+            [workflo.macros.entity :as e :refer [defentity]]))
+
+(deftest minimal-defentity
+  (is (= '(do
+            (def macros-user-schema map?)
+            (def macros-user-definition
+              {:schema pod/macros-user-schema}))
+         (macroexpand-1 `(defentity macros/user
+                           (~'schema ~'map?))))))
+
+(deftest defentity-with-validation
+  (is (= '(do
+            (def macros-user-validation
+              (s/keys :req [:foo/bar]
+                      :opt [:bar/baz]))
+            (def macros-user-schema map?)
+            (def macros-user-definition
+              {:schema pod/macros-user-schema
+               :validation pod/macros-user-validation}))
+         (macroexpand-1 `(defentity macros/user
+                           (~'validation
+                             (~'s/keys :req [:foo/bar]
+                                       :opt [:bar/baz]))
+                           (~'schema ~'map?))))))
+
+(deftest defentity-with-auth
+  (is (= '(do
+            (defn macros-user-auth
+              [{:keys [foo bar]}]
+              (println foo bar))
+            (def macros-user-auth-query
+              '[{:name foo :type :property}
+                {:name bar :type :property}])
+            (def macros-user-schema map?)
+            (def macros-user-definition
+              {:auth pod/macros-user-auth
+               :auth-query pod/macros-user-auth-query
+               :schema pod/macros-user-schema}))
+         (macroexpand-1 `(defentity macros/user
+                           ~'(auth [foo bar]
+                             (println foo bar))
+                           ~'(schema map?))))))
+
+(deftest defentity-with-auth-and-validation
+  (is (= '(do
+            (defn macros-user-auth
+              [{:keys [foo bar]}]
+              (println foo bar))
+            (def macros-user-auth-query
+              '[{:name foo :type :property}
+                {:name bar :type :property}])
+            (def macros-user-validation
+              (s/keys :req-un [::foo ::bar]))
+            (def macros-user-schema map?)
+            (def macros-user-definition
+              {:auth pod/macros-user-auth
+               :auth-query pod/macros-user-auth-query
+               :validation pod/macros-user-validation
+               :schema pod/macros-user-schema}))
+         (macroexpand-1 `(defentity macros/user
+                           ~'(auth [foo bar]
+                                   (println foo bar))
+                           ~'(validation
+                               (s/keys :req-un [::foo ::bar]))
+                           ~'(schema map?))))))


with-meta w/in let

with-meta w/in let

fatal: unable to access 'https://github.com/michaelsbradleyjr/transwarp.git/': The requested URL returned error: 403


beginnings of a proper "first test(drive)"

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/michaelsbradleyjr/transwarp.git/'


Comments and requires in datview

Comments and requires in datview

--- src/catalysis/client/datview.cljs
+++ src/catalysis/client/datview.cljs
@@ -3,7 +3,19 @@
   (:require-macros [reagent.ratom :refer [reaction]])
   (:require [posh.core :as posh]
             [reagent.core :as r]
-            [datascript.core :as d]))
+            [re-frame.core :as re-frame]
+            [re-com.core :as re-com]
+            [datsync.client.core :as datsync]
+            [posh.core :as posh]
+            [datascript.core :as d]
+            [goog.date.Date]
+            [cljs-time.core :as cljs-time]
+            [cljs-time.format]
+            [cljs-time.coerce]
+            [cljs.pprint :as pp]
+            [cljs.core.match :as match :refer-macros [match]]
+            [markdown.core :as md]))
+

 ;; ## Overview
@@ -38,22 +50,23 @@
 (def my-vbox-defaults
   {:style {:flex-flow "column wrap"}})

-(defn vbox
-  [& {:as kvs}]
-  (->> kvs
-       (u/deep-merge {:coll-merge (comp vec concat)} my-vbox-defaults)
-       seq
-       flatten
-       (apply re-com/v-box)))
-
-(defn hbox
-  [& {:as kvs}]
-  (->> kvs
-       (u/deep-merge {:coll-merge (comp vec concat)} my-vbox-defaults)
-       (u/deep-merge {:coll-merge (comp vec concat)} my-vbox-defaults)
-       seq
-       flatten
-       (apply re-com/h-box)))
+;; Might be nice to override these things
+;(defn vbox
+  ;[& {:as kvs}]
+  ;(->> kvs
+       ;(u/deep-merge {:coll-merge (comp vec concat)} my-vbox-defaults)
+       ;seq
+       ;flatten
+       ;(apply re-com/v-box)))
+
+;(defn hbox
+  ;[& {:as kvs}]
+  ;(->> kvs
+       ;(u/deep-merge {:coll-merge (comp vec concat)} my-vbox-defaults)
+       ;(u/deep-merge {:coll-merge (comp vec concat)} my-vbox-defaults)
+       ;seq
+       ;flatten
+       ;(apply re-com/h-box)))

 (defn debug-str


Added hadoop job namespace for common data model query

fatal: unable to access 'https://github.com/wri/forma-clj.git/': The requested URL returned error: 403


use make-%-key fns in parse-mutate-params

dee arr wye


don't allow for start > finish

don't allow for start > finish

fatal: unable to access 'https://github.com/wilkerlucio/youtube-looper.git/': The requested URL returned error: 403


change ant props to skewer-case

change ant props to skewer-case


bugfix two

bugfix two

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/m1dnight/clojbot.git/'


Added a simple task to clean out classes/ and lib/ in WEB-INF.

fatal: unable to access 'https://github.com/craygo/appengine-magic-2.git/': The requested URL returned error: 403


dissoc optional send-before

dissoc optional send-before

remote: Support for password authentication was removed on August 13, 2021.
remote: Please see https://docs.github.com/en/get-started/getting-started-with-git/about-remote-repositories#cloning-with-https-urls for information on currently recommended modes of authentication.
fatal: Authentication failed for 'https://github.com/democracyworks/scheduled-message-works.git/'


dissoc optional keys in `->tx-data`

dissoc optional keys in `->tx-data`


Use snapshots to clear chain before test

Before, deployer was used to clear test blockchain state
before each test. Deployer is now gone, replaced with
truffle. I found it much faster to use ganache snapshotting
before / after each test, than to call truffle migrate.

error: pathspec 'test/server/name_bazaar/utils.cljs' did not match any file(s) known to git

--- test/server/name_bazaar/utils.cljs
+++ test/server/name_bazaar/utils.cljs
@@ -0,0 +1,64 @@
+(ns server.name-bazaar.utils
+  (:require
+    [cljs.core.async :refer [<! go]]
+    [cljs.test :refer-macros [async]]
+    [cljs-time.coerce :refer [from-long]]
+    [cljs-web3-next.eth :as web3-eth]
+    [cljs-web3-next.evm :as web3-evm]
+    [cljs-web3-next.helpers :as web3-helpers]
+    [district.server.web3 :refer [web3]]
+    [district.shared.async-helpers :refer [promise->]]
+    [mount.core :as mount]
+    [taoensso.timbre :as log]))
+
+(def snapshot-id (atom ""))
+
+(def namehash (aget (js/require "eth-ens-namehash") "hash"))
+(def sha3 (comp (partial str "0x") (aget (js/require "js-sha3") "keccak_256")))
+
+
+(defn now []
+  (promise-> (web3-eth/get-block-number @web3)
+             #(web3-eth/get-block @web3 % false)
+             (fn [block]
+               (let [block (web3-helpers/js->cljkk block)]
+                 (from-long (* (:timestamp block) 1000))))))
+
+
+(defn before-test []
+  (async done
+    (go
+      (-> (mount/with-args
+            {:web3            {:url        "ws://127.0.0.1:8549"
+                               :on-online  #(log/warn "Ethereum node went online")
+                               :on-offline #(log/warn "Ethereum node went offline")}
+             :smart-contracts {:contracts-build-path "./resources/public/contracts-build/"
+                               :contracts-var        #'name-bazaar.shared.smart-contracts/smart-contracts
+                               :auto-mining?         true}})
+          (mount/only [#'district.server.web3
+                       #'district.server.smart-contracts/smart-contracts])
+          (mount/start))
+      (let [id (<! (web3-evm/snapshot @web3))]
+        (swap! snapshot-id (fn [_] id)))
+      (done))))
+
+
+(defn after-test []
+  (async done
+    (go
+      ;; we'd like to use cljs-web3-next.evm/revert here, but it's broken now as:
+      ;; 1. evm_revert doesn't accept 0 arguments even if it should:
+      ;;    https://github.com/trufflesuite/ganache-cli/issues/672
+      ;; 2. evm_revert is a non-standard method not explicitly supported in web3js
+      ;; 3. there's a validator expecting by default any non-standard method to have 0 args
+      ;; so we need to go more low level
+      (js-invoke (aget @web3 "currentProvider")
+                 "send"
+                 (clj->js {:jsonrpc "2.0",
+                           :method "evm_revert",
+                           :params [@snapshot-id],
+                           :id 1})
+                 (fn [err _]
+                   (if err (throw (js/Error. "Error evm_revert-ing to snapshot" err)))
+                   (mount/stop)
+                   (js/setTimeout #(done) 500))))))