properly wait for executor shutdown

properly wait for executor shutdown

an exception in a compile task can otherwise destroy async tasks
still running (like flushing cache to disk) leading to corrupted
cache errors

--- src/main/shadow/cljs/devtools/server/common.clj
+++ src/main/shadow/cljs/devtools/server/common.clj
@@ -11,7 +11,7 @@
     [shadow.build.babel :as babel]
     [shadow.cljs.devtools.plugin-manager :as plugin-mgr])
   (:import (java.io ByteArrayOutputStream InputStream)
-           (java.util.concurrent Executors)))
+           (java.util.concurrent Executors TimeUnit)))

 (def app-config
   {:edn-reader
@@ -62,7 +62,10 @@
         (Executors/newFixedThreadPool n-threads)))
     :stop
     (fn [ex]
-      (.shutdown ex))}
+      (.shutdown ex)
+      (try
+        (.awaitTermination ex 10 TimeUnit/SECONDS)
+        (catch InterruptedException ex)))}

    :classpath
    {:depends-on [:cache-root]


Add boot cmd to logging info

Add boot cmd to logging info

--- src/overtone/sc/machinery/server/connection.clj
+++ src/overtone/sc/machinery/server/connection.clj
@@ -211,7 +211,7 @@
   STDOUT for log messages."
   ([cmd] (external-booter cmd "."))
   ([cmd working-dir]
-     (log/debug "booting external audio server...")
+     (log/info "Booting external audio server with cmd: " (seq cmd) ", and working directory: " working-dir)
      (let [working-dir (File. working-dir)
            proc        (.exec (Runtime/getRuntime) cmd nil working-dir)
            in-stream   (BufferedInputStream. (.getInputStream proc))


Some cleanup from port to real rendering

--- web-client/test/test_burgerboard/huh.cljs
+++ web-client/test/test_burgerboard/huh.cljs
@@ -105,13 +105,16 @@
     )
   )

-(defn in [component selector]
-  (let [component-node (.getDOMNode component)]
-    (if (= selector "")
-      component-node
-      (.querySelector component-node selector)
-      )
-    )
+(defn in
+  ([component] (om/get-node component))
+  ([component selector]
+     (let [component-node (om/get-node component)]
+       (if (= selector "")
+         component-node
+         (.querySelector component-node selector)
+         )
+       )
+     )
   )

 (defn -extract-m [tests]
@@ -145,7 +148,7 @@

 (defn tag [expected-tag & tests]
   (fn -tag-pred [component]
-    (let [component-node (.getDOMNode component)
+    (let [component-node (om/get-node component)
           actual (tag-name component-node)]
       (if-not (= expected-tag actual)
         {:msg "Tag does not match" :expected expected-tag :actual actual}
@@ -214,7 +217,7 @@

 (defn with-text [text]
   (fn -text-pred [component]
-    (let [component (.getDOMNode component)
+    (let [component (om/get-node component)
           actual-text (.-textContent component)]
       (if (= text actual-text)
         true
@@ -255,7 +258,7 @@

 (defn with-class [class-name]
   (fn -with-class-pred [component]
-    (let [component (.getDOMNode component)
+    (let [component (om/get-node component)
           actual (.. component -className)]
       (if (.contains (.. component -classList) class-name)
         true
@@ -267,7 +270,7 @@

 (defn with-attr [attr-name attr-value]
   (fn -with-attr-pred [component]
-    (let [component (.getDOMNode component)
+    (let [component (om/get-node component)
           actual-value (.getAttribute component attr-name)]
       (if (= attr-value actual-value)
         true


name change to web-routes test

name change to web-routes test

--- test/text_stream/handler_test.clj
+++ test/text_stream/handler_test.clj
@@ -3,7 +3,7 @@
             [ring.mock.request :as mock]
             [text-stream.handler :refer :all]))

-(deftest test-app
+(deftest web-routes
   (testing "main route"
     (let [response (app (mock/request :get "/"))]
       (is (= (:status response) 200))))


Continue migrating to `frob` functions

Continue migrating to `frob` functions

--- src/structural_typing/mechanics/m_canonical.clj
+++ src/structural_typing/mechanics/m_canonical.clj
@@ -10,30 +10,12 @@
 ;;; Utilities

-
-
-
-
-
-
-
-
-
-
-(defn- mkfn:passing-through [ignore-pred process-fn]
-  (fn [mixture]
-    (map #(if (ignore-pred %)
-            %
-            (process-fn %))
-         mixture)))
-
 ;;; Decompressers undo one or more types of compression allowed in compressed type descriptions.

-(defn dc:validate-description-types [mixture]
-  ( (mkfn:passing-through (some-fn map? sequential?)
-                          #(frob/boom "Types are described with maps or vectors: `%s` has `%s`"
-                                      mixture %))
-    mixture))
+(def dc:validate-description-types
+  (frob/mkst:validator (some-fn map? sequential?)
+                       #(frob/boom "Types are described with maps or vectors: `%s` has `%s`"
+                                   %1 %2)))

 (defn dc:expand-type-signifiers [type-map form]
   (let [do-one #(if (path/type-finder? %) (% type-map) %)]
@@ -66,23 +48,25 @@
                     path-ending-in-map?))

-(defn dc:flatten-maps [mixture]
+
+
+(def dc:flatten-maps
   (letfn [(do-one [kvs parent-path]
             (reduce (fn [so-far [path v]]
                       (when (and (sequential? path)
                                  (some map? path))
-                          (frob/boom "A path used as a map key may not itself contain a map: `%s`" path))
+                        (frob/boom "A path used as a map key may not itself contain a map: `%s`" path))
                       (let [extended-path (frob/adding-on parent-path path)]
                         (merge-with into so-far
-                                  (if (map? v)
-                                    (do-one v extended-path)
-                                    (hash-map extended-path (frob/force-vector v))))))
+                                    (if (map? v)
+                                      (do-one v extended-path)
+                                      (hash-map extended-path (frob/force-vector v))))))
                     {}
                     kvs))]
-    ( (mkfn:passing-through sequential? #(do-one % [])) mixture)))
+    (frob/mkst:x->y #(do-one % []) map?)))

 (def dc:required-paths->maps
-  (mkfn:passing-through map? #(hash-map % [pred/required-key])))
+  (frob/mkst:x->y #(hash-map % [pred/required-key]) (complement map?)))

 (defn dc:validate-all-are-flatmaps [xs]
   (doseq [x xs]
@@ -118,8 +102,9 @@
     (frob/boom "Canonicalize was called with no type descriptions. Type-map: %s" type-map))

   (->> condensed-type-descriptions
-       (dc:expand-type-signifiers type-map)
+       (dc:expand-type-signifiers type-map) ; comes first because signifiers can be top-level
        dc:validate-description-types
+
        dc:spread-collections-of-required-paths      ; affects vectors, skips maps
        dc:split-paths-ending-in-maps   ; produces new vectors and maps
        dc:flatten-maps                 ; affects maps


Untangled

Untangled

--- webui/src/webui/routes/api.clj
+++ webui/src/webui/routes/api.clj
@@ -47,16 +47,14 @@
   ; TODO handle nil or invalid data for spit
   ; TODO Do the yaml conversion in a functional way
 (.println System/out "")
- (info (yaml/generate-string
+ (def yaml-workspace (yaml/generate-string
     {:workspace (json/parse-string
              (get workspace :meta) true)
      :artifacts (map
              #(json/parse-string % true)
-             (get workspace :data))})))
-  ;(def workspace-data (get workspace :data))
-  ;(def workspace-meta (get workspace :meta))
-  ;(spit (str savedir "/workspace.sav") yaml-workspace); TODO dynamic filename
-  ;(yaml-response yaml-workspace))
+             (get workspace :data))}))
+  (spit (str savedir "/workspace.sav") yaml-workspace); TODO dynamic filename
+  (yaml-response yaml-workspace))

 (defn load-workspace []
   "Loads a workspace from YAML storage"


WIP RESFul API demo

WIP RESFul API demo

--- webui/src/webui/routes/api.clj
+++ webui/src/webui/routes/api.clj
@@ -56,15 +56,15 @@

 (defn update-workspace [id]
   "Update workspace in YAML storage"
-  (yaml-response "update-workspace stub"))
+  (yaml-response (str "update-workspace stub " id)))

 (defn delete-workspace [id]
   "Delete workspace from YAML storage"
-  (yaml-response "delete-workspace stub"))
+  (yaml-response (str "delete-workspace stub " id)))

 (defn run-workspace [id]
   "Run workspace"
-  (yaml-response "run-workspace stub"))
+  (yaml-response (str "run-workspace stub " id)))

 ;; API Definition
 ;;


Add more explanation to "Puzzle #1 -- Something about `quote`"

--- test/com/nomistech/clojure_the_language/c_300_language_lawyer_stuff/s_800_reborg_puzzlers_test.clj
+++ test/com/nomistech/clojure_the_language/c_300_language_lawyer_stuff/s_800_reborg_puzzlers_test.clj
@@ -26,7 +26,8 @@
   (fact "Explanation"
     (= ''hello
        '(quote hello)
-       (quote (quote hello)))
+       (quote (quote hello))
+       (list 'quote 'hello))
     => true))

 ;;;; ___________________________________________________________________________


[#1113] Create Postgis extension & use template0

--- backend/src/akvo/lumen/admin/add_tenant.clj
+++ backend/src/akvo/lumen/admin/add_tenant.clj
@@ -118,11 +118,13 @@
     (util/exec! db-uri
                 (str "CREATE DATABASE %1$s "
                      "WITH OWNER = %1$s "
-                     "TEMPLATE = template1 "
+                     "TEMPLATE = template0 "
                      "ENCODING = 'UTF8' "
                      "LC_COLLATE = 'en_US.UTF-8' "
                      "LC_CTYPE = 'en_US.UTF-8';")
                 tenant)
+    (util/exec! tenant-db-uri-with-superuser
+                "CREATE EXTENSION IF NOT EXISTS postgis WITH SCHEMA public;")
     (util/exec! tenant-db-uri-with-superuser
                 "CREATE EXTENSION IF NOT EXISTS btree_gist WITH SCHEMA public;")
     (util/exec! tenant-db-uri-with-superuser


[#1534] Removing "hidden" columns from dataset response

This was the logic before the last refactoring

--- backend/src/akvo/lumen/lib/dataset_impl.clj
+++ backend/src/akvo/lumen/lib/dataset_impl.clj
@@ -66,10 +66,9 @@
                                  {:as-arrays? true}))]
       (lib/ok
        (-> dataset
-           (select-keys [:columns :created :id :modified :status :title :transformations :updated])
+           (select-keys [:created :id :modified :status :title :transformations :updated])
            (rename-keys {:title :name})
-           (assoc :rows data)
-           (assoc :status "OK"))))
+           (assoc :rows data :columns columns :status "OK"))))
     (lib/not-found {:error "Not found"})))


check for namespace existence as a last ditch effort to see if a namespace should be loaded

this was added for the new code splitting behavior which doesn’t write
to goog.dependencies_.written when a module is loaded

--- support/src/figwheel/client/file_reloading.cljs
+++ support/src/figwheel/client/file_reloading.cljs
@@ -333,6 +333,9 @@
   (let [meta-pragmas (get @figwheel-meta-pragmas (name namespace))]
     (:figwheel-no-load meta-pragmas)))

+(defn ns-exists? [namespace]
+  (some? (reduce gobj/get goog.global (string/split (name namespace) "."))))
+
 (defn reload-file? [{:keys [namespace] :as file-msg}]
   (dev-assert (namespace-file-map? file-msg))
   (let [meta-pragmas (get @figwheel-meta-pragmas (name namespace))]
@@ -342,7 +345,8 @@
       (:figwheel-always meta-pragmas)
       (:figwheel-load meta-pragmas)
       ;; might want to use .-visited here
-      (provided? (name namespace))))))
+      (provided? (name namespace))
+      (ns-exists? namespace)))))

 (defn js-reload [{:keys [request-url namespace] :as file-msg} callback]
   (dev-assert (namespace-file-map? file-msg))


Cosmetic.

Cosmetic.

--- test/onyx/log/generative_peer_join.clj
+++ test/onyx/log/generative_peer_join.clj
@@ -23,6 +23,7 @@
 (def messenger (->DummyMessenger))

 (def job-1-id #uuid "f55c14f0-a847-42eb-81bb-0c0390a88608")
+
 (def job-1
   {:workflow [[:a :b] [:b :c]]
    :catalog [{:onyx/name :a
@@ -33,7 +34,7 @@
               :onyx/doc "Reads segments from a core.async channel"}

              {:onyx/name :b
-              :onyx/fn :onyx.log.round-robin-multi-job-test/my-inc
+              :onyx/fn :mock/fn
               :onyx/type :function
               :onyx/batch-size 20}

@@ -46,6 +47,7 @@
    :task-scheduler :onyx.task-scheduler/round-robin})

 (def job-2-id #uuid "5813d2ec-c486-4428-833d-e8373910ae14")
+
 (def job-2
   {:workflow [[:d :e] [:e :f]]
    :catalog [{:onyx/name :d
@@ -56,7 +58,7 @@
               :onyx/doc "Reads segments from a core.async channel"}

              {:onyx/name :e
-              :onyx/fn :onyx.log.round-robin-multi-job-test/my-inc
+              :onyx/fn :mock/fn
               :onyx/type :function
               :onyx/batch-size 20}

@@ -69,6 +71,7 @@
    :task-scheduler :onyx.task-scheduler/round-robin})

 (def job-3-id #uuid "58d199e8-4ea4-4afd-a112-945e97235924")
+
 (def job-3
   {:workflow [[:g :h] [:h :i]]
    :catalog [{:onyx/name :g
@@ -79,7 +82,7 @@
               :onyx/doc "Reads segments from a core.async channel"}

              {:onyx/name :h
-              :onyx/fn :onyx.log.round-robin-multi-job-test/my-inc
+              :onyx/fn :mock/fn
               :onyx/type :function
               :onyx/batch-size 20}

@@ -94,9 +97,9 @@
 (defn generate-join-entries [peer-ids]
   (zipmap peer-ids
           (map (fn [id] [{:fn :prepare-join-cluster
-                          :immediate? true
-                          :args {:peer-site (extensions/peer-site messenger)
-                                 :joiner id}}])
+                         :immediate? true
+                         :args {:peer-site (extensions/peer-site messenger)
+                                :joiner id}}])
                peer-ids)))

 (defn generate-peer-ids [n]
@@ -105,108 +108,108 @@

 (deftest greedy-allocation
   (checking
-    "Checking greedy allocation causes all peers to be allocated to one of two jobs"
-    1000
-    [{:keys [replica log peer-choices]}
-     (log-gen/apply-entries-gen
-       (gen/return
-         {:replica {:job-scheduler :onyx.job-scheduler/greedy
-                    :messaging {:onyx.messaging/impl :dummy-messenger}}
-          :message-id 0
-          :entries (assoc
-                     (generate-join-entries (generate-peer-ids 8))
-                     :job-1 [(api/create-submit-job-entry job-1-id
-                                                          peer-config
-                                                          job-1
-                                                          (planning/discover-tasks (:catalog job-1) (:workflow job-1)))]
-                     :job-2 [(api/create-submit-job-entry job-2-id
-                                                          peer-config
-                                                          job-2
-                                                          (planning/discover-tasks (:catalog job-2) (:workflow job-2)))])
-          :log []
-          :peer-choices []}))]
-
-    (let [allocs (vector (apply + (map count (vals (get (:allocations replica) job-1-id))))
-                         (apply + (map count (vals (get (:allocations replica) job-2-id)))))]
-      (is
-        (or (= allocs [0 8])
-            (= allocs [8 0]))))))
+   "Checking greedy allocation causes all peers to be allocated to one of two jobs"
+   1000
+   [{:keys [replica log peer-choices]}
+    (log-gen/apply-entries-gen
+     (gen/return
+      {:replica {:job-scheduler :onyx.job-scheduler/greedy
+                 :messaging {:onyx.messaging/impl :dummy-messenger}}
+       :message-id 0
+       :entries (assoc
+                    (generate-join-entries (generate-peer-ids 8))
+                  :job-1 [(api/create-submit-job-entry job-1-id
+                                                       peer-config
+                                                       job-1
+                                                       (planning/discover-tasks (:catalog job-1) (:workflow job-1)))]
+                  :job-2 [(api/create-submit-job-entry job-2-id
+                                                       peer-config
+                                                       job-2
+                                                       (planning/discover-tasks (:catalog job-2) (:workflow job-2)))])
+       :log []
+       :peer-choices []}))]
+
+   (let [allocs (vector (apply + (map count (vals (get (:allocations replica) job-1-id))))
+                        (apply + (map count (vals (get (:allocations replica) job-2-id)))))]
+     (is
+      (or (= allocs [0 8])
+          (= allocs [8 0]))))))

 (deftest greedy-allocation-reallocated
   (checking
-    "Checking peers reallocated to other job when killed"
-    1000
-    [{:keys [replica log peer-choices]}
-     (log-gen/apply-entries-gen
-       (gen/return
-         {:replica {:job-scheduler :onyx.job-scheduler/greedy
-                    :messaging {:onyx.messaging/impl :dummy-messenger}}
-          :message-id 0
-          :entries (assoc (generate-join-entries (generate-peer-ids 8))
-                          :job-1 [(api/create-submit-job-entry job-1-id
-                                                               peer-config
-                                                               job-1
-                                                               (planning/discover-tasks (:catalog job-1) (:workflow job-1)))]
-                          :job-2 [(api/create-submit-job-entry job-2-id
-                                                               peer-config
-                                                               job-2
-                                                               (planning/discover-tasks (:catalog job-2) (:workflow job-2)))
-                                  {:fn :kill-job :args {:job job-2-id}}])
-          :log []
-          :peer-choices []}))]
-    (is (= (apply + (map count (vals (get (:allocations replica) job-1-id)))) 8))
-    (is (= (apply + (map count (vals (get (:allocations replica) job-2-id)))) 0))))
+   "Checking peers reallocated to other job when killed"
+   1000
+   [{:keys [replica log peer-choices]}
+    (log-gen/apply-entries-gen
+     (gen/return
+      {:replica {:job-scheduler :onyx.job-scheduler/greedy
+                 :messaging {:onyx.messaging/impl :dummy-messenger}}
+       :message-id 0
+       :entries (assoc (generate-join-entries (generate-peer-ids 8))
+                  :job-1 [(api/create-submit-job-entry job-1-id
+                                                       peer-config
+                                                       job-1
+                                                       (planning/discover-tasks (:catalog job-1) (:workflow job-1)))]
+                  :job-2 [(api/create-submit-job-entry job-2-id
+                                                       peer-config
+                                                       job-2
+                                                       (planning/discover-tasks (:catalog job-2) (:workflow job-2)))
+                          {:fn :kill-job :args {:job job-2-id}}])
+       :log []
+       :peer-choices []}))]
+   (is (= (apply + (map count (vals (get (:allocations replica) job-1-id)))) 8))
+   (is (= (apply + (map count (vals (get (:allocations replica) job-2-id)))) 0))))

 (deftest round-robin-task-balancing
   (checking
-    "Checking round robin allocation causes peers to be evenly over tasks"
-    1000
-    [{:keys [replica log peer-choices]}
-     (log-gen/apply-entries-gen
-       (gen/return
-         {:replica {:job-scheduler :onyx.job-scheduler/round-robin
-                    :messaging {:onyx.messaging/impl :dummy-messenger}}
-          :message-id 0
-          :entries (assoc (generate-join-entries (generate-peer-ids 6))
-                          :job-1 [(api/create-submit-job-entry job-1-id
-                                                               peer-config
-                                                               job-1
-                                                               (planning/discover-tasks (:catalog job-1) (:workflow job-1)))]
-                          :job-2 [(api/create-submit-job-entry job-2-id
-                                                               peer-config
-                                                               job-2
-                                                               (planning/discover-tasks (:catalog job-2) (:workflow job-2)))])
-          :log []
-          :peer-choices []}))]
-    (is (= (map count (vals (get (:allocations replica) job-1-id))) [1 1 1]))
-    (is (= (map count (vals (get (:allocations replica) job-2-id))) [1 1 1]))))
+   "Checking round robin allocation causes peers to be evenly over tasks"
+   1000
+   [{:keys [replica log peer-choices]}
+    (log-gen/apply-entries-gen
+     (gen/return
+      {:replica {:job-scheduler :onyx.job-scheduler/round-robin
+                 :messaging {:onyx.messaging/impl :dummy-messenger}}
+       :message-id 0
+       :entries (assoc (generate-join-entries (generate-peer-ids 6))
+                  :job-1 [(api/create-submit-job-entry job-1-id
+                                                       peer-config
+                                                       job-1
+                                                       (planning/discover-tasks (:catalog job-1) (:workflow job-1)))]
+                  :job-2 [(api/create-submit-job-entry job-2-id
+                                                       peer-config
+                                                       job-2
+                                                       (planning/discover-tasks (:catalog job-2) (:workflow job-2)))])
+       :log []
+       :peer-choices []}))]
+   (is (= (map count (vals (get (:allocations replica) job-1-id))) [1 1 1]))
+   (is (= (map count (vals (get (:allocations replica) job-2-id))) [1 1 1]))))

 (deftest round-robin-allocations
   (checking
-    "Checking round robin allocation causes peers to be evenly split"
-    1000
-    [{:keys [replica log peer-choices]}
-     (log-gen/apply-entries-gen
-       (gen/return
-         {:replica {:job-scheduler :onyx.job-scheduler/round-robin
-                    :messaging {:onyx.messaging/impl :dummy-messenger}}
-          :message-id 0
-          :entries (assoc (generate-join-entries (generate-peer-ids 12))
-                          :job-1 [(api/create-submit-job-entry job-1-id
-                                                               peer-config
-                                                               job-1
-                                                               (planning/discover-tasks (:catalog job-1) (:workflow job-1)))]
-                          :job-2 [(api/create-submit-job-entry job-2-id
-                                                               peer-config
-                                                               job-2
-                                                               (planning/discover-tasks (:catalog job-2) (:workflow job-2)))]
-                          :job-3 [(api/create-submit-job-entry job-3-id
-                                                               peer-config
-                                                               job-3
-                                                               (planning/discover-tasks (:catalog job-3) (:workflow job-3)))
-                                  {:fn :kill-job :args {:job job-3-id}}])
-          :log []
-          :peer-choices []}))]
-    (is (= (map count (vals (get (:allocations replica) job-1-id))) [1 1 1]))
-    (is (= (map count (vals (get (:allocations replica) job-2-id))) [1 1 1]))
-    (is (= (map count (vals (get (:allocations replica) job-3-id))) []))))
+   "Checking round robin allocation causes peers to be evenly split"
+   1000
+   [{:keys [replica log peer-choices]}
+    (log-gen/apply-entries-gen
+     (gen/return
+      {:replica {:job-scheduler :onyx.job-scheduler/round-robin
+                 :messaging {:onyx.messaging/impl :dummy-messenger}}
+       :message-id 0
+       :entries (assoc (generate-join-entries (generate-peer-ids 12))
+                  :job-1 [(api/create-submit-job-entry job-1-id
+                                                       peer-config
+                                                       job-1
+                                                       (planning/discover-tasks (:catalog job-1) (:workflow job-1)))]
+                  :job-2 [(api/create-submit-job-entry job-2-id
+                                                       peer-config
+                                                       job-2
+                                                       (planning/discover-tasks (:catalog job-2) (:workflow job-2)))]
+                  :job-3 [(api/create-submit-job-entry job-3-id
+                                                       peer-config
+                                                       job-3
+                                                       (planning/discover-tasks (:catalog job-3) (:workflow job-3)))
+                          {:fn :kill-job :args {:job job-3-id}}])
+       :log []
+       :peer-choices []}))]
+   (is (= (map count (vals (get (:allocations replica) job-1-id))) [1 1 1]))
+   (is (= (map count (vals (get (:allocations replica) job-2-id))) [1 1 1]))
+   (is (= (map count (vals (get (:allocations replica) job-3-id))) []))))


Added doc summaries to each endpoint.

Added doc summaries to each endpoint.

--- src/org/ocremix/api/routes.clj
+++ src/org/ocremix/api/routes.clj
@@ -28,6 +28,7 @@

 (defroutes* api-routes
   (GET* "/remixes" []
+        :summary      "List all remixes."
         :query-params [{sort-order :- String "id"}
                        {sort-dir :- String "DESC"}
                        {limit :- Long 50}
@@ -35,9 +36,11 @@
         (service/trap #(remixes/get-remixes (->params-map sort-order sort-dir limit offset))))

   (GET* "/remixes/:remix-id" [remix-id]
-       (service/trap #(remix/get-remix remix-id)))
+        :summary "Get a single remix."
+        (service/trap #(remix/get-remix remix-id)))

   (GET* "/songs" []
+        :summary      "List all songs."
         :query-params [{sort-order :- String "name"}
                        {sort-dir :- String "ASC"}
                        {limit :- Long 50}
@@ -45,14 +48,17 @@
         (service/trap #(songs/get-songs (->params-map sort-order sort-dir limit offset))))

   (GET* "/songs/:song-id" [song-id]
+        :summary     "Get a single song."
         :path-params [song-id :- Long]
-       (service/trap #(song/get-song song-id)))
+        (service/trap #(song/get-song song-id)))

   (GET* "/songs/:song-id/remixes" [song-id]
+        :summary     "Get remixes for a single song."
         :path-params [song-id :- Long]
-       (service/trap #(song/get-song-remixes song-id)))
+        (service/trap #(song/get-song-remixes song-id)))

   (GET* "/games" []
+        :summary      "List all games."
         :query-params [{sort-order :- String "name"}
                        {sort-dir :- String "ASC"}
                        {limit :- Long 50}
@@ -60,22 +66,27 @@
         (service/trap #(games/get-games (->params-map sort-order sort-dir limit offset))))

   (GET* "/games/:game-id" [game-id]
-        :path-params [game-id :- Long]
-       (service/trap #(game/get-game game-id)))
+        :summary     "Get a single game."
+        :path-params [game-id :- Long]
+        (service/trap #(game/get-game game-id)))

   (GET* "/games/:game-id/songs" [game-id]
-        :path-params [game-id :- Long]
-       (service/trap #(game/get-game-songs game-id)))
+        :summary     "Get songs for a single game."
+        :path-params [game-id :- Long]
+        (service/trap #(game/get-game-songs game-id)))

   (GET* "/games/:game-id/albums" [game-id]
-        :path-params [game-id :- Long]
-       (service/trap #(game/get-game-albums game-id)))
+        :summary     "Get albums for a single game."
+        :path-params [game-id :- Long]
+        (service/trap #(game/get-game-albums game-id)))

   (GET* "/games/:game-id/remixes" [game-id]
-        :path-params [game-id :- Long]
-       (service/trap #(game/get-game-remixes game-id)))
+        :summary     "Get remixes for a single game."
+        :path-params [game-id :- Long]
+        (service/trap #(game/get-game-remixes game-id)))

   (GET* "/albums" []
+        :summary      "List all albums."
         :query-params [{sort-order :- String "release_date"}
                        {sort-dir :- String "DESC"}
                        {limit :- Long 50}
@@ -83,18 +94,22 @@
         (service/trap #(albums/get-albums (->params-map sort-order sort-dir limit offset))))

   (GET* "/albums/:album-id" [album-id]
+        :summary     "Get a single album."
         :path-params [album-id :- Long]
-       (service/trap #(album/get-album album-id)))
+        (service/trap #(album/get-album album-id)))

   (GET* "/albums/:album-id/composers" [album-id]
+        :summary     "Get composers for a single album."
         :path-params [album-id :- Long]
-       (service/trap #(album/get-album-composers album-id)))
+        (service/trap #(album/get-album-composers album-id)))

   (GET* "/albums/:album-id/remixes" [album-id]
+        :summary     "Get remixes for a single album."
         :path-params [album-id :- Long]
-       (service/trap #(album/get-album-remixes album-id)))
+        (service/trap #(album/get-album-remixes album-id)))

   (GET* "/artists" []
+        :summary      "List all artists."
         :query-params [{sort-order :- String "name"}
                        {sort-dir :- String "ASC"}
                        {limit :- Long 50}
@@ -102,22 +117,27 @@
         (service/trap #(artists/get-artists (->params-map sort-order sort-dir limit offset))))

   (GET* "/artists/:artist-id" [artist-id]
-        :path-params [artist-id :- Long]
-       (service/trap #(artist/get-artist artist-id)))
+        :summary     "Get a single artist."
+        :path-params [artist-id :- Long]
+        (service/trap #(artist/get-artist artist-id)))

   (GET* "/artists/:artist-id/games" [artist-id]
-        :path-params [artist-id :- Long]
-       (service/trap #(artist/get-artist-games artist-id)))
+        :summary     "Get games for a single artist."
+        :path-params [artist-id :- Long]
+        (service/trap #(artist/get-artist-games artist-id)))

   (GET* "/artists/:artist-id/albums" [artist-id]
-        :path-params [artist-id :- Long]
-       (service/trap #(artist/get-artist-albums artist-id)))
+        :summary     "Get albums for a single artist."
+        :path-params [artist-id :- Long]
+        (service/trap #(artist/get-artist-albums artist-id)))

   (GET* "/artists/:artist-id/remixes" [artist-id]
-        :path-params [artist-id :- Long]
-       (service/trap #(artist/get-artist-remixes artist-id)))
+        :summary     "Get remixes for a single artist."
+        :path-params [artist-id :- Long]
+        (service/trap #(artist/get-artist-remixes artist-id)))

   (GET* "/systems" []
+        :summary      "List all systems."
         :query-params [{sort-order :- String "name"}
                        {sort-dir :- String "ASC"}
                        {limit :- Long 50}
@@ -125,21 +145,27 @@
         (service/trap #(systems/get-systems (->params-map sort-order sort-dir limit offset))))

   (GET* "/systems/:system-id" [system-id]
-       (service/trap #(system/get-system system-id)))
+        :summary      "Get a single system."
+        (service/trap #(system/get-system system-id)))

   (GET* "/systems/:system-id/games" [system-id]
-       (service/trap #(system/get-system-games system-id)))
+        :summary      "Get games for a single system."
+        (service/trap #(system/get-system-games system-id)))

   (GET* "/systems/:system-id/composers" [system-id]
-       (service/trap #(system/get-system-composers system-id)))
+        :summary      "Get composers for a single system."
+        (service/trap #(system/get-system-composers system-id)))

   (GET* "/systems/:system-id/albums" [system-id]
-       (service/trap #(system/get-system-albums system-id)))
+        :summary      "Get albums for a single system."
+        (service/trap #(system/get-system-albums system-id)))

   (GET* "/systems/:system-id/remixes" [system-id]
-       (service/trap #(system/get-system-remixes system-id)))
+        :summary      "Get remixes for a single system."
+        (service/trap #(system/get-system-remixes system-id)))

   (GET* "/orgs" []
+        :summary      "List all organizations."
         :query-params [{sort-order :- String "name"}
                        {sort-dir :- String "ASC"}
                        {limit :- Long 50}
@@ -148,30 +174,37 @@
                         (->params-map sort-order sort-dir limit offset))))

   (GET* "/orgs/:organization-id" [organization-id]
-        :path-params [organization-id :- Long]
-       (service/trap #(organization/get-organization organization-id)))
+        :summary     "Get a single organization."
+        :path-params [organization-id :- Long]
+        (service/trap #(organization/get-organization organization-id)))

   (GET* "/orgs/:organization-id/systems" [organization-id]
-        :path-params [organization-id :- Long]
-       (service/trap #(organization/get-organization-systems organization-id)))
+        :summary     "Get systems for a single organization."
+        :path-params [organization-id :- Long]
+        (service/trap #(organization/get-organization-systems organization-id)))

   (GET* "/orgs/:organization-id/games" [organization-id]
-        :path-params [organization-id :- Long]
-       (service/trap #(organization/get-organization-games organization-id)))
+        :summary     "Get games for a single organization."
+        :path-params [organization-id :- Long]
+        (service/trap #(organization/get-organization-games organization-id)))

   (GET* "/orgs/:organization-id/composers" [organization-id]
-        :path-params [organization-id :- Long]
-       (service/trap #(organization/get-organization-composers organization-id)))
+        :summary     "Get composers for a single organization."
+        :path-params [organization-id :- Long]
+        (service/trap #(organization/get-organization-composers organization-id)))

   (GET* "/orgs/:organization-id/albums" [organization-id]
-        :path-params [organization-id :- Long]
-       (service/trap #(organization/get-organization-albums organization-id)))
+        :summary     "Get albums for a single organization."
+        :path-params [organization-id :- Long]
+        (service/trap #(organization/get-organization-albums organization-id)))

   (GET* "/orgs/:organization-id/remixes" [organization-id]
-        :path-params [organization-id :- Long]
-       (service/trap #(organization/get-organization-remixes organization-id)))
+        :summary     "Get remixes for a single organization."
+        :path-params [organization-id :- Long]
+        (service/trap #(organization/get-organization-remixes organization-id)))

   (GET* "/chiptunes" []
+        :summary      "List all chiptunes."
         :query-params [{sort-order :- String "name"}
                        {sort-dir :- String "ASC"}
                        {limit :- Long 50}
@@ -179,8 +212,9 @@
         (service/trap #(chiptunes/get-chiptunes (->params-map sort-order sort-dir limit offset))))

   (GET* "/chiptunes/:chiptune-id" [chiptune-id]
+        :summary     "Get a single chiptune."
         :path-params [chiptune-id :- Long]
-       (service/trap #(chiptune/get-chiptune chiptune-id)))
+        (service/trap #(chiptune/get-chiptune chiptune-id)))

   (route/not-found (service/unrecognized-path-response)))


Remove try/catch around mock-run-monad + fix check-mocks-empty in cljs.

--- src/active/clojure/mock_monad.cljc
+++ src/active/clojure/mock_monad.cljc
@@ -43,9 +43,6 @@

 ;; clojure-check assertions as a monadic command:
 ;; NOTE Don't use this in CLJS
-(defmacro m-is [& forms]
-  `(monad/return (is ~@forms)))
-
 (def check-mocks-empty
   (monad/monadic
    [mocks (monad/get-state-component ::mocks)]
@@ -53,8 +50,8 @@
    (if-cljs
     ;; We must be careful here to call the function version in CLJS
     ;; (otherwise, it expands to clojure.test/is and not cljs.test/is)
-     (monad/return (is (empty? rmocks) "Did not see expected mocked commands."))
-     (m-is (empty? rmocks) "Did not see expected mocked commands."))
+     (monad/return (cljs.test/is (empty? rmocks) "Did not see expected mocked commands."))
+     (monad/return (clojure.test/is (empty? rmocks) "Did not see expected mocked commands.")))
     (monad/return nil)))

 (defn mock-effect
@@ -82,18 +79,14 @@
   ([mocks m]
    (mock-execute-monad (monad/null-monad-command-config {} {}) mocks m))
   ([command-config mocks m]
-   (try (monad/run-free-reader-state-exception
-         (monad/combine-monad-command-configs command-config
-                                              (mock-commands mocks))
-         (monad/monadic
-          [res m]
-          ;; check that mock stack is empty at 'end'
-          check-mocks-empty
-          (monad/return res)))
-        #?(:clj (catch Exception e
-                  (println "e =" e))
-           :cljs (catch js/Error e
-                   (println "e =" e))))))
+   (monad/run-free-reader-state-exception
+    (monad/combine-monad-command-configs command-config
+                                         (mock-commands mocks))
+    (monad/monadic
+     [res m]
+     ;; check that mock stack is empty at 'end'
+     check-mocks-empty
+     (monad/return res)))))

 ;; FIXME This should be renamed to `mock-execute-monad`
 (defn mock-run-monad
@@ -101,14 +94,10 @@
    `mocks` should be a sequence, whose values can be created by the
   `mock`, `mock-result` or `mock-effect` and other functions above, and are
   expected to appear in that order while executing `m`."
+  ([mocks m]
+   (mock-run-monad (monad/null-monad-command-config {} {}) mocks m))
   ([command-config mocks m]
-   (try (first (mock-execute-monad command-config mocks m))
-        #?(:clj (catch Exception e
-                  (println "e =" e))
-           :cljs (catch js/Error e
-                   (println "e =" e)))))
-  ([mocks m]
-   (mock-run-monad (monad/null-monad-command-config {} {}) mocks m)))
+   (first (mock-execute-monad command-config mocks m))))

 (defn with-mock-run-monad
   "Immediately calls f with a function of two arguments, `mocks` and


(count)

(count)

--- src/babel/francais/morphology.cljc
+++ src/babel/francais/morphology.cljc
@@ -54,7 +54,7 @@
                                            (get lexicon lex))))))))
                  regular-patterns))]
     (if (not (empty? retval))
-      (log/info (str "analyze '" surface-form "': " (string/join "," (map strip-refs retval))))
+      (log/info (str "analyze '" surface-form "': count=" (count retval) ";" (string/join "," (map strip-refs retval))))
       (log/warn (str " analyze: could not analyze surface-form: " surface-form)))
     retval))


Decoding

Decoding

--- src/clj/algorithms_clj/huffman.clj
+++ src/clj/algorithms_clj/huffman.clj
@@ -81,12 +81,24 @@
 ;; Decoding
 ;; -----------------------------------------------------------

-#_(defn decode-bits
-   [huffman-tree bits]
-   (cond
-     (= 1 (count huffman-tree)) []
-     )
-   )
+(defn ^:private decode-one
+  [{:keys [values lhs rhs]} bits]
+  (cond
+    (= 1 (count values)) [(first values) bits]
+    (= 0 (first bits)) (recur lhs (rest bits))
+    (= 1 (first bits)) (recur rhs (rest bits))
+    ))
+
+(defn ^:private decode-bits
+  [huffman-tree inputs]
+  (loop [bits inputs
+         result []]
+    (if (empty? bits)
+      result
+      (let [[c tail-bits] (decode-one huffman-tree bits)]
+        (recur tail-bits (conj result c))
+        ))
+    ))

 ;; -----------------------------------------------------------
@@ -98,7 +110,9 @@

 (defn tests []
   (prn (encode-with (tree->decoder t) [:a :b]))
-  (prn (encode [:a :b])))
+  (prn (encode [:a :b]))
+  (prn (decode-bits t [0 1 0 0 1 1]))
+  )


Soren's fix for get with Thrift-serialized keys

--- src/clj/elephantdb/keyval/core.clj
+++ src/clj/elephantdb/keyval/core.clj
@@ -206,7 +206,10 @@
         (multi-get get-fn
                    database
                    domain-name
-                   (map (fn [^ByteBuffer x] (.array x))
+                   (map (fn [^ByteBuffer x]
+                          (let [ret (byte-array (.remaining x))]
+                            (.get x ret)
+                            ret))
                         key-seq))))

     (multiGetInt [this domain-name key-seq]
@@ -226,8 +229,10 @@

     (get [this domain-name key]
       (thrift/assert-domain database domain-name)
-      (let [get-fn (kv-get-fn this domain-name database)]
-        (first (multi-get get-fn database domain-name [(.array key)]))))
+      (let [get-fn (kv-get-fn this domain-name database)
+            ret (byte-array (.remaining key))]
+        (.get key ret)
+        (first (multi-get get-fn database domain-name [ret]))))

     (getInt [this domain-name key]
       (thrift/assert-domain database domain-name)


Much better tag search results inc tag pairs

--- src/clj/sbsk/components/search.clj
+++ src/clj/sbsk/components/search.clj
@@ -53,13 +53,13 @@
           (collect-pairs-of [tag record]
             (let [rtags (get-tags record)]
               (when (some #{tag} rtags)
-                (do (println tag "/" rtags)
-                    (remove #{tag} (get-tags record))))))]
+                (remove #{tag} (get-tags record)))))]
     (log/debug "Collecting tag pairs..." (count tags) "x" (count records))
     (reset! tag-pair-index
             (reduce #(assoc %1 %2
-                            (reduce concat []
-                                    (mapv (partial collect-pairs-of %2) records)))
+                            (set (reduce concat
+                                         []
+                                         (mapv (partial collect-pairs-of %2) records))))
                     {} tags))))

 (defn reload-index
@@ -93,6 +93,11 @@
     (collect-tag-pairs! tag-pair-index @tag-index @records)
     (log/info "Index ready")))

+(defn index-of-compare
+  [x]
+  (fn [a b]
+    (.compareTo (.indexOf a x) (.indexOf b x))))
+
 (defn do-search
   [{:keys [id] :as qs} index records tag-index tag-pair-index]
   (let [query (url-decode (:query qs))
@@ -109,7 +114,14 @@
                       (get @records rid)) results))
             ;;
             (not (clojure.string/blank? tag-query))
-            (sort (filter #(.contains % tag-query) @tag-index)))
+            (let [tag-results (filter #(.contains % tag-query) @tag-index)]
+              (if (= 1 (count tag-results))
+                (let [tag (first tag-results)]
+                  (sort (concat tag-results (map #(str tag ", " %)
+                                                 (get @tag-pair-index tag)))))
+                (->> tag-results
+                     (sort)
+                     (sort (index-of-compare tag-query))))))
       [])))

 (defn search-handler


Move actual processing of mouse and keyboard events out of the handlers - these now just pass the events through to the main messages channel

--- src/cljs/mandelbrot_cljs/core.cljs
+++ src/cljs/mandelbrot_cljs/core.cljs
@@ -120,6 +120,14 @@

         :log (.log js/console (:message body))

+        :keydown (handle-keydown! messages body)
+
+        :mousedown (swap! app-state assoc :mousedown-event body)
+
+        :mouseup (handle-mouseup messages body)
+
+        :mousemove (handle-mousemove messages body)
+
         :undo (undo! messages)

         :open-as-png (open-as-png! body)
@@ -191,13 +199,13 @@

     (set! (.-onresize js/window) (fn [] (put! messages [:render])))

-    (set! (.-onmousedown (:overlay-canvas @app-state)) (fn [e] (swap! app-state assoc :mousedown-event e)))
-
-    (set! (.-onmousemove (:overlay-canvas @app-state)) (partial handle-mousemove messages))
-
-    (set! (.-onmouseup (:overlay-canvas @app-state)) (partial handle-mouseup messages))
-
-    (set! (.-onkeydown js/window) (partial handle-keydown! messages))
+    (set! (.-onmousedown (:overlay-canvas @app-state)) #(put! messages [:mousedown %]))
+
+    (set! (.-onmousemove (:overlay-canvas @app-state)) #(put! messages [:mousemove %]))
+
+    (set! (.-onmouseup (:overlay-canvas @app-state)) #(put! messages [:mouseup %]))
+
+    (set! (.-onkeydown js/window) #(put! messages [:keydown %]))

     (set! (.-onclick (.getElementById js/document "undo")) #(put! messages [:undo]))


cleanup

cleanup

--- src/clojure/zensols/dataset/db.clj
+++ src/clojure/zensols/dataset/db.clj
@@ -45,13 +45,7 @@

 (def ^:private dataset-key :dataset)

-(def ^:private es-class-label-key
-  ;(->> [dataset-key class-label-key] (map name) (s/join "."))
-  class-label-key
-  )
-
-;; (def ^:private es-instance-key
-;;   (-> dataset-key name (str ".instance")))
+(def ^:private es-class-label-key class-label-key)

 (def ^:private id-state-key "id-state")

@@ -236,17 +230,13 @@
 (defn- persist-id-state [id-state]
   (use-connection
     (with-context [stats-context]
-      ;(es/put-document id-state-key {stat-info-key id-state})
-      (es/put-document id-state-key id-state)
-      ))
+      (es/put-document id-state-key id-state)))
   id-state)

 (defn- unpersist-id-state []
   (use-connection
     (with-context [stats-context]
-      ;(stat-info-key (es/document-by-id id-state-key))
-      (es/document-by-id id-state-key)
-      )))
+      (es/document-by-id id-state-key))))

 (defn- db-ids
   "Get IDs straight from the DB."


[#472] Fix flow import test

[#472] Fix flow import test

--- backend/test/akvo/lumen/import/flow_test.clj
+++ backend/test/akvo/lumen/import/flow_test.clj
@@ -1,8 +1,8 @@
 (ns akvo.lumen.import.flow-test
-  (:require [clojure.test :refer :all]
+  (:require [akvo.lumen.import.flow :refer :all]
+            [clojure.edn :as edn]
             [clojure.java.io :as io]
-            [clojure.edn :as edn]
-            [akvo.lumen.import.flow :refer :all]))
+            [clojure.test :refer :all]))

 (comment
   (require 'clojure.tools.namespace.repl)
@@ -58,11 +58,11 @@
             {:title "Longitude", :type "number", :column-name "c3"}
             {:title "Submitter", :type "text", :column-name "c4"}
             {:title "Submitted at", :type "date", :column-name "c5"}
-            {:type "object", :title "Geoshape", :column-name "c6"}
-            {:type "object", :title "Barcode", :column-name "c7"}
+            {:type "text", :title "Geoshape", :column-name "c6"}
+            {:type "text", :title "Barcode", :column-name "c7"}
             {:type "date", :title "Date", :column-name "c8"}
-            {:type "object", :title "Video", :column-name "c9"}
-            {:type "object", :title "Photo", :column-name "c10"}
+            {:type "text", :title "Video", :column-name "c9"}
+            {:type "text", :title "Photo", :column-name "c10"}
             {:type "text", :title "Geolocation", :column-name "c11"}
             {:type "number", :title "Number", :column-name "c12"}
             {:type "text", :title "Cascade", :column-name "c13"}


let search match against "inside" functions

--- cljs-client/cljsinfo_client/cheatsheet.cljs
+++ cljs-client/cljsinfo_client/cheatsheet.cljs
@@ -43,7 +43,7 @@
 (def matched-search-class "matched-e5c67")
 (def matched-search-sel (str "." matched-search-class))
 (def no-results-class "no-results-5d3ea")
-(def fn-link-sel ".fn-a8476")
+(def fn-link-sel ".fn-a8476, .inside-fn-c7607")
 (def group-sel ".group-2be36")
 (def section-sel ".section-31efe")
 (def search-input-id "searchInput")
@@ -55,7 +55,7 @@

 (defn- toggle-el!
   "Show / hide an element based on whether it contains a search match or not."
-  [idx el]
+  [_idx el]
   (let [$el ($ el)
         $matched (.find $el matched-search-sel)
         matches-in-el? (pos? (aget $matched "length"))]
@@ -74,7 +74,7 @@
       (aget "length")
       pos?))

-(defn- toggle-fn-link [idx el search-txt]
+(defn- toggle-fn-link [el search-txt]
   (let [$link ($ el)
         link-txt (.text $link)
         match? (not= -1 (.indexOf link-txt search-txt))]
@@ -84,7 +84,7 @@

 (defn- toggle-fn-matches! [search-txt]
   (let [$links ($ fn-link-sel)]
-    (.each $links #(toggle-fn-link %1 %2 search-txt))))
+    (.each $links #(toggle-fn-link %2 search-txt))))

 (defn- clear-search! []
   (.removeClass ($ search-input-sel) no-results-class)


touching up the bike shed

touching up the bike shed

--- boot/core/src/boot/task/built_in.clj
+++ boot/core/src/boot/task/built_in.clj
@@ -78,7 +78,7 @@
               `(boot.notify/failure! ~theme ~failure))
             (throw t)))))))

-(core/deftask debug
+(core/deftask env
   "Print the boot environment map."
   []
   (core/with-pre-wrap
@@ -248,15 +248,15 @@
   "Create project web.xml file.

   The --serve option is required. The others are optional."
-
+
   [s serve SYM        sym "The 'serve' callback function."
    c create SYM       sym "The 'create' callback function."
    d destroy SYM      sym "The 'destroy' callback function."]
-
+
   (defonce web-created? (atom false))
   (core/with-pre-wrap
     (when-not @web-created?
-      (-> (and (symbol? serve) (namespace serve))
+      (-> (and (symbol? serve) (namespace serve))
         (assert "no serve function specified"))
       (let [tgt (core/mktgtdir! ::web-tgt)]
         (pod/call-worker


core - rename arg http-spec -> request,  basic verify using Spec, use sequential? instead of (or list? vector?)

--- src/re_frame_http_fx/core.cljs
+++ src/re_frame_http_fx/core.cljs
@@ -2,7 +2,8 @@
   (:require
     [goog.net.ErrorCode :as errors]
     [re-frame.core      :refer [def-fx dispatch console]]
-    [ajax.core          :as ajax]))
+    [ajax.core          :as ajax]
+    [cljs.spec          :as s]))

 ;; I provide the :http effect handler leveraging cljs-ajax lib
 ;; see API docs https://github.com/JulianBirch/cljs-ajax
@@ -37,14 +38,14 @@

 (defn spec->ajax-options
-  [{:as   http-spec
+  [{:as   request
     :keys [on-success on-failure api response-format]
     :or   {on-success      [:http-no-on-success]
            on-failure      [:http-no-on-failure]
            api             (new js/goog.net.XhrIo)
            response-format (ajax/detect-response-format)}}]
   ; wrap events in cljs-ajax callbacks
-  (-> http-spec
+  (-> request
       (assoc
         :api             api
         :response-format response-format
@@ -54,17 +55,16 @@
                                  api))
       (dissoc :on-success :on-failure)))

+(s/def ::sequential-or-map (s/or :list-or-vector sequential? :map map?))

 (def-fx
   :http
-  (fn http-effect [http-spec]
-    ;;TODO verify with Spec
+  (fn http-effect [request]
+    (when (= :cljs.spec/invalid (s/conform ::sequential-or-map request))
+      (console :error (s/explain-str ::sequential-or-map request)))
+    ;;TODO verify detail request(s) using spec for ajax-request api
     (cond
-      (or (list? http-spec) (vector? http-spec))
-      (doseq [each http-spec] (http-effect each))
-
-      (map? http-spec)
-      (-> http-spec spec->ajax-options ajax/ajax-request)
-
+      (sequential? request) (doseq [each request] (http-effect each))
+      (map? request)        (-> request spec->ajax-options ajax/ajax-request)
       :else
-      (console :error "re-frame-http-fx: expected :http effect to be a list or vector or map, but got: " http-spec))))
+      (console :error "re-frame-http-fx: expected request to be a list or vector or map, but got: " request))))


Fix cached-custom-prop-name

Fix cached-custom-prop-name

--- src/reagent/impl/template.cljs
+++ src/reagent/impl/template.cljs
@@ -82,13 +82,14 @@
   (if (named? k)
     (if-some [k' (cache-get custom-prop-name-cache (name k))]
       k'
-      (gobj/set prop-name-cache (name k) (util/dash-to-camel k)))
+      (let [v (util/dash-to-camel k)]
+        (gobj/set prop-name-cache (name k) v)
+        v))
     k))

 (defn custom-kv-conv [o k v]
   (doto o
-    (aset (cached-custom-prop-name k)
-          (convert-prop-value v))))
+    (gobj/set (cached-custom-prop-name k) (convert-prop-value v))))

 (defn convert-custom-prop-value [x]
   (cond (js-val? x) x


first run at the homepage animation

first run at the homepage animation

--- src-cljs/frontend/components/drawing.cljs
+++ src-cljs/frontend/components/drawing.cljs
@@ -18,10 +18,10 @@
 (defn clear-subscriber [tick-state tick]
   (add-tick tick-state tick (fn [owner]
                               ((om/get-shared owner :cast!)
-                               :subscriber-updated {:client-id (ffirst state/subscriber-bot)
-                                                    :fields {:mouse-position nil
-                                                             :tool nil
-                                                             :show-mouse? false}}))))
+                               :subscriber-updated {:client-id (:client-id state/subscriber-bot)
+                                                    :fields (merge state/subscriber-bot {:mouse-position nil
+                                                                                :tool nil
+                                                                                :show-mouse? false})}))))

 (defn move-mouse [tick-state {:keys [start-tick end-tick start-x end-x start-y end-y tool]
                               :or {tool :rect}}]
@@ -36,27 +36,31 @@
                                                    (/ (- end-y start-y)
                                                       (- end-tick start-tick))))]
                               ((om/get-shared owner :cast!)
-                               :subscriber-updated {:client-id (ffirst state/subscriber-bot)
-                                                    :fields {:mouse-position [ex ey]
-                                                             :show-mouse? true
-                                                             :tool tool}})))))
+                               :subscriber-updated {:client-id (:client-id state/subscriber-bot)
+                                                    :fields (merge state/subscriber-bot {:mouse-position [ex ey]
+                                                                                :show-mouse? true
+                                                                                :tool tool})})))))
               tick-state
               (range 0 (inc (- end-tick start-tick))))
     (annotate-keyframes end-tick)))

 (defn draw-shape [tick-state {:keys [start-tick end-tick start-x end-x
-                                     start-y end-y type tool doc-id props]
-                              :or {type :rect
-                                   tool :rect}}]
+                                     start-y end-y tool doc-id props]
+                              :or {tool :rect}}]
   (let [base-layer (merge {:layer/start-x start-x
                            :layer/start-y start-y
                            :layer/end-x end-x
                            :layer/end-y end-y
-                           :layer/type (keyword "layer.type" (name type))
+                           :layer/type (keyword "layer.type" (if (= :circle tool)
+                                                               "rect"
+                                                               (name tool)))
                            :layer/name "placeholder"
                            :layer/stroke-width 1
                            :document/id doc-id
-                           :db/id (inc (rand-int 1000))}
+                           :db/id (- (inc (rand-int 1000)))}
+                          (when (= :circle tool)
+                            {:layer/rx 1000
+                             :layer/ry 1000})
                           props)
         ;; number of ticks to pause before saving layer
         pause-ticks 2]
@@ -71,19 +75,19 @@
                                                      (/ (- end-y start-y)
                                                         (- end-tick start-tick pause-ticks))))]
                                 ((om/get-shared owner :cast!)
-                                 :subscriber-updated {:client-id (ffirst state/subscriber-bot)
-                                                      :fields {:mouse-position [ex ey]
-                                                               :show-mouse? true
-                                                               :layers [(assoc base-layer
-                                                                               :layer/current-x ex
-                                                                               :layer/current-y ey)]
-                                                               :tool tool}})))))
+                                 :subscriber-updated {:client-id (:client-id state/subscriber-bot)
+                                                      :fields (merge state/subscriber-bot {:mouse-position [ex ey]
+                                                                                :show-mouse? true
+                                                                                :layers [(assoc base-layer
+                                                                                :layer/current-x ex
+                                                                                :layer/current-y ey)]
+                                                                                :tool tool})})))))
                 tick-state
                 (range 0 (inc (- end-tick start-tick pause-ticks))))
       (add-tick end-tick
                 (fn [owner]
                   ((om/get-shared owner :cast!)
-                   :subscriber-updated {:client-id (ffirst state/subscriber-bot)
+                   :subscriber-updated {:client-id (:client-id state/subscriber-bot)
                                         :fields {:mouse-position nil
                                                  :layers nil
                                                  :tool tool}})
@@ -115,14 +119,14 @@
                                                          (/ (- end-tick start-tick pause-ticks)
                                                             relative-tick)))]
                                 ((om/get-shared owner :cast!)
-                                 :subscriber-updated {:client-id (ffirst state/subscriber-bot)
-                                                      :fields {:mouse-position [start-x (- start-y (/ text-height 2))]
-                                                               :show-mouse? true
-                                                               :layers [(assoc base-layer
-                                                                               :layer/text (apply str (take letter-count text))
-                                                                               :layer/current-x end-x
-                                                                               :layer/current-y end-y)]
-                                                               :tool :text}})))))
+                                 :subscriber-updated {:client-id (:client-id state/subscriber-bot)
+                                                      :fields (merge state/subscriber-bot {:mouse-position [start-x (- start-y (/ text-height 2))]
+                                                                                :show-mouse? true
+                                                                                :layers [(assoc base-layer
+                                                                                :layer/text (apply str (take letter-count text))
+                                                                                :layer/current-x end-x
+                                                                                :layer/current-y end-y)]
+                                                                                :tool :text})})))))
                 tick-state
                 (map int
                      (range 0
@@ -132,69 +136,12 @@
       (add-tick end-tick
                 (fn [owner]
                   ((om/get-shared owner :cast!)
-                   :subscriber-updated {:client-id (ffirst state/subscriber-bot)
-                                        :fields {:mouse-position nil
-                                                 :layers nil
-                                                 :tool :text}})
+                   :subscriber-updated {:client-id (:client-id state/subscriber-bot)
+                                        :fields (merge state/subscriber-bot {:mouse-position nil
+                                                                             :layers nil
+                                                                             :tool :text})})
                   (d/transact! (om/get-shared owner :db) [base-layer] {:bot-layer true})))
       (annotate-keyframes start-tick end-tick))))
-
-(defn signup-animation [document vw]
-  (let [text "Sign in with Google"
-        text-width 171
-
-        rect-width 208
-        rect-height 48
-
-        rect-offset-x 8
-        rect-offset-y 8
-
-        rect-start-x (- vw rect-width rect-offset-x)
-        rect-start-y (+ rect-offset-y rect-height)
-        rect-end-x (+ rect-start-x rect-width)
-        rect-end-y rect-offset-y
-
-        text-start-x (+ rect-start-x (/ (- rect-width text-width) 2))
-        text-start-y (+ rect-end-y text-height (/ (- rect-height text-height) 2))]
-    (-> {:tick-ms 16
-         :ticks {}}
-      (move-mouse {:start-tick 10
-                   :end-tick 45
-                   :start-x vw
-                   :end-x rect-start-x
-                   :start-y 0
-                   :end-y rect-start-y})
-      (draw-shape {:type :rect
-                   :doc-id (:db/id document)
-                   :tool :rect
-                   :start-tick 50
-                   :end-tick 100
-                   :start-x rect-start-x
-                   :end-x rect-end-x
-                   :start-y rect-start-y
-                   :end-y rect-end-y
-                   :props {;; look into this later, right now it interfers with signup action
-                           ;; :layer/ui-target "/signup"
-                           :layer/signup-button true}})
-      (move-mouse {:tool :text
-                   :start-tick 100
-                   :end-tick 120
-                   :start-x rect-end-x
-                   :end-x text-start-x
-                   :start-y rect-end-y
-                   :end-y (- text-start-y (/ text-height 2))})
-      (draw-text {:text text
-                  :doc-id (:db/id document)
-                  :start-tick 120
-                  :end-tick 200
-                  :start-x text-start-x
-                  :end-x (+ text-start-x text-width)
-                  :start-y text-start-y
-                  :end-y (- text-start-y text-height)
-                  :props {;; look into this later, right now it interfers with signup action
-                          ;;:layer/ui-target "/signup"
-                          :layer/signup-button true}})
-      (clear-subscriber 201))))

 (defn clear-ticks [tick-state ticks]
   (update-in tick-state [:ticks] #(apply dissoc % ticks)))
@@ -205,15 +152,16 @@
     nil))

 (defn run-animation* [owner start-ms current-ms tick-state min-tick max-tick]
-  (if (and (om/mounted? owner)
-           (seq (:ticks tick-state)))
+  (if-not (and (om/mounted? owner)
+               (seq (:ticks tick-state)))
+    nil;(js/console.profileEnd)
     (let [latest-tick (int (/ (- current-ms start-ms)
                               (:tick-ms tick-state)))
           tick-range (vec (range min-tick (inc latest-tick)))
           ticks (-> (filter #(contains? (:keyframes tick-state) %) tick-range)
                   set
                   (conj (middle-elem tick-range)))]
-      (doseq [tick ticks]
+      (doseq [tick (sort ticks)]
         (when-let [tick-fn (get-in tick-state [:ticks tick])]
           (tick-fn owner)))
       (utils/rAF (fn [timestamp]
@@ -236,9 +184,43 @@
                  (run-animation* owner timestamp timestamp tick-state 0 max-tick)))))

 (defn cleanup [owner]
-  ((om/get-shared owner :cast!) :subscriber-updated {:client-id (ffirst state/subscriber-bot)
-                                                     :fields {:mouse-position nil
-                                                              :layers nil}}))
+  ((om/get-shared owner :cast!) :subscriber-updated {:client-id (:client-id state/subscriber-bot)
+                                                     :fields (merge state/subscriber-bot {:mouse-position nil
+                                                                                :layers nil})}))
+
+(defn signup-animation [document vw]
+  (let [text "Sign in with Google"
+        text-width 171
+
+        rect-width 208
+        rect-height 48
+
+        rect-offset-x 8
+        rect-offset-y 8
+
+        rect-start-x (- vw rect-width rect-offset-x)
+        rect-start-y (+ rect-offset-y rect-height)
+        rect-end-x (+ rect-start-x rect-width)
+        rect-end-y rect-offset-y
+
+        text-start-x (+ rect-start-x (/ (- rect-width text-width) 2))
+        text-start-y (+ rect-end-y text-height (/ (- rect-height text-height) 2))]
+    (-> {:tick-ms 16
+         :ticks {}}
+      (move-mouse {:start-tick 10 :end-tick 45 :start-x vw :end-x rect-start-x :start-y 0 :end-y rect-start-y})
+      (draw-shape {:doc-id (:db/id document) :tool :rect :start-tick 50 :end-tick 100 :start-x rect-start-x :end-x rect-end-x
+                   :start-y rect-start-y :end-y rect-end-y
+                   :props {;; look into this later, right now it interfers with signup action
+                           ;; :layer/ui-target "/signup"
+                           :layer/signup-button true}})
+      (move-mouse {:tool :text :start-tick 100 :end-tick 120 :start-x rect-end-x :end-x text-start-x
+                   :start-y rect-end-y :end-y (- text-start-y (/ text-height 2))})
+      (draw-text {:text text :doc-id (:db/id document) :start-tick 120 :end-tick 200 :start-x text-start-x
+                  :end-x (+ text-start-x text-width) :start-y text-start-y :end-y (- text-start-y text-height)
+                  :props {;; look into this later, right now it interfers with signup action
+                          ;;:layer/ui-target "/signup"
+                          :layer/signup-button true}})
+      (clear-subscriber 201))))

 (defn signup-button [document owner]
   (reify
@@ -256,3 +238,174 @@
     (render [_]
       ;; dummy span so that the component can be mounted
       (dom/span #js {:className "hidden"}))))
+
+(defn add-shape [tick-state tick-count props]
+  (draw-shape tick-state (merge (let [start-tick (inc (apply max (conj (keys (:ticks tick-state)) -1)))]
+                                  {:start-tick start-tick
+                                   :end-tick (+ start-tick (int (* 1.5 tick-count)))})
+                                props)))
+
+(defn add-mouse-transition [tick-state tick-count previous-shape next-shape]
+  (move-mouse tick-state (let [start-tick (inc (apply max (conj (keys (:ticks tick-state)) -1)))]
+                           {:start-tick start-tick
+                            :end-tick (+ start-tick (int (* 1.5 tick-count)))
+                            :start-x (:end-x previous-shape)
+                            :start-y (:end-y previous-shape)
+                            :tool (:tool previous-shape)
+                            :end-x (:start-x next-shape)
+                            :end-y (:start-y next-shape)})))
+
+(defn browser [document viewport]
+  (let [start-x 100
+        start-y 100
+        width (int (* (- (:width viewport) 200)
+                      0.9))
+        height (int (* (- (:height viewport) 200)
+                       0.9))]
+    {:doc-id (:db/id document) :tool :rect
+     :start-x start-x :end-x (+ start-x width)
+     :start-y start-y :end-y (+ start-y height)}))
+
+(defn menu-bar [document viewport]
+  (let [browser (browser document viewport)]
+    {:doc-id (:db/id document) :tool :line
+     :start-x (:start-x browser) :end-x (:end-x browser)
+     :start-y (+ (:start-y browser) 30) :end-y (+ (:start-y browser) 30)}))
+
+(defn close-button [document viewport]
+  (let [browser (browser document viewport)]
+    {:doc-id (:db/id document) :tool :circle
+     :start-x (+ (:start-x browser) 10) :end-x (+ (:start-x browser) 20)
+     :start-y (+ (:start-y browser) 10) :end-y (+ (:start-y browser) 20)}))
+
+(defn minimize-button [document viewport]
+  (let [browser (browser document viewport)]
+    {:doc-id (:db/id document) :tool :circle
+     :start-x (+ (:start-x browser) 25) :end-x (+ (:start-x browser) 35)
+     :start-y (+ (:start-y browser) 10) :end-y (+ (:start-y browser) 20)}))
+
+(defn expand-button [document viewport]
+  (let [browser (browser document viewport)]
+    {:doc-id (:db/id document) :tool :circle
+     :start-x (+ (:start-x browser) 40) :end-x (+ (:start-x browser) 50)
+     :start-y (+ (:start-y browser) 10) :end-y (+ (:start-y browser) 20)}))
+
+(defn search-box [document viewport]
+  (let [browser (browser document viewport)
+        width (- (:end-x browser)
+                 (:start-x browser))
+        height (- (:end-y browser)
+                  (:start-y browser))
+        box-width 540
+        start-x (int (- (+ (:start-x browser) (/ width 2))
+                        (/ box-width 2)))
+        box-height 28
+        start-y (int (- (+ (:start-y browser) (/ height 2))
+                        (* 2 box-height)))]
+    {:doc-id (:db/id document) :tool :rect
+     :start-x start-x :end-x (+ start-x box-width)
+     :start-y start-y :end-y (+ start-y box-height)}))
+
+(defn submit-button [document viewport]
+  (let [search-box (search-box document viewport)
+        width (- (:end-x search-box)
+                 (:start-x search-box))
+        height (- (:end-y search-box)
+                  (:start-y search-box))
+        start-x (int (+ (:start-x search-box)
+                        (/ width 4)))
+        start-y (int (+ (:start-y search-box)
+                        (* 1.5 height)))
+        ]
+    {:doc-id (:db/id document) :tool :rect
+     :start-x start-x :end-x (+ start-x (int (/ width 4)))
+     :start-y start-y :end-y (+ start-y height)}))
+
+(defn lucky-button [document viewport]
+  (let [submit-button (submit-button document viewport)
+        start-x (:end-x submit-button)
+        width (- (:end-x submit-button)
+                 (:start-x submit-button))]
+    {:doc-id (:db/id document) :tool :rect
+     :start-x start-x :end-x (+ start-x width)
+     :start-y (:start-y submit-button) :end-y (:end-y submit-button)}))
+
+(defn footer-1 [document viewport]
+  (let [browser (browser document viewport)
+        width (- (:end-x browser)
+                 (:start-x browser))
+        line-width 500
+        start-x (int (- (+ (:start-x browser) (/ width 2))
+                        (/ line-width 2)))
+        start-y (- (:end-y browser) 50)]
+    {:doc-id (:db/id document) :tool :line
+     :start-x start-x  :end-x (+ start-x line-width)
+     :start-y start-y :end-y start-y}))
+
+(defn footer-2 [document viewport]
+  (let [browser (browser document viewport)
+        width (- (:end-x browser)
+                 (:start-x browser))
+        line-width 400
+        start-x (int (- (+ (:start-x browser) (/ width 2))
+                        (/ line-width 2)))
+        start-y (- (:end-y browser) 25)]
+    {:doc-id (:db/id document) :tool :line
+     :start-x start-x  :end-x (+ start-x line-width)
+     :start-y start-y :end-y start-y}))
+
+(defn landing-animation [document viewport]
+  (let [browser (browser document viewport)
+        menu-bar (menu-bar document viewport)
+        close-button (close-button document viewport)
+        minimize-button (minimize-button document viewport)
+        expand-button (expand-button document viewport)
+        search-box (search-box document viewport)
+        submit-button (submit-button document viewport)
+        lucky-button (lucky-button document viewport)
+        footer-1 (footer-1 document viewport)
+        footer-2 (footer-2 document viewport)]
+    (-> {:tick-ms 16
+         :ticks {}}
+      ;; the mouse could be automatic
+      (add-mouse-transition 50
+                            {:end-x (:width viewport)
+                             :end-y 100
+                             :tool :rect}
+                            browser)
+      (add-shape 100 browser)
+      (add-mouse-transition 50 browser menu-bar)
+      (add-shape 50 menu-bar)
+      (add-mouse-transition 25 menu-bar close-button)
+      (add-shape 10 close-button)
+      (add-mouse-transition 10 close-button minimize-button)
+      (add-shape 10 minimize-button)
+      (add-mouse-transition 10 minimize-button expand-button)
+      (add-shape 10 expand-button)
+      (add-mouse-transition 30 expand-button search-box)
+      (add-shape 30  search-box)
+      (add-mouse-transition 20 search-box submit-button)
+      (add-shape 30 submit-button)
+      (add-mouse-transition 1 submit-button lucky-button)
+      (add-shape 30 lucky-button)
+      (add-mouse-transition 20 lucky-button footer-1)
+      (add-shape 20 footer-1)
+      (add-mouse-transition 10 footer-1 footer-2)
+      (add-shape 18 footer-2))))
+
+(defn landing-background [document owner]
+  (reify
+    om/IDisplayName (display-name [_] "Landing Animation")
+    om/IDidMount
+    (did-mount [_]
+      ;; TODO: would be nice to get this a different way :(
+      (let [viewport (utils/canvas-size)]
+        (when true;(< 640 (:width viewport)) ;; only if not on mobile
+          (run-animation owner (landing-animation document viewport)))))
+    om/IWillUnmount
+    (will-unmount [_]
+      (cleanup owner))
+    om/IRender
+    (render [_]
+      ;; dummy span so that the component can be mounted
+      (dom/span #js {:className "hidden"}))))


Don't barf on nil urls.

Don't barf on nil urls.

--- wildfly/src/immutant/wildfly.clj
+++ wildfly/src/immutant/wildfly.clj
@@ -29,7 +29,7 @@
 (defn- if-exists?
   "Returns the given url if it matches a file that exists."
   [url]
-  (if (.exists (io/file url))
+  (if (and url (.exists (io/file url)))
     url))

 (defn- loader->url


Fix overly specific type hint

Fix overly specific type hint

--- src/grafter_2/rdf4j/repository.clj
+++ src/grafter_2/rdf4j/repository.clj
@@ -344,7 +344,7 @@
 (defn ^:no-doc sesame-results->seq
   "Convert a sesame results object into a lazy sequence of results."
   ([prepared-query] (sesame-results->seq prepared-query identity))
-  ([^TupleQuery prepared-query converter-f]
+  ([^Query prepared-query converter-f]
      (let [^CloseableIteration results (.evaluate prepared-query)
            run-query (fn pull-query []
                        (try


Update the regex used for JS obj printing

--- ClojureScript/replete/src/replete/pprint.cljs
+++ ClojureScript/replete/src/replete/pprint.cljs
@@ -59,7 +59,7 @@
       (pretty-coll this "#js [" x :line "]" visit)
       (object? x)
       (let [kvs (map (fn [k]
-                       [(cond-> k (some? (re-matches #"[A-Za-z][\w\*\+\?!\-']*" k)) keyword)
+                       [(cond-> k (some? (re-matches #"[A-Za-z_\*\+\?!\-'][\w\*\+\?!\-']*" k)) keyword)
                         (gobj/get x k)])
                   (js-keys x))]
         (pretty-coll this "#js {" kvs [:span "," :line] "}"


make fetch-async actually work

make fetch-async actually work

--- src/appengine_magic/services/urlfetch.clj
+++ src/appengine_magic/services/urlfetch.clj
@@ -31,7 +31,7 @@
   (parse-response (.fetch (get-urlfetch-service) (urlify url))))

 (defn fetch-async [url]
-  (let [f (.fetchAsync (urlify url))]
+  (let [f (.fetchAsync (get-urlfetch-service) (urlify url))]
     (reify
      clojure.lang.IDeref
       (deref [_] (parse-response (.get f)))


fix: characters can no longer have more than 5 societies or greater than 20 management

--- src/hphelper/chargen/generator.clj
+++ src/hphelper/chargen/generator.clj
@@ -24,8 +24,13 @@
   (if (and (not (-> charRec :priStats (get "Management")))
            (-> charRec (get "Program Group"))) ;; If no management skill but an existing program group
     (assoc-in charRec [:priStats "Management"]
-              (let [minimum (inc (* 5 (dec (dec (count (get charRec "Program Group"))))))]
-                (+ minimum (rand-int (- 20 minimum)))))
+              (let [minimum (inc
+                              (* 5
+                                 (+ -2
+                                    (min 5
+                                         (count (get charRec "Program Group"))))))]
+                (log/info "Minimum is: " minimum)
+                (+ minimum (rand-int (- 21 minimum)))))
     charRec))

 (defn- calc-clone-degredation
@@ -54,8 +59,9 @@
       charRec
       (recur (assoc-in charRec ["Program Group"] ;; Add a random society
                        (clojure.set/union #{} (charRec "Program Group") #{(sql/get-random-society)}))))
-    (recur (update-in charRec ["Program Group"] ;; Drop a random society
-                      (dissoc (rand-int (count (charRec "Program Group"))))))))
+    (recur (assoc-in charRec ["Program Group"] ;; Drop a random society
+                     (let [pg (get charRec "Program Group")]
+                       (disj pg (rand-nth (into '() pg))))))))

 (defn- calc-access-remaining
   "Calculates remaining access"


added swank-clojure dependency

added swank-clojure dependency

--- project.clj
+++ project.clj
@@ -9,5 +9,6 @@
                  [clj-time "0.3.0"]
                  [clojure-couchdb "0.4.5"]]
   :dev-dependencies [[lein-ring "0.4.0"]
-                     [org.clojars.autre/lein-vimclojure "1.0.0"]]
+                     [org.clojars.autre/lein-vimclojure "1.0.0"]
+                     [swank-clojure "1.2.1"]]
   :ring {:handler vix.routes/app})


Added conjars.

Added conjars.

--- project.clj
+++ project.clj
@@ -4,7 +4,8 @@
   :javac-options {:debug "true" :fork "true"}
   :jvm-opts ["-Xmx768m" "-server"]
   :repositories {"oracle" "http://download.oracle.com/maven"
-                 "releases" "http://artifactory.local.twitter.com/libs-releases-local"}
+                 "releases" "http://artifactory.local.twitter.com/libs-releases-local"
+                 "conjars" "http://conjars.org/repo/"}
   :dependencies [[org.clojure/clojure "1.3.0"]
                  [jvyaml "1.0.0"]
                  [org.yaml/snakeyaml "1.9"]


Move to latest released liberator.

Move to latest released liberator.

This is a build of the 0.12.1 tag in liberator upstream repo.

However, The clojars jar is corrupt so we build our own.

See https://github.com/clojure-liberator/liberator/issues/162

--- project.clj
+++ project.clj
@@ -57,8 +57,8 @@
                  [org.clojure/tools.reader "0.8.8"]

                  ;; using a patched liberator pending
-                 ;; https://github.com/clojure-liberator/liberator/pull/120
-                 [kixi/liberator "0.12.0-p2-413ee59"]
+                 ;; https://github.com/clojure-liberator/liberator/issues/162
+                 [kixi/liberator "0.12.1-p0"]
                  [cheshire "5.3.1"]

                  ;; Required for Cassandra (possibly only OSX)


Update Clojure dep to 1.7.0-beta2.

Update Clojure dep to 1.7.0-beta2.

--- project.clj
+++ project.clj
@@ -3,7 +3,7 @@
   :url "https://github.com/mpietrzak/sqls"
   :license {:name "Eclipse Public License"
             :url "http://www.eclipse.org/legal/epl-v10.html"}
-  :dependencies [[org.clojure/clojure "1.7.0-alpha6"]
+  :dependencies [[org.clojure/clojure "1.7.0-beta2"]
                  [org.clojure/data.json "0.2.6"]
                  [org.clojure/java.jdbc "0.3.6"]
                  [org.clojure/tools.cli "0.3.1"]


Add new amazonica Version for Region Frankfurt

--- project.clj
+++ project.clj
@@ -22,7 +22,7 @@
                  [org.slf4j/jul-to-slf4j "1.7.7"]
                  [org.slf4j/jcl-over-slf4j "1.7.7"]
                  ; amazon aws (if upgrading, also check the joda-time version)
-                 [amazonica "0.2.30" :exclusions [joda-time commons-logging]]
+                 [amazonica "0.3.12" :exclusions [joda-time commons-logging]]
                  [joda-time "2.5"]
                  ; storage
                  [postgresql "9.3-1102.jdbc41"]


add javac options to specify 1.8 JDK

add javac options to specify 1.8 JDK

--- project.clj
+++ project.clj
@@ -8,6 +8,7 @@
                  [com.stuartsierra/component "0.2.3"]]
   :source-paths []
   :java-source-paths ["src/org/onyxplatform/api/java/"]
+  :javac-options ["-target" "1.8" "-source" "1.8" "-Xlint:-options"]
   :profiles {:uberjar {:aot :all}
              :dev {:dependencies [[org.clojure/tools.namespace "0.2.10"]]
                    :plugins [[lein-update-dependency "0.1.2"]


Update prismatic/schema to 0.4.2

Update prismatic/schema to 0.4.2

--- project.clj
+++ project.clj
@@ -15,7 +15,7 @@
                  [com.draines/postal "1.11.3"]
                  [version-clj "0.1.2"]
                  [clojurewerkz/quartzite "2.0.0"]
-                 [prismatic/schema "0.4.1"]
+                 [prismatic/schema "0.4.2"]
                  [com.stuartsierra/component "0.2.3"]
                  [me.raynes/fs "1.4.6"]
                  [com.googlecode.streamflyer/streamflyer-core "1.1.3"]


removed SNAPSHOT from project

removed SNAPSHOT from project

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject storm/storm-kafka "0.7.4-dynamic-json-SNAPSHOT"
+(defproject storm/storm-kafka "0.7.5-dynamic-json"
   :source-path "src/clj"
   :java-source-path "src/jvm"
   :javac-options {:debug "true" :fork "true"}


Fixed react problem with react 14

Fixed react problem with react 14

works better now

--- project.clj
+++ project.clj
@@ -1,10 +1,9 @@
 (defproject org.clojars.zubairq/coils "0.7.5-beta"
   :dependencies [
                   [org.clojure/clojure "1.8.0" :scope "provided"]
-                  [org.clojure/clojurescript "1.9.36" :scope "provided"]
+                  [org.clojure/clojurescript "1.9.89" :scope "provided"]
                   [org.omcljs/om "1.0.0-alpha30"]
                   [org.clojure/core.async "0.2.374" :scope "provided"]
-                  [cljsjs/react "0.14.3-0"]

                   [korma "0.4.2"]


Version 1.7.2-SNAPSHOT

Version 1.7.2-SNAPSHOT

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject puppetlabs/lein-ezbake "1.7.1"
+(defproject puppetlabs/lein-ezbake "1.7.2-SNAPSHOT"
   :description "A system for building packages for trapperkeeper-based applications"
   :url "https://github.com/puppetlabs/ezbake"
   :license {:name "Apache License 2.0"


Updating dependencies.

Updating dependencies.

--- project.clj
+++ project.clj
@@ -4,11 +4,11 @@
   :license {:name "Eclipse Public License"
             :url "http://www.eclipse.org/legal/epl-v10.html"}
   :dependencies [[org.clojure/clojure "1.6.0"]
-                 [compojure "1.3.1"]
+                 [compojure "1.3.2"]
                  [ring/ring-defaults "0.1.4"]
                  [enlive "1.1.5"]
                  [environ "1.0.0"]]
-  :plugins [[lein-ring "0.9.1"]]
+  :plugins [[lein-ring "0.9.3"]]

   :aot [ahnentafel.gedcom.ParseError]
   :ring {:handler ahnentafel.main/app}
@@ -16,7 +16,7 @@
   :profiles
   {:dev
    {:resource-paths ["test-resources"]
-    :plugins [[lein-ancient "0.6.2"]
+    :plugins [[lein-ancient "0.6.5"]
               [lein-bikeshed "0.2.0"]
               [lein-kibit "0.0.8"]]
     :dependencies [[ring/ring-mock "0.2.0"]]


Release version 0.13.0.0-alpha1.

Release version 0.13.0.0-alpha1.

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject onyx-app/lein-template "0.12.7.1-SNAPSHOT"
+(defproject onyx-app/lein-template "0.13.0.0-alpha1"
   :description "Onyx Leiningen application template"
   :url "https://github.com/onyx-platform/onyx-template"
   :license {:name "MIT License"


Removed SNAPSHOT from lein-clojars dependency

--- project.clj
+++ project.clj
@@ -5,6 +5,6 @@
                  [org.clojure/clojure-contrib "1.1.0"]
                  [clout "0.2.0-SNAPSHOT"]
                  [ring/ring-core "0.2.0"]]
-  :dev-dependencies [[lein-clojars "0.5.0-SNAPSHOT"]
+  :dev-dependencies [[lein-clojars "0.5.0"]
                      [ring/ring-jetty-adapter "0.2.0"]
                      [hiccup "0.2.1"]])


using new versions

using new versions

--- project.clj
+++ project.clj
@@ -3,8 +3,8 @@
   :url "https://www.domaindrivenarchitecture.org"
   :license {:name "Apache License, Version 2.0"
             :url "https://www.apache.org/licenses/LICENSE-2.0.html"}
- :dependencies [[org.clojure/clojure "1.6.0"]
-                [com.palletops/pallet "0.8.10"]
+ :dependencies [[org.clojure/clojure "1.7.0"]
+                [com.palletops/pallet "0.8.11"]
                 [com.palletops/pallet "0.8.10" :classifier "tests"]
                 [com.palletops/stevedore "0.8.0-beta.7"]
                 [org.domaindrivenarchitecture.org/dda-config-crate "0.3.0-SNAPSHOT"]]


Bump deps

Bump deps

--- project.clj
+++ project.clj
@@ -1,38 +1,37 @@
-(defproject io.nervous/eulalie "0.6.9"
+(defproject io.nervous/eulalie "0.6.10"
   :description "Asynchronous, pure-Clojure AWS client"
   :url "https://github.com/nervous-systems/eulalie"
   :license {:name "Unlicense" :url "http://unlicense.org/UNLICENSE"}
   :scm {:name "git" :url "https://github.com/nervous-systems/eulalie"}
-  :global-vars {*warn-on-reflection* true}
   :source-paths ["src"]
   :dependencies
   [[org.clojure/clojure        "1.8.0"]
-   [org.clojure/clojurescript  "1.8.34"]
-   [org.clojure/core.async     "0.2.374"]
+   [org.clojure/clojurescript  "1.8.51"]
+   [org.clojure/core.async     "0.2.395"]

    [io.nervous/glossop         "0.2.1"]
-   [prismatic/plumbing         "0.4.4"]
+   [prismatic/plumbing         "0.5.3"]

-   [camel-snake-kebab          "0.3.2"]
+   [camel-snake-kebab          "0.4.0"]

    [http-kit                   "2.1.18"]
    [com.cemerick/url           "0.1.1"]
    [cheshire                   "5.5.0"]
    [digest                     "1.4.4"]
-   [clj-time                   "0.11.0"]
+   [clj-time                   "0.12.2"]
    [base64-clj                 "0.1.1"]

    [com.andrewmcveigh/cljs-time    "0.4.0"]
    [io.nervous/cljs-nodejs-externs "0.1.0"]]
   :exclusions [[org.clojure/clojure]]

-  :node-dependencies [[source-map-support "0.2.8"]
-                      [buffer-crc32       "0.2.5"]
-                      [xml2js             "0.4.9"]]
+  :npm {:dependencies [[source-map-support "0.2.8"]
+                       [buffer-crc32       "0.2.5"]
+                       [xml2js             "0.4.9"]]}

-  :plugins [[lein-cljsbuild "1.0.6"]
-            [lein-npm       "0.5.0"]
-            [lein-doo       "0.1.7-SNAPSHOT"]]
+  :plugins [[lein-cljsbuild "1.1.4"]
+            [lein-npm       "0.6.2"]
+            [lein-doo       "0.1.7"]]

   :test-selectors {:default (complement :ec2)
                    :ec2 :ec2


Release 1.4.0.

Release 1.4.0.

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject com.draines/postal "1.4.0-SNAPSHOT"
+(defproject com.draines/postal "1.4.0"
   :resources-path "etc"
   :repositories {"java.net" "http://download.java.net/maven/2"
                  "clojars" "http://clojars.org/repo"}


Turn off Flight Recorder

Turn off Flight Recorder

--- project.clj
+++ project.clj
@@ -11,9 +11,9 @@
                         "-Daeron.rcv.initial.window.length=2097152"
                         "-Dagrona.disable.bounds.checks=true"

-                        "-XX:+UnlockCommercialFeatures" "-XX:+FlightRecorder"
-                        "-XX:+UnlockDiagnosticVMOptions"
-                        "-XX:StartFlightRecording=duration=1080s,filename=myrecording.jfr"
+                        ;"-XX:+UnlockCommercialFeatures" "-XX:+FlightRecorder"
+                        ;"-XX:+UnlockDiagnosticVMOptions"
+                        ;"-XX:StartFlightRecording=duration=1080s,filename=myrecording.jfr"
                         ; "-XX:+TraceClassLoading" "-XX:+LogCompilation" "-XX:+PrintAssembly"
                         ]


Update version for 5.2.20-SNAPSHOT development

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(def pdb-version "5.2.19")
+(def pdb-version "5.2.20-SNAPSHOT")
 (def clj-parent-version "1.4.3")
 (def tk-jetty9-ver "2.3.1")


bump to alpha6

bump to alpha6

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject re-frame "0.8.0-alpha6-SNAPSHOT"
+(defproject re-frame "0.8.0-alpha6"
   :description  "A Clojurescript MVC-like Framework For Writing SPAs Using Reagent."
   :url          "https://github.com/Day8/re-frame.git"
   :license      {:name "MIT"}


CMR Hotfix: Release version bump.

CMR Hotfix: Release version bump.

--- project.clj
+++ project.clj
@@ -15,7 +15,7 @@
        ns
        "\u001B[35m]\u001B[33m λ\u001B[m=> "))

-(defproject gov.nasa.earthdata/cmr-opendap "1.2.0-SNAPSHOT"
+(defproject gov.nasa.earthdata/cmr-opendap "1.2.1-SNAPSHOT"
   :description "OPeNDAP Integration in the CMR"
   :url "https://github.com/cmr-exchange/cmr-opendap"
   :license {


Upgrade prismatic/schema

Upgrade prismatic/schema

--- project.clj
+++ project.clj
@@ -22,7 +22,7 @@
    [manifold "0.1.2-alpha1"]
    [metosin/ring-http-response "0.6.5"]
    [metosin/ring-swagger "0.20.2" :exclusions [potemkin]]
-   [prismatic/schema "1.0.3"]
+   [prismatic/schema "1.0.4"]
    [potemkin "0.4.1" :exclusions [riddley]]
    [ring-basic-authentication "1.0.5"]
    [org.clojure/core.async "0.1.346.0-17112a-alpha"]


REPL Timeout

REPL Timeout

--- project.clj
+++ project.clj
@@ -2,6 +2,11 @@
   :description "FIXME: write description"
   :url "http://example.com/FIXME"
   :main nn-replicon-identification.core
+  :repl-options {}
+             ;; If nREPL takes too long to load it may timeout,
+             ;; increase this to wait longer before timing out.
+             ;; Defaults to 30000 (30 seconds)
+             :timeout 1200000
   :license {:name "Eclipse Public License"
             :url "http://www.eclipse.org/legal/epl-v10.html"}
   :plugins [[lein-gorilla "0.4.0"]]


Updated projects: codox, lein-cloverage, and junit-plugin libraries

--- project.clj
+++ project.clj
@@ -19,17 +19,21 @@
                    [clj-jgit "0.8.0"]
                    [clj-rm-rf "1.0.0-SNAPSHOT"]
                    [org.clojure/java.jdbc "0.3.5"]
+                   [org.clojure/tools.cli "0.3.1"]
                    [org.xerial/sqlite-jdbc "3.7.2"]
-                   [org.clojure/tools.cli "0.3.1"]
+                   [clojure-ini "0.0.1"]
                    [ring/ring-core "1.3.2"]
                    [ring/ring-jetty-adapter "1.3.2"]
-                   [clojure-ini "0.0.1"]
                    [org.clojars.tisnik/clj-flotr "0.2.0-SNAPSHOT"]
                    [org.clojars.tisnik/clj-calendar "0.1.0-SNAPSHOT"]
                    [hiccup "1.0.4"]]
     :dev-dependencies [[lein-ring "0.8.10"]]
-    :plugins [[lein-ring "0.8.10"]]
+    :plugins [[lein-ring "0.8.10"]
+              [codox "0.8.11"]
+              [test2junit "1.1.0"]
+              [lein-cloverage "1.0.6"]]
     :main ^:skip-aot arachnida.core
     :target-path "target/%s"
     :ring {:handler arachnida.server/app}
     :profiles {:uberjar {:aot :all}})
+


Update version to 0.2.1-SNAPSHOT

Update version to 0.2.1-SNAPSHOT

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject se.haleby/stub-http "0.2.1"
+(defproject se.haleby/stub-http "0.2.1-SNAPSHOT"
   :description "A client library agonistic way to stub HTTP responses"
   :url "https://github.com/johanhaleby/stub-http"
   :license {:name         "MIT License"


fixed bad merge (who DID that??!?)

fixed bad merge (who DID that??!?)

--- project.clj
+++ project.clj
@@ -19,7 +19,7 @@
                  [liberator "0.11.0"]
                  [clj-http "0.9.1"]
                  [org.clojure/data.json "0.2.4"]
-                 [org.clojure/clojure "1.6.0"]]]
+                 [org.clojure/clojure "1.6.0"]]

   :pedantic? :warn ; :abort
   :immutant {:context-path "/"}


Release Muxx 0.1.1 - Minor cleanups - Use latest libs

--- project.clj
+++ project.clj
@@ -10,7 +10,7 @@
 ;;; You must not remove this notice, or any other, from this software.

-(defproject muxx "0.1.1-SNAPSHOT"
+(defproject muxx "0.1.1"
   :description "Deploy multiple production and dev websites on one instance of compojure."
   :url "https://github.com/deg/muxx"
   :license {:name "Eclipse Public License"
@@ -19,7 +19,7 @@
                  [org.clojure/clojure "1.5.1"]

                  ;; Degel's Clojure utility library
-                 [degel-clojure-utils "0.1.14-SNAPSHOT"]]
+                 [degel-clojure-utils "0.1.14"]]

   :profiles {:dev
              { :plugins [[lein-marginalia "0.7.1"]]}})


Updated transit-clj -> 0.8.275 and transit-cljs -> 0.8.220

--- project.clj
+++ project.clj
@@ -18,8 +18,8 @@
                  [http-kit "2.1.19"]

                  [com.taoensso/sente "1.4.1" :exclusions [org.clojure/tools.reader]]
-                 [com.cognitect/transit-clj "0.8.271" :exclusions [commons-codec]]
-                 [com.cognitect/transit-cljs "0.8.215"]
+                 [com.cognitect/transit-clj "0.8.275" :exclusions [commons-codec]]
+                 [com.cognitect/transit-cljs "0.8.220"]

                  [reagent "0.5.0"]
                  [org.webjars/bootstrap "3.3.4"]]


Bump to 3.8.1-SNAPSHOT

Bump to 3.8.1-SNAPSHOT

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject clj-http "3.8.0"
+(defproject clj-http "3.8.1-SNAPSHOT"
   :description "A Clojure HTTP library wrapping the Apache HttpComponents client."
   :url "https://github.com/dakrone/clj-http/"
   :license {:name "The MIT License"


Start 0.4.0-SNAPSHOT

Start 0.4.0-SNAPSHOT

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject play-clj "0.3.12-SNAPSHOT"
+(defproject play-clj "0.4.0-SNAPSHOT"
   :description "A libGDX wrapper for easy cross-platform game development"
   :url "https://github.com/oakes/play-clj"
   :license {:name "Public Domain"


add factual/geo

add factual/geo


Version 0.6.0-SNAPSHOT

Version 0.6.0-SNAPSHOT

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject io.sarnowski/swagger1st "0.5.0"
+(defproject io.sarnowski/swagger1st "0.6.0-SNAPSHOT"
   :description "A ring middleware that does routing based on a swagger definition."
   :url "https://github.com/sarnowski/swagger1st"


Tweak benching :jvm-opts (mpenet)

Tweak benching :jvm-opts (mpenet)

--- project.clj
+++ project.clj
@@ -16,7 +16,8 @@
              :dev   {:dependencies []}
              :test  {:dependencies []}
              :bench {:dependencies []
-                     :jvm-opts ["-server" "-XX:+UseCompressedOops"]}}
+                     :jvm-opts ^:replace ["-server" "-XX:+UseCompressedOops"
+                                          "-XX:-TieredCompilation"]}}
   :aliases {"test-all"    ["with-profile" "test,1.4:test,1.5" "do" "test,"
                            "expectations"]
             "test-auto"   ["with-profile" "test" "autoexpect"]


lein-release plugin: preparing 0.1.0 release

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject puppetlabs/ring-middleware "0.1.0-SNAPSHOT"
+(defproject puppetlabs/ring-middleware "0.1.0"
   :dependencies [[org.clojure/clojure "1.6.0"]
                  [org.clojure/tools.logging "0.2.6"]
                  [ring "1.3.0"]


Update dependencies.

Update dependencies.

--- project.clj
+++ project.clj
@@ -16,7 +16,7 @@
     ;; Server-side
     [org.clojure/clojure "1.8.0-alpha2"] ; Lisp on the JVM http://clojure.org/documentation
     [org.clojure/core.match "0.3.0-alpha4"] ; Erlang-esque pattern matching https://github.com/clojure/core.match
-    [defun "0.2.0-RC"] ; Erlang-esque pattern matching for Clojure functions https://github.com/killme2008/defun
+    [defun "0.2.0"] ; Erlang-esque pattern matching for Clojure functions https://github.com/killme2008/defun
     [org.clojure/core.incubator "0.1.3"] ; Functions proposed for inclusion in Clojure https://github.com/clojure/core.incubator
     [cheshire "5.5.0"] ; JSON de/encoding https://github.com/dakrone/cheshire
     [org.flatland/ordered "1.5.3"] ; Ordered hash map https://github.com/flatland/ordered
@@ -28,7 +28,7 @@
     [com.ashafa/clutch "0.4.0"] ; CouchDB client https://github.com/clojure-clutch/clutch
     [clojurewerkz/elastisch "2.2.0-beta4"] ; Client for ElasticSearch https://github.com/clojurewerkz/elastisch
     [environ "1.0.1"] ; Get environment settings from different sources https://github.com/weavejester/environ
-    [com.taoensso/timbre "4.1.1"] ; Logging https://github.com/ptaoussanis/timbre
+    [com.taoensso/timbre "4.1.2"] ; Logging https://github.com/ptaoussanis/timbre
     [clj-http "2.0.0"] ; HTTP client https://github.com/dakrone/clj-http
     [superstring "2.1.0"] ; String manipulation https://github.com/expez/superstring
   ]
@@ -72,7 +72,7 @@
         [lein-kibit "0.1.2"] ; Static code search for non-idiomatic code https://github.com/jonase/kibit
         [lein-checkall "0.1.1"] ; Runs bikeshed, kibit and eastwood https://github.com/itang/lein-checkall
         [lein-pprint "1.1.2"] ; pretty-print the lein project map https://github.com/technomancy/leiningen/tree/master/lein-pprint
-        [lein-ancient "0.6.7"] ; Check for outdated dependencies https://github.com/xsc/lein-ancient
+        [lein-ancient "0.6.8-SNAPSHOT"] ; Check for outdated dependencies https://github.com/xsc/lein-ancient
         [lein-spell "0.1.0"] ; Catch spelling mistakes in docs and docstrings https://github.com/cldwalker/lein-spell
         [lein-deps-tree "0.1.2"] ; Print a tree of project dependencies https://github.com/the-kenny/lein-deps-tree
         [lein-cljfmt "0.2.0"] ; Code formatting https://github.com/weavejester/cljfmt
@@ -112,7 +112,7 @@
     "start!" ["with-profile" "prod" "do" "init-db," "run"] ; start an FCMS server in production
     "spell!" ["spell" "-n"] ; check spelling in docs and docstrings
     "bikeshed!" ["bikeshed" "-v" "-m" "120"] ; code check with max line length warning of 120 characters
-    "ancient" ["with-profile" "dev" "do" "ancient" ":allow-qualified," "ancient" ":plugins" ":allow-qualified"] ; check for out of date dependencies
+    "ancient!" ["do" "ancient" ":allow-qualified," "ancient" ":plugins" ":allow-qualified"] ; check for out of date dependencies
   }

   ;; ----- Code check configuration -----


Alpha 2 - includes nrepl 0.2.0-beta1

Alpha 2 - includes nrepl 0.2.0-beta1

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject reply "0.1.0-SNAPSHOT"
+(defproject reply "0.1.0-alpha2"
   :description "REPL-y: A fitter, happier, more productive REPL for Clojure."
   :dependencies [[org.clojure/clojure "1.3.0"]
                  [org.clojars.trptcolin/jline "2.6-alpha1"]


Bump version

Bump version

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject kinesis-logger "0.1.0"
+(defproject kinesis-logger "0.1.1"
   :description "Simple logger for Kinesis events, mainly for debugging purposes"
   :url "https://github.com/komoot/kinesis-logger"
   :license {:name "Eclipse Public License"