Finished Count Odds problem

Finished Count Odds problem

--- src/clojush/problems/software/count_odds.clj
+++ src/clojush/problems/software/count_odds.clj
@@ -65,15 +65,13 @@
 ;;Can make Count Odds test data like this:
 ;(test-and-train-data-from-domains count-odds-data-domains)

-;;TMH DONE TO HERE
-
 ; Helper function for error function
 (defn count-odds-test-cases
   "Takes a sequence of inputs and gives IO test cases of the form
    [input output]."
   [inputs]
   (map #(vector %
-                (= (first %) (vec (reverse (second %)))))
+                (count (filter odd? %)))
        inputs))

 ; Define error function. For now, each run uses different random inputs
@@ -83,7 +81,7 @@
   [data-domains]
   (let [[train-cases test-cases] (map count-odds-test-cases
                                       (test-and-train-data-from-domains data-domains))]
-    (when false ;; Change to false to not print test cases
+    (when true ;; Change to false to not print test cases
       (doseq [[i case] (map vector (range) train-cases)]
         (println (format "Train Case: %3d | Input/Output: %s" i (str case))))
       (doseq [[i case] (map vector (range) test-cases)]
@@ -96,24 +94,24 @@
       ([program data-cases print-outputs]
         (let [behavior (atom '())
               errors (doall
-                       (for [[[input1 input2] correct-output] (case data-cases
-                                                                           :train train-cases
-                                                                           :test test-cases
-                                                                           [])]
+                       (for [[input1 correct-output] (case data-cases
+                                                                  :train train-cases
+                                                                  :test test-cases
+                                                                  [])]
                          (let [final-state (run-push program
                                                      (->> (make-push-state)
-                                                       (push-item input2 :input)
                                                        (push-item input1 :input)))
-                               result (top-item :boolean final-state)]
+                               result (top-item :integer final-state)]
                            (when print-outputs
-                             (println (format "Correct output: %5b | Program output: %5b" correct-output result)))
+                             (println (format "Correct output: %2d | Program output: %s" correct-output (str result))))
                            ; Record the behavior
                            (when @global-print-behavioral-diversity
                              (swap! behavior conj result))
-                           ; Error is boolean error
-                           (if (= result correct-output)
-                             0
-                             1))))]
+                           ; Error is integer error
+                           (if (number? result)
+                             (abs (- result correct-output)) ; distance from correct integer
+                             1000) ; penalty for no return value
+                           )))]
           (when @global-print-behavioral-diversity
             (swap! population-behaviors conj @behavior))
           errors)))))
@@ -146,9 +144,9 @@
 (def argmap
   {:error-function (count-odds-error-function count-odds-data-domains)
    :atom-generators count-odds-atom-generators
-   :max-points 300
-   :max-points-in-initial-program 150
-   :evalpush-limit 600
+   :max-points 500
+   :max-points-in-initial-program 250
+   :evalpush-limit 1500
    :population-size 1000
    :max-generations 300
    :parent-selection :lexicase


Ensure there's at least 1 command processing thread

The default setting for the number of command processing threads is set to half
the number of cores in your system (rounded down due to integer division). That
works great until you've got a system with only one core, in which case we ended
up starting 0 command-processing threads. This patch ensures a minumim of one
command processing thread.

It's 2012...who's still rocking a single core? :)

Signed-off-by: Deepak Giridharagopal <d11186354d1ef01ca06ae37d7e23e827da13e85f@puppetlabs.com>

--- src/com/puppetlabs/puppetdb/cli/services.clj
+++ src/com/puppetlabs/puppetdb/cli/services.clj
@@ -106,14 +106,17 @@
 (defn configure-commandproc-threads
   "Update the supplied config map with the number of
   command-processing threads to use. If no value exists in the config
-  map, default to half the number of CPUs."
+  map, default to half the number of CPUs. If only one CPU exists, we
+  will use one command-processing thread."
   [config]
   {:pre [(map? config)]
-   :post [(map? %)]}
+   :post [(map? %)
+          (pos? (get-in % [:command-processing :threads]))]}
   (let [default-nthreads (-> (Runtime/getRuntime)
                              (.availableProcessors)
                              (/ 2)
-                             (int))]
+                             (int)
+                             (max 1))]
     (update-in config [:command-processing :threads] #(or % default-nthreads))))

 (defn configure-web-server


cleanup

cleanup

--- src/babel/generate.cljc
+++ src/babel/generate.cljc
@@ -70,9 +70,7 @@
            (assoc-in accum
                      (first paths)
                      (first val-at-paths))]
-       (if (not (empty? (first paths)))
-         (dissoc-paths result [(first paths)] model)
-         result))
+       (dissoc-paths result [(first paths)] model))
      (rest paths)
      (rest val-at-paths)
      model)))
@@ -99,10 +97,12 @@
             (map (fn [bolt-and-comps]
                    (log/debug (str "bolt-and-comps: " ((:morph-ps model) (get bolt-and-comps []))))
                    (do-defaults
-                    (do-assocs (get bolt-and-comps [])
-                               (keys bolt-and-comps)
-                               (vals bolt-and-comps)
-                               model)
+                    (let [bolt (get bolt-and-comps [])
+                          bolt-and-comps (dissoc bolt-and-comps [])]
+                      (do-assocs bolt
+                                 (keys bolt-and-comps)
+                                 (vals bolt-and-comps)
+                                 model))
                     model))
                  all-of-them))))


move intersection-with-identity to bottom

--- src/babel/generate.cljc
+++ src/babel/generate.cljc
@@ -26,6 +26,7 @@
 (declare candidate-parents)
 (declare exception)
 (declare find-comp-paths-in)
+(declare intersection-with-identity)
 (declare lazy-mapcat)
 (declare lazy-shuffle)
 (declare lexemes-before-phrases)
@@ -79,20 +80,6 @@
       (->
        (lightning-bolts language-model spec 0 total-depth :max-total-depth max-total-depth)
        (add-all-comps language-model total-depth false max-total-depth)))))
-
-(defn intersection-with-identity [set1 set2]
-  (if (> (count set1)
-         (count set2))
-    (filter (fn [member2]
-              (some (fn [member1]
-                      (identical? member1 member2))
-                    set1))
-            set2)
-    (filter (fn [member1]
-              (some (fn [member2]
-                      (identical? member1 member2))
-                    set2))
-            set1)))

 (defn lightning-bolts [language-model spec depth total-depth
                        & {:keys [max-total-depth]
@@ -393,3 +380,16 @@
       {:subcat/:1/:cat subcat1
        :subcat/:1/:agr (get-in spec [:synsem :subcat :1 :agr])}))))

+(defn intersection-with-identity [set1 set2]
+  (if (> (count set1)
+         (count set2))
+    (filter (fn [member2]
+              (some (fn [member1]
+                      (identical? member1 member2))
+                    set1))
+            set2)
+    (filter (fn [member1]
+              (some (fn [member2]
+                      (identical? member1 member2))
+                    set2))
+            set1)))


more logging improvements

more logging improvements

--- src/babel/generate.cljc
+++ src/babel/generate.cljc
@@ -187,11 +187,17 @@
                                (empty? phrasal-complements))
                           (let [cat (get-in spec [:synsem :cat] :top)
                                 pred (get-in spec [:synsem :sem :pred] :top)
-                                subcat1-cat (get-in spec [:synsem :subcat :1 :cat] :none)
-                                subcat1-pred (get-in spec [:synsem :subcat :1 :sem :pred] :none)]
-                            (log/warn (str "failed to generate both phrasal or lexical complements for rule: "
+                                subcat1-cat
+                                (if (empty? (get-in spec [:synsem :subcat]))
+                                  "(empty)"
+                                  (get-in spec [:synsem :subcat :1 :cat] :no-cat))
+                                subcat1-pred
+                                (if (empty? (get-in spec [:synsem :subcat]))
+                                  "(empty)"
+                                  (get-in spec [:synsem :subcat :1 :sem :pred] :no-pred))]
+                            (log/warn (str "could generate neither phrasal nor lexical complements for parent: "
                                            (get-in bolt (concat (butlast path) [:rule]) :norule-wtf) " "
-                                           "with "
+                                           "with complement having: "
                                            "cat: " cat "; "
                                            "pred: " pred "; "
                                            "subcat1 cat: " subcat1-cat "; "


Update views.clj

Update views.clj

--- src/briefcase/views.clj
+++ src/briefcase/views.clj
@@ -56,7 +56,7 @@
 (defn- old-entry-warning
   "Generates a warning for entries that are more than 6 months or so old"
   [data]
-  (when (before? (:date data) six-months-ago)
+  (when (before? (from-date (:date data)) six-months-ago)
     (hiccup.core/html
       [:blockquote.warning "This post is over 6 months old.
       	Some details, especially technical, may have changed


Update protocols.cljc

Update protocols.cljc

--- src/cats/protocols.cljc
+++ src/cats/protocols.cljc
@@ -73,8 +73,8 @@
     "Applies the function(s) inside af's context to the value(s)
      inside av's context while preserving the context.")
   (-pure [app v]
-    "Takes any context or monadic value (app) and any value (v), and puts
-     the value v in the most minimal context (normally mempty) of same type of app"))
+    "Takes any context or monadic value `app` and any value `v`, and puts
+     the value `v` in the most minimal context (normally `mempty`) of same type of app"))

 (defprotocol Foldable
   "Abstraction of data structures that can be folded to a summary value."


updating some stuff

updating some stuff

--- resources/leiningen/new/closp/clj/routes/cc.clj
+++ resources/leiningen/new/closp/clj/routes/cc.clj
@@ -1,22 +1,41 @@
 (ns {{ns}}.routes.cc
   (:require [compojure.core :refer [routes GET POST]]
+            [schema.core :as s]
+            [ring.util.response :refer [response status]]
             [{{ns}}.layout :as layout]
             [{{ns}}.service.cc :as serv-cc]
-            [ring.util.response :refer [response]])
-  (:import (java.io File)))
+            [{{ns}}.closp-schema :as st])
+
+  (:import (java.io File)
+    (java.util UUID)) )

 (defn cc-page []
   (layout/render "cc/index.html"))

-(defn initial-data [config]
-  (let [files (->> (:closp-definitions config)
-                   (File.)
-                   (file-seq)
-                   (filter #(.isFile %)))
-        files-beautified (map (fn [f] {:name (.getName f) :content (slurp f)}) files)]
-    (response {:ex-entities files-beautified :loaded true})))
+(s/defn initial-data :- {:ex-entities st/existing-entities}
+        [config :- s/Any]
+        (let [files (->> (:closp-definitions config)
+                         (File.)
+                         (file-seq)
+                         (filter #(.isFile %)))
+              files-beautified (map (fn [f] {:name (.getName f) :content (slurp f)}) files)]
+          (response {:ex-entities files-beautified :loaded true})))
+
+
+
+(s/defn add-new-entity :- s/Any
+        [description :- s/Str config :- s/Any]
+        (try
+          (spit (File. (str (:closp-definitions config) "/"
+                            (get-in description [:name] (.toString (UUID/randomUUID))) ".edn"))
+                (serv-cc/web-entity-desc->entity-desc description))
+          (response {:ok "fine"})
+          (catch Exception e
+            (status 500 (response {:error "Something failed while saving the entity"}))))
+        )

 (defn cc-routes [config]
   (routes
     (GET "/admin/cc" [] (cc-page))
-    (GET "/admin/cc/initial" [] (initial-data config))))
+    (GET "/admin/cc/entities" [] (initial-data config))
+    (POST "/admin/cc/entities" req (add-new-entity (:params req) config))))


Reset textarea after message posted

Reset textarea after message posted

--- src/om_chat/components/message_composer.cljs
+++ src/om_chat/components/message_composer.cljs
@@ -14,7 +14,8 @@
   (condp == (.-keyCode e)
     ENTER_KEY
     (let [msg-text (or (om/get-state c :edit-text) "")]
-      (on-new-msg id msg-text)
+      (if-not (= msg-text "") (on-new-msg id msg-text))
+      (om/update-state! c assoc :edit-text "")
       (doto e (.preventDefault) (.stopPropagation)))
     nil))


Reset peer state before switching tasks.

--- src/onyx/scheduling/common_job_scheduler.clj
+++ src/onyx/scheduling/common_job_scheduler.clj
@@ -53,10 +53,11 @@
                                   (:jobs replica)))]
       (if (and (seq peer-pool) (seq candidate-jobs))
         (recur (rest peer-pool)
-               (let [removed (common/remove-peers replica (first peer-pool))]
-                 (update-in removed [:allocations
-                                     (ffirst candidate-jobs)
-                                     (second (first candidate-jobs))]
+               (let [removed (common/remove-peers replica (first peer-pool))
+                     reset-state (assoc-in replica [:peer-state (first peer-pool)] :idle)]
+                 (update-in reset-state [:allocations
+                                         (ffirst candidate-jobs)
+                                         (second (first candidate-jobs))]
                             conj (first peer-pool))))
         replica))))


Angle brackets need dashes so they won't disappear.


Add handler to start load balancer

Add handler to start load balancer

--- router/src/router/core.clj
+++ router/src/router/core.clj
@@ -25,6 +25,7 @@
 (defroutes app-routes
   (GET "/status" [] (response (str @services)))
   (POST "/register" {body :body} (register-service body))
+  (POST "/start" [] (h/start-haproxy! @services))
   (route/not-found "Not Found"))

 (def app


Make sure systems-box is initialized before boxes do a first call

--- systems/mail/src/containium/systems/mail.clj
+++ systems/mail/src/containium/systems/mail.clj
@@ -7,9 +7,8 @@
   (:require [containium.systems :refer (require-system Startable)]
             [containium.systems.config :as config :refer (Config)]
             [containium.systems.logging :refer (SystemLogger refer-logging)]
-            [containium.modules.boxes :refer (call-in-root)]
+            [containium.modules.boxes :refer (call-in-root systems-box)]
             [postal.core :as postal]
-            [classlojure.core :refer (with-classloader)]
             [clojure.xml :as xml]
             [clojure.zip :as zip]
             [clojure.java.io :as io :refer (resource as-file)])
@@ -56,6 +55,7 @@
       (let [config (config/get-config (require-system Config systems) :postal)
             logger (require-system SystemLogger systems)]
         (info logger "Starting Postal system, using config:" config)
+        @systems-box
         (Postal. logger config)))))


adding the beginning of orchestration for console

--- src/cartagena/core.clj
+++ src/cartagena/core.clj
@@ -175,13 +175,31 @@
        default
        (str/lower-case input)))))

-(defn prompt-move
+(defn prompt-play-card
+  "Display card play options for current player, capture input, perform action"
+  []
+  (println "playing card!"))
+
+(defn prompt-move-back
+  "Display move options for current player, capture input, perform action"
+  []
+  (println "moving!"))
+
+(defn prompt-action
   "Gets input for current player"
   [game-state]
-  (pp/pprint game-state))
+  (let [active-player (filter #(= (:current-player game-state) (:name %)) (:players game-state))]
+    (println "active player" active-player)
+    (println "You have" (:actions-left game-state) "actions left!  Choose! ([1] is default)")
+    (println "[1] Play card")
+    (println "[2] Move back")
+    (let [current-action (get-input "1")]
+      (if (= "1" current-action)
+        (prompt-play-card)
+        (prompt-move-back)))))

 (defn -main
   "Calls the function to get the number of players... goes on from there"
   [& args]
   (new-game! [{:name "tanya" :color :orange} {:name "rusty" :color :black}])
-  (prompt-move @game-state))+  (prompt-action @game-state))


Fix grifter fixes mtgred/netrunner#370

Fix grifter fixes mtgred/netrunner#370

--- src/clj/game/cards.clj
+++ src/clj/game/cards.clj
@@ -1046,9 +1046,9 @@
    "Grifter"
    {:events {:runner-turn-ends
              {:effect #(let [ab (if (get-in @%1 [:runner :register :successful-run])
-                                  {:effect (effect (gain [:credit 1])) :msg "gain 1 [Credits]"}
+                                  {:effect (effect (gain :credit 1)) :msg "gain 1 [Credits]"}
                                   {:effect (effect (trash %3)) :msg "trash Grifter"})]
-                         (resolve-ability %1 %2 ab %3 nil))}}}
+                         (resolve-ability %1 %2 ab %3 %4))}}}

    "Grimoire"
    {:effect (effect (gain :memory 2)) :leave-play (effect (lose :memory 2))


track expired

track expired

--- src/cljs/app/core.cljs
+++ src/cljs/app/core.cljs
@@ -55,23 +55,23 @@
        (- utime (* 10 1000)))
     :warn))

-(defn expired-devices [expires]
-  (filter
-   (fn [[_ device]]
-     (< (:utime device) expires))
-   @devices-var))
-
 (defn track-devices [& [alarm]]
   (let [in (:in-chan (pubnub/tunnel))]
-    (go-loop []
-      (when-let [val (<! in)]
+    (go-loop [active-devices {}]
+      (when-let [msg (<! in)]
         (swap! devices-var
-               #(update % (:id val) (fn [_] val)))
-        (let [utime (<! (pubnub/fetch-time))]
-          (doseq [[_ device] (expired-devices (- utime expiration))]
-            #_ (alarm)
-            #_ (println "[EXPIRED]" device (- utime expiration) (:utime device))))
-        (recur)))))
+               #(assoc % (:id msg) msg))
+        (let [utime (<! (pubnub/fetch-time))
+              expires (- utime expiration)
+              expire? #(< % expires)]
+          (doseq [[id recent] active-devices
+                  :when (expire? recent)]
+            #_ (if alarm (alarm))
+            (println "[EXPIRED]" id expires recent))
+          (recur (assoc (apply dissoc active-devices
+                               (remove (comp expire? second)
+                                       active-devices))
+                        (:id msg) utime) ))))))

 (defn devices-cursor
   ([devices utime]


Add color picker to element options.

Add color picker to element options.

--- src/uxbox/ui/workspace/options.cljs
+++ src/uxbox/ui/workspace/options.cljs
@@ -7,6 +7,7 @@
             [uxbox.ui.icons :as i]
             [uxbox.ui.mixins :as mx]
             [uxbox.ui.dom :as dom]
+            [uxbox.ui.colorpicker :refer (colorpicker)]
             [uxbox.ui.workspace.base :as wb]
             [uxbox.util.data :refer (parse-int parse-float)]))

@@ -47,24 +48,33 @@

 (defmethod -render-menu :menu/fill
   [menu own shape]
-  (letfn [(on-color-change [event]
-            (let [value (dom/event->value event)
-                  sid (:id shape)]
-              (-> (dw/update-shape-fill sid {:fill value})
+  (letfn [(change-fill [value]
+            (println value)
+            (let [sid (:id shape)]
+              (-> (dw/update-shape-fill sid value)
                   (rs/emit!))))
+          (on-color-change [event]
+            (let [value (dom/event->value event)]
+              (change-fill {:fill value})))
           (on-opacity-change [event]
             (let [value (dom/event->value event)
-                  value (parse-float value 1)
-                  sid (:id shape)]
-              (-> (dw/update-shape-fill sid {:opacity value})
-                  (rs/emit!))))]
+                  value (parse-float value 1)]
+              (change-fill {:opacity value})))
+          (on-color-picker-event [{:keys [hex]}]
+            (change-fill {:fill hex}))]
     (html
      [:div.element-set {:key (str (:id menu))}
       [:div.element-set-title (:name menu)]
       [:div.element-set-content
        ;; SLIDEBAR FOR ROTATION AND OPACITY
        [:span "Color"]
-       [:div.element-color-picker
+       #_(colorpicker (constantly nil))
+
+       (colorpicker {:picker {:width 165 :height 165}
+                     :bar {:width 15 :height 165}
+                     :callback on-color-picker-event})
+
+       #_[:div.element-color-picker
         [:div.color-picker-body
           [:img {:src "images/color-gamma.png", :border "none"}]]
         [:div.color-picker-bar


CLJS-391: add some missing IEmptyableCollection impls

--- src/cljs/cljs/core.cljs
+++ src/cljs/cljs/core.cljs
@@ -597,6 +597,9 @@
   ICollection
   (-conj [coll o] (cons o coll))

+  IEmptyableCollection
+  (-empty [coll] cljs.core.List/EMPTY)
+
   IReduce
   (-reduce [coll f]
     (if (counted? a)
@@ -659,6 +662,8 @@
     ([array f start]
        (ci-reduce array f start))))

+(declare with-meta)
+
 (deftype RSeq [ci i meta]
   Object
   (toString [this]
@@ -691,6 +696,9 @@
   ICollection
   (-conj [coll o]
     (cons o coll))
+
+  IEmptyableCollection
+  (-empty [coll] (with-meta cljs.core.List/EMPTY meta))

   IHash
   (-hash [coll] (hash-coll coll)))
@@ -1910,6 +1918,9 @@
   ICollection
   (-conj [this o]
     (cons o this))
+
+  IEmptyableCollection
+  (-empty [coll] (with-meta cljs.core.List/EMPTY meta))

   IHash
   (-hash [coll] (caching-hash coll hash-coll __hash)))
@@ -4861,6 +4872,9 @@
   ICollection
   (-conj [coll o] (cons o coll))

+  IEmptyableCollection
+  (-empty [coll] (with-meta cljs.core.List/EMPTY meta))
+
   IHash
   (-hash [coll] (caching-hash coll hash-coll __hash))


minor style cleanup

minor style cleanup

--- src/cljs/cljs/core.cljs
+++ src/cljs/cljs/core.cljs
@@ -5779,9 +5779,8 @@
 (defn keys
   "Returns a sequence of the map's keys."
   [hash-map]
-  (let [mseq (seq hash-map)]
-    (when-not (nil? mseq)
-      (KeySeq. mseq nil))))
+  (when-let [mseq (seq hash-map)]
+    (KeySeq. mseq nil)))

 (defn key
   "Returns the key of the map entry."
@@ -5840,9 +5839,8 @@
 (defn vals
   "Returns a sequence of the map's values."
   [hash-map]
-  (let [mseq (seq hash-map)]
-    (when-not (nil? mseq)
-      (ValSeq. mseq nil))))
+  (when-let [mseq (seq hash-map)]
+    (ValSeq. mseq nil)))

 (defn val
   "Returns the value in the map entry."


add space to ISeqable error message in cljs.core/seq

--- src/cljs/cljs/core.cljs
+++ src/cljs/cljs/core.cljs
@@ -488,7 +488,7 @@
       (native-satisfies? ISeqable coll)
       (-seq coll)

-      :else (throw (js/Error. (str coll "is not ISeqable"))))))
+      :else (throw (js/Error. (str coll " is not ISeqable"))))))

 (defn first
   "Returns the first item in the collection. Calls seq on its


Move channel loading into channel-list

Move channel loading into channel-list

--- src/cljs/virt/home.cljs
+++ src/cljs/virt/home.cljs
@@ -29,11 +29,37 @@

 (defn channel-list [{:keys [params data]} owner]
   (reify
+    om/IInitState
+    (init-state [_]
+      {:loading false})
+    om/IWillMount
+    (will-mount [_]
+      (when (empty? (:channels data))
+        (om/set-state! owner :loading true))
+      (go
+        (let [loc (<! (get-geolocation))]
+          (om/update! data [:geolocation] loc)
+          (let [response (<! (http/get "/api/channels" {:query-params loc}))]
+            (om/update! data [:channels] (:body response))))
+        (om/set-state! owner :loading false)
+        (om/set-state! owner :poll-interval
+          (js/setInterval
+            #(go
+               (let [loc (<! (get-geolocation))]
+                 (om/update! data [:geolocation] loc)
+                 (let [response (<! (http/get "/api/channels" {:query-params loc}))]
+                   (om/update! data [:channels] (:body response)))))
+            3000))))
+    om/IWillUnmount
+    (will-unmount [_]
+      (js/clearInterval (om/get-state owner :poll-interval)))
     om/IRenderState
     (render-state [_ {:keys [comm]}]
-      (dom/div nil
-        (apply dom/ul #js {:className "virt-list"}
-          (om/build-all list-item data {:init-state {:comm comm}}))))))
+      (if (om/get-state owner :loading)
+        (om/build loading nil)
+        (dom/div nil
+          (apply dom/ul #js {:className "virt-list"}
+            (om/build-all list-item (:channels data) {:init-state {:comm comm}})))))))

 (defn new-channel [_ owner]
   (reify
@@ -53,26 +79,12 @@
   (reify
     om/IInitState
     (init-state [_]
-      {:comm (chan)
-       :loading true})
+      {:comm (chan)})
     om/IWillMount
     (will-mount [_]
       (let [comm (om/get-state owner :comm)
             core-comm (om/get-state owner :core-comm)]
         (go
-          (let [loc (<! (get-geolocation))]
-            (om/update! data [:geolocation] loc)
-            (let [response (<! (http/get "/api/channels" {:query-params loc}))]
-              (om/update! data [:channels] (:body response))))
-          (om/set-state! owner :loading false)
-          (om/set-state! owner :poll-interval
-            (js/setInterval
-              #(go
-                 (let [loc (<! (get-geolocation))]
-                   (om/update! data [:geolocation] loc)
-                   (let [response (<! (http/get "/api/channels" {:query-params loc}))]
-                     (om/update! data [:channels] (:body response)))))
-              3000))
           (while true
             (let [[msg msg-data] (<! comm)]
               (case msg
@@ -85,14 +97,9 @@
                   (om/transact! data [:channels] (fn [cs] (conj cs (:body response))))
                   (put! comm [:navigate [:back]]))
                 (>! core-comm [msg msg-data])))))))
-    om/IWillUnmount
-    (will-unmount [_]
-      (js/clearInterval (om/get-state owner :poll-interval)))
     om/IRenderState
     (render-state [_ {:keys [comm]}]
       (let [m {:init-state {:comm comm}}]
-        (if (om/get-state owner :loading)
-          (om/build loading nil)
-          (case page
-            ::new (om/build new-channel nil m)
-            ::home (om/build channel-list {:params params :data (:channels data)} m)))))))
+        (case page
+          ::new (om/build new-channel nil m)
+          ::home (om/build channel-list {:params params :data data} m))))))


use proper domain in home examples

use proper domain in home examples

--- src/cljsbin/routes.cljs
+++ src/cljsbin/routes.cljs
@@ -13,7 +13,7 @@

 (declare routes)

-(defn render-endpoint
+(defn- render-endpoint
   "Take the route url and spec and render an index entry based on its metadata."
   [[url route]]
   (let [{:keys [no-display href-query display-query href-params doc]}
@@ -30,6 +30,13 @@
            [:a {:data-bare-link "true", :href href-url} [:code display-url]]
            [:code display-url])
          (str " " doc)]))))
+
+(defn- absolute-path
+  [req path]
+  (str (-> req :scheme name)
+       "://"
+       (get-in req [:headers "host"])
+       path))

 (defn home
   "This page."
@@ -60,13 +67,13 @@
            [:a {:href "https://github.com/macchiato-framework/"} "Macchiato web framework"]
            " for ClojureScript."]
           [:h2#EXAMPLES "EXAMPLES"]
-          [:h3#-curl-http-cljsbin-org-ip "$ curl http://cljsbin.org/ip"]
+          [:h3#-curl-http-cljsbin-org-ip (str "$ curl "  (absolute-path req "/ip"))]
           [:pre [:code "{\"origin\": \"24.127.96.129\"}\n"]]
-          [:h3#-curl-http-cljsbin-org-user-agent "$ curl http://cljsbin.org/user-agent"]
+          [:h3#-curl-http-cljsbin-org-user-agent (str "$ curl "  (absolute-path req "/user-agent"))]
           [:pre [:code "{\"user-agent\": \"curl/7.19.7 (universal-apple-darwin10.0) libcurl/7.19.7 OpenSSL/0.9.8l zlib/1.2.3\"}\n"]]
-          [:h3#-curl-http-cljsbin-org-get "$ curl http://cljsbin.org/get"]
-          [:pre [:code "{\n   \"args\": {},\n   \"headers\": {\n      \"Accept\": \"*/*\",\n      \"Connection\": \"close\",\n      \"Content-Length\": \"\",\n      \"Content-Type\": \"\",\n      \"Host\": \"cljsbin.org\",\n      \"User-Agent\": \"curl/7.19.7 (universal-apple-darwin10.0) libcurl/7.19.7 OpenSSL/0.9.8l zlib/1.2.3\"\n   },\n   \"origin\": \"24.127.96.129\",\n   \"url\": \"http://cljsbin.org/get\"\n}\n"]]
-          [:h3#-curl-I-http-cljsbin-org-status-418 "$ curl -I http://cljsbin.org/status/418"]
+          [:h3#-curl-http-cljsbin-org-get (str "$ curl "  (absolute-path req "/get"))]
+          [:pre [:code (str "{\n   \"args\": {},\n   \"headers\": {\n      \"Accept\": \"*/*\",\n      \"Connection\": \"close\",\n      \"Content-Length\": \"\",\n      \"Content-Type\": \"\",\n      \"Host\": \"" (get-in req [:headers "host"]) "\",\n      \"User-Agent\": \"curl/7.19.7 (universal-apple-darwin10.0) libcurl/7.19.7 OpenSSL/0.9.8l zlib/1.2.3\"\n   },\n   \"origin\": \"24.127.96.129\",\n   \"url\": \"" (absolute-path req "/get") "\"\n}\n")]]
+          [:h3#-curl-I-http-cljsbin-org-status-418 (str "$ curl -I " (absolute-path req "/status/418"))]
           [:pre [:code "HTTP/1.1 418 I'M A TEAPOT\nServer: nginx/0.7.67\nDate: Mon, 13 Jun 2011 04:25:38 GMT\nConnection: close\nx-more-info: http://tools.ietf.org/html/rfc2324\nContent-Length: 135\n"]]
           [:h2#Installing-and-running "Installing and running from GitHub"]
           [:p "You can install httpbin from the source at GitHub and run it with leiningen and node:"]
@@ -149,13 +156,6 @@
           (r/found)
           (res))
       (raise (js/Error "Not a valid cache age.")))))
-
-(defn- absolute-path
-  [req path]
-  (str (-> req :scheme name)
-       "://"
-       (get-in req [:headers "host"])
-       path))

 (defn ^{:href-params {:n 6}} absolute-redirect
   "302 absolyte redirects n times."


CMR-119: Changed port for API in tests back to 3000 instead of 3001 used for tcp-mon debugging.

--- int_test/cmr/metadata_db/utility.clj
+++ int_test/cmr/metadata_db/utility.clj
@@ -19,7 +19,7 @@
 (defn get-concept-by-id-and-revision
   "Make a get to retrieve a concept by concept-id and revision."
   [concept-id revision-id]
-  (let [response (client/get (str "http://localhost:3001/concepts/" concept-id "/" revision-id)
+  (let [response (client/get (str "http://localhost:3000/concepts/" concept-id "/" revision-id)
                              {:accept :json
                               :throw-exceptions false})
         status (:status response)]
@@ -31,7 +31,7 @@
 (defn get-concept-by-id
   "Make a get to retrieve a concept by concept-id."
   [concept-id]
-  (let [response (client/get (str "http://localhost:3001/concepts/" concept-id)
+  (let [response (client/get (str "http://localhost:3000/concepts/" concept-id)
                              {:accept :json
                               :throw-exceptions false})
         status (:status response)]
@@ -45,7 +45,7 @@
   "Make a post request to save a concept without JSON encoding the concept.  Returns a map with
   status, revision-id, and a list of error messages"
   [concept]
-  (let [response (client/post "http://localhost:3001/concepts"
+  (let [response (client/post "http://localhost:3000/concepts"
                               {:body (cheshire/generate-string concept)
                                :body-encoding "UTF-8"
                                :content-type :json
@@ -60,7 +60,7 @@
 (defn reset-database
   "Make a request to reset the database by clearing out all stored concepts."
   []
-  (let [response (client/delete "http://localhost:3001/concepts"
+  (let [response (client/delete "http://localhost:3000/concepts"
                                 {:throw-exceptions false})
         status (:status response)]
     status))


CMR-1419: Removed commented code

CMR-1419: Removed commented code

--- system-int-test/test/cmr/system_int_test/search/concept_metadata_search_test.clj
+++ system-int-test/test/cmr/system_int_test/search/concept_metadata_search_test.clj
@@ -45,7 +45,7 @@

 (defmethod result-matches? :default
   [format-key umm response]
-  (let [expected (umm/umm->xml umm format-key);(:metadata (d/item->metadata-result false format-key umm))
+  (let [expected (umm/umm->xml umm format-key)
         metadata-xml (:body response)]
     (is (= expected metadata-xml))))


Version 0.11.0-rc2

Version 0.11.0-rc2

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


Version 0.4.31

Version 0.4.31

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject yetibot.core "0.4.31-SNAPSHOT"
+(defproject yetibot.core "0.4.31"
   :description "Core yetibot utilities, extracted for shared use among yetibot
                 and its various plugins"
   :url "https://github.com/yetibot/yetibot.core"


Update dependencies

Update dependencies

--- project.clj
+++ project.clj
@@ -7,14 +7,14 @@
                  [ring "1.8.0"]
                  [ring/ring-defaults "0.3.2"]
                  [org.postgresql/postgresql "42.2.9"]
-                 [org.clojure/java.jdbc "0.7.10"]
+                 [org.clojure/java.jdbc "0.7.11"]
                  [honeysql "0.9.8"]
                  [clj-time "0.15.2"]
                  [cheshire "5.9.0"]
                  [selmer "1.12.18"]
                  [clj-http "3.10.0"]
                  [org.clojure/tools.logging "0.5.0"]
-                 [org.slf4j/slf4j-log4j12 "1.7.29"]
+                 [org.slf4j/slf4j-log4j12 "1.7.30"]
                  [com.yubico/yubico-validation-client2 "3.0.5"]
                  [buddy/buddy-hashers "1.4.0"]
                  [buddy/buddy-auth "2.2.0"]


Bump version number, improve description

--- project.clj
+++ project.clj
@@ -1,5 +1,5 @@
-(defproject degasolv/degasolv "1.1.1-SNAPSHOT"
-  :description "Dependency resolver with an eye toward building software."
+(defproject degasolv/degasolv "1.2.0"
+  :description "Dependency tracker with an eye toward building and shipping software."
   :url "http://github.com/djhaskin987/degasolv"
   :license {:name "Eclipse Public License"
             :url "http://www.eclipse.org/legal/epl-v10.html"}


Update versions

Update versions

--- project.clj
+++ project.clj
@@ -20,8 +20,8 @@

                         :immutant                       "1.0.3-SNAPSHOT"
                         :ring                           "1.2.1"
-                        :jbossas                        "7.2.x.slim.incremental.12"
-                        :polyglot                       "1.x.incremental.61"
+                        :jbossas                        "7.2.x.slim.incremental.14"
+                        :polyglot                       "1.19.0"

                         org.immutant/immutant-parent               :immutant
                         org.immutant/immutant-modules-parent       :immutant


use 4g heap

use 4g heap

--- project.clj
+++ project.clj
@@ -4,6 +4,7 @@
   :license {:name "Eclipse Public License"
             :url "http://www.eclipse.org/legal/epl-v10.html"}
   :plugins [[lein-marginalia "0.8.0"]]
+  :jvm-opts ["-Xmx4g"]
   :dependencies [[org.clojure/clojure "1.6.0"]
                  [org.apache.lucene/lucene-core "4.9.1"]
                  [org.apache.lucene/lucene-highlighter "4.9.1"]


Set aot all

Set aot all

--- project.clj
+++ project.clj
@@ -6,5 +6,6 @@
   :source-paths ["src/clj"]
   :java-source-paths ["src/java"]
   :javac-options ["-Xlint:deprecation"]
+  :aot :all
   :dependencies [[org.clojure/clojure "1.10.0"]
                  [org.clojure/core.async "0.3.443"]])


Release 5.10.1

Release 5.10.1

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject cheshire "5.10.1-SNAPSHOT"
+(defproject cheshire "5.10.1"
   :description "JSON and JSON SMILE encoding, fast."
   :url "https://github.com/dakrone/cheshire"
   :license {:name "The MIT License"


We need data.xml for dtbook generation

We need data.xml for dtbook generation

--- project.clj
+++ project.clj
@@ -8,7 +8,8 @@
                  [medley "0.7.0"]
                  [prismatic/schema "1.0.3"]
                  [clj-time "0.11.0"]
-                 [comb "0.1.0" :exclusions [org.clojure/clojure]]]
+                 [comb "0.1.0" :exclusions [org.clojure/clojure]]
+                 [org.clojure/data.xml "0.0.8"]]
   :plugins [[cider/cider-nrepl "0.10.0-SNAPSHOT"]
             [refactor-nrepl "2.0.0-SNAPSHOT"]]
   :main ^:skip-aot catalog.core


lein-release plugin: bumped version from 0.7.1 to 0.7.2-SNAPSHOT for next development cycle

--- project.clj
+++ project.clj
@@ -1,7 +1,7 @@
 (def tk-version "0.4.3")
 (def ks-version "0.7.2")

-(defproject puppetlabs/trapperkeeper-webserver-jetty9 "0.7.1"
+(defproject puppetlabs/trapperkeeper-webserver-jetty9 "0.7.2-SNAPSHOT"
   :description "We are trapperkeeper.  We are one."
   ;; Abort when version ranges or version conflicts are detected in
   ;; dependencies. Also supports :warn to simply emit warnings.


Make for a more efficient 'lein run' in prod.

--- project.clj
+++ project.clj
@@ -36,12 +36,13 @@
     [ring/ring-core "1.6.3"]
     [ring/ring-codec "1.1.0"]
     [ring/ring-defaults "0.3.1"]]
+  :jvm-opts ["-XX:-OmitStackTraceInFastThrow" "-Xms2g" "-Xmx2g"]
   :main cmr.opendap.core
   :aot [cmr.opendap.core]
   :profiles {
     :ubercompile {
       :aot :all}
-    :dev {
+    :local {
       :dependencies [
         [clojusc/dev-system "0.1.0"]
         [org.clojure/tools.namespace "0.2.11"]
@@ -50,7 +51,8 @@
         [lein-project-version "0.1.0"]
         [lein-shell "0.5.0"]
         [venantius/ultra "0.5.2"]]
-      :source-paths ["dev-resources/src"]
+      :source-paths ["dev-resources/src"]}
+    :dev {
       :repl-options {
         :init-ns cmr.opendap.dev
         :prompt ~get-prompt
@@ -95,6 +97,7 @@
         :output-path "docs/current"}}}
   :aliases {
     ;; Dev & Testing Aliases
+    "repl" ["with-profile" "+local" "repl"]
     "ubercompile" ["with-profile" "+ubercompile" "compile"]
     "check-vers" ["with-profile" "+lint" "ancient" "check" ":all"]
     "check-jars" ["with-profile" "+lint" "do"


Bump devtools dep to 0.2.1

Bump devtools dep to 0.2.1

--- project.clj
+++ project.clj
@@ -10,7 +10,7 @@
                  [org.omcljs/om "0.8.8" :exclusions [cljsjs/react]]
                  [cljsjs/react "0.13.1-0"]
                  [prismatic/om-tools "0.3.11"]
-                 [binaryage/devtools "0.2.0"]
+                 [binaryage/devtools "0.2.1"]
                  [spellhouse/phalanges "0.1.6"]
                  [secretary "1.2.3"]
                  [matchbox "0.0.6" :exclusions [commons-codec]]


Bump version number to 2.1.0

Bump version number to 2.1.0

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject degasolv/degasolv "2.1.0-SNAPSHOT"
+(defproject degasolv/degasolv "2.1.0"
             :description "Dependency tracker with an eye toward building and shipping software."
             :url "http://github.com/djhaskin987/degasolv"
             :license {:name "Eclipse Public License"


Version 0.11.1

Version 0.11.1

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject crucible "0.11.1-SNAPSHOT"
+(defproject crucible "0.11.1"
   :description "AWS Cloudformation templates in Clojure"
   :url "http://github.com/brabster/crucible"
   :license {:name "Eclipse Public License"


Tweak project file.

Tweak project file.

--- project.clj
+++ project.clj
@@ -42,19 +42,20 @@
                                              "-hadoop-stable,+hadoop-cdh4:"
                                              "-hadoop-stable,+hadoop-2-2-0")
                         ,              "test"]}
-  :profiles {:default [:base :system :user :provided :java6 :hadoop-stable :dev]
-             :conjars {:repositories
+  :profiles {:conjars {:repositories
                        [["conjars" "http://conjars.org/repo/"]]}
              :cloudera {:repositories
                         [["cloudera" ~(str "https://repository.cloudera.com"
                                            "/artifactory/cloudera-repos/")]]}
-             :provided {:dependencies
-                        [[org.slf4j/slf4j-api "1.6.1"]
-                         [org.slf4j/slf4j-log4j12 "1.6.1"]
-                         [log4j "1.2.17"]]}
+             :provided [:hadoop-stable :slf4j-log4j :java6]
+             :slf4j-log4j {:dependencies
+                           [[org.slf4j/slf4j-api "1.6.1"]
+                            [org.slf4j/slf4j-log4j12 "1.6.1"]
+                            [log4j "1.2.17"]]}
              :java6 {:dependencies
                      [[org.codehaus.jsr166-mirror/jsr166y "1.7.0"]]}
              :examples {:source-paths ["examples"]}
+             :uberjar [:examples :java6]
              :dev [:examples
                    :conjars ;; For cascading-* *
                    {:dependencies


Updated version for next release cycle

Updated version for next release cycle

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject lein-pallet-release "0.1.8"
+(defproject lein-pallet-release "0.1.9-SNAPSHOT"
   :description "A leiningen plugin for the PalletOps release workflow"
   :url "http://github.com/palletops/lein-pallet-release"
   :license {:name "Eclipse Public License"


Update dependencies.

Update dependencies.

--- project.clj
+++ project.clj
@@ -54,14 +54,14 @@
       ]
       :plugins [
         [lein-ancient "0.6.8-SNAPSHOT"] ; Check for outdated dependencies https://github.com/xsc/lein-ancient
-        [lein-cljsbuild "1.0.6"] ; ClojureScript compiler https://github.com/emezeske/lein-cljsbuild
+        [lein-cljsbuild "1.1.0"] ; ClojureScript compiler https://github.com/emezeske/lein-cljsbuild
         [lein-spell "0.1.0"] ; Catch spelling mistakes in docs and docstrings https://github.com/cldwalker/lein-spell
         [lein-bikeshed "0.2.0"] ; Check for code smells https://github.com/dakrone/lein-bikeshed
         [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-cljfmt "0.3.0"] ; Code formatting https://github.com/weavejester/cljfmt
         [lein-deps-tree "0.1.2"] ; Print a tree of project dependencies https://github.com/the-kenny/lein-deps-tree
-        [venantius/yagni "0.1.1"] ; Dead code finder https://github.com/venantius/yagni
+        [venantius/yagni "0.1.4"] ; Dead code finder https://github.com/venantius/yagni
       ]
       :env {
         :config-file "config.edn"
@@ -100,7 +100,7 @@
     "start!" ["ring" "server-headless"]
     "repl" ["with-profile" "repl" "repl"]
     "spell" ["spell" "-n"]
-    "ancient!" ["do" "ancient" ":allow-qualified," "ancient" ":plugins" ":allow-qualified"] ; check for out of date dependencies
+    "ancient" ["ancient" ":all" ":allow-qualified"] ; check for out of date dependencies
   }

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


Upgrade cloverage

Upgrade cloverage

--- project.clj
+++ project.clj
@@ -20,7 +20,7 @@

   :plugins [[lein-cljsbuild "1.0.3"]
             [lein-environ "1.0.0"]
-            [lein-cloverage "1.0.2"]]
+            [lein-cloverage "1.0.5"]]

   :min-lein-version "2.5.0"


Fix file permissions on onix init.d script

--- project.clj
+++ project.clj
@@ -107,9 +107,8 @@
                     :groupname "onix"
                     :sources {:source [{:location "scripts/bin"}]}}
                    {:directory "/etc/rc.d/init.d"
-                    :filemode "744"
-                    :username "onix"
-                    :groupname "onix"
-                    :sources {:source [{:location "scripts/service/onix"}]}}]}
+                    :filemode "755"
+                    :sources {:source [{:location "scripts/service/onix"
+                                        :destination "onix"}]}}]}

   :main onix.setup)


release 2.3.2

release 2.3.2

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject babel "2.3.2-SNAPSHOT"
+(defproject babel "2.3.2"
   :description "A library for natural language generation and parsing"
   :url "http://github.com/ekoontz/babel"
   :license {:name "Eclipse Public License"


Updated version for next release cycle

Updated version for next release cycle

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject lein-pallet-release "0.1.11"
+(defproject lein-pallet-release "0.1.12-SNAPSHOT"
   :description "A leiningen plugin for the PalletOps release workflow"
   :url "http://github.com/palletops/lein-pallet-release"
   :license {:name "Eclipse Public License"


(SERVER-2431) Update clj-parent to 1.7.21

This brings in a new BouncyCastle, fixing a security vulnerability.

--- project.clj
+++ project.clj
@@ -37,7 +37,7 @@

   :min-lein-version "2.7.1"

-  :parent-project {:coords [puppetlabs/clj-parent "1.7.19"]
+  :parent-project {:coords [puppetlabs/clj-parent "1.7.21"]
                    :inherit [:managed-dependencies]}

   :dependencies [[org.clojure/clojure]


layout

layout

--- project.clj
+++ project.clj
@@ -6,13 +6,18 @@
   :dependencies [[org.clojure/clojure "1.7.0"]
                  [org.clojure/clojurescript "1.7.48"]
                  [org.clojure/core.async "0.1.346.0-17112a-alpha"]]
+
+  :node-dependencies [[express "4.13.3"]]
+
   :plugins [[org.bodil/lein-noderepl "0.1.11"]
             [lein-cljsbuild "1.0.6"]]
+
   :min-lein-version "2.0.0"
+
   :clean-targets [^{:protect false}
                   [:cljsbuild :builds 0 :compiler :output-to]
                   :target-path :compile-path]
-  :node-dependencies [[express "4.13.3"]]
+
   :cljsbuild {:builds
               [{:source-paths ["src/cljs"]
                 :compiler {:target :nodejs


lein-release plugin: bumped version from 0.1.0 to 0.1.1-SNAPSHOT for next development cycle

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject yetibot.core "0.1.0"
+(defproject yetibot.core "0.1.1-SNAPSHOT"
   :description "Core yetibot utilities, extracted for shared use among yetibot
                 and its various plugins"
   :url "https://github.com/devth/yetibot.core"


Explicitly declared segment v0.4.2

Explicitly declared segment v0.4.2

LATEST is a bad idea.  A breaking change was introduced in version
1.0.0, causing this library to stop compiling.

Setting to 0.4.2, last known good version.  It can be updated later if
the Clojure code is updated to match.

--- project.clj
+++ project.clj
@@ -6,7 +6,7 @@
   :plugins [[codox "0.6.6"]]
   :codox {:src-linenum-anchor-prefix "L"}
   :dependencies [[org.clojure/clojure "1.5.1"]
-                 [com.github.segmentio/analytics "LATEST"]]
+                 [com.github.segmentio/analytics "0.4.2"]]
   :profiles {:dev {:dependencies [[ch.qos.logback/logback-classic "1.0.13"]
                                   [ch.qos.logback/logback-core "1.0.13"]
                                   [org.slf4j/jcl-over-slf4j "1.7.5"]]}})


move s3 dep to normal dependencies

move s3 dep to normal dependencies

--- project.clj
+++ project.clj
@@ -17,6 +17,7 @@
                  [joda-time "2.8.2"]
                  [instaparse "1.4.1"]
                  [com.taoensso/carmine "2.11.1"]
+                 [clj-aws-s3 "0.3.10" :exclusions [joda-time]]
                  ;client
                  [org.clojure/clojurescript "1.7.145"]
                  [org.omcljs/om "0.8.8"]
@@ -57,7 +58,6 @@
                                   [figwheel-sidecar "0.4.0"]]}
              :prod {:dependencies [[com.datomic/datomic-pro "0.9.5201" :exclusions [joda-time]]
                                    [org.postgresql/postgresql "9.3-1103-jdbc4"]
-                                   [clj-aws-s3 "0.3.10" :exclusions [joda-time]]
                                    [org.clojure/tools.nrepl "0.2.10"]]}
              :test [:dev]
              :uberjar [:prod


use [rewrite-clj "0.3.7"].

use [rewrite-clj "0.3.7"].

--- project.clj
+++ project.clj
@@ -1,7 +1,7 @@
 (defproject lein-ancient "0.5.5-SNAPSHOT"
   :description "Check your Projects for outdated Dependencies."
   :url "https://github.com/xsc/lein-ancient"
-  :dependencies [[rewrite-clj "0.3.6"]
+  :dependencies [[rewrite-clj "0.3.7"]
                  [ancient-clj "0.1.7"]]
   :license {:name "Eclipse Public License"
             :url "http://www.eclipse.org/legal/epl-v10.html"}


new bodyguard version

new bodyguard version

--- project.clj
+++ project.clj
@@ -16,7 +16,7 @@
     [ring/ring-servlet "1.3.0"]
     [paths "0.1.0-beta4"]
     [enforcer "0.1.0-beta1"]
-    [bodyguard "0.2b"]
+    [bodyguard "0.1.0-beta3"]

     [environ "0.5.0"] ; environment variables
     [clj-time "0.7.0"] ; date/time


Version 0.31.0-SNAPSHOT

Version 0.31.0-SNAPSHOT

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject ch.sbs/catalog "0.30.0"
+(defproject ch.sbs/catalog "0.31.0-SNAPSHOT"

   :description "A webapp to generate catalogs of the new items in the library"
   :url "https://github.com/sbsdev/catalog"


Update compojure to 1.2.1. Close #11.

Update compojure to 1.2.1. Close #11.

--- project.clj
+++ project.clj
@@ -4,7 +4,7 @@
   :dependencies [; Clojure
                  [org.clojure/clojure "1.6.0"]
                  [ring "1.3.1"]
-                 [compojure "1.2.0"]
+                 [compojure "1.2.1"]
                  [ring/ring-json "0.3.1"]
                  [clj-http "1.0.0"]
                  [tentacles "0.2.5"]


Add org and reponame to demo-label

Add org and reponame to demo-label

--- src-cljs/frontend/components/header.cljs
+++ src-cljs/frontend/components/header.cljs
@@ -1,5 +1,6 @@
 (ns frontend.components.header
-  (:require [frontend.async :refer [raise!]]
+  (:require [clojure.string :as string]
+            [frontend.async :refer [raise!]]
             [frontend.components.common :as common]
             [frontend.components.forms :as forms]
             [frontend.components.license :as license]
@@ -97,7 +98,8 @@
       (let [flash (get-in app state/flash-path)
             logged-in? (get-in app state/user-path)
             nav-point (:navigation-point app)
-            hamburger-state (get-in app state/hamburger-menu-path)]
+            hamburger-state (get-in app state/hamburger-menu-path)
+            first-build (first (:recent-builds app))]
         (html
           [:div.outer-header
            [:div
@@ -131,7 +133,9 @@
              [:div.navbar-container {:class hamburger-state}
               (if (:current-build-data app)
                 [:ul.nav.navbar-nav
-                  [:li [:span.demo-label "You are viewing the CircleCI open source dashboard!"]]]
+                  (if first-build
+                    [:li [:span.demo-label "You are viewing the CircleCI open source dashboard with builds from " (string/capitalize (:username first-build)) "'s " (string/capitalize (:reponame first-build)) " repo!"]]
+                    [:li [:span.demo-label "You are viewing the CircleCI open source dashboard"]])]
                 [:ul.nav.navbar-nav
                  (when (config/show-marketing-pages?)
                    (list


CMR-1341: Changed cubby elasticsearch fetch value to use the get api instead of search.

--- cubby-app/src/cmr/cubby/data/elastic_cache_store.clj
+++ cubby-app/src/cmr/cubby/data/elastic_cache_store.clj
@@ -56,15 +56,19 @@

 (comment

-  (d/reset (:db user/system))
+  (def db (get-in user/system [:apps :cubby :db]))

-  (d/set-value (:db user/system) "foo" "v")
-  (d/set-value (:db user/system) "bar" "v2")
-  (d/set-value (:db user/system) "charlie" "v2")
+  (d/reset db)

-  (d/get-keys (:db user/system))
-  (d/get-value (:db user/system) "bar")
-  (d/delete-value (:db user/system) "bar")
+  (d/set-value db "foo" "v")
+  (d/set-value db "bar" "v2")
+  (d/set-value db "charlie" "v2")
+
+
+
+  (d/get-keys db)
+  (d/get-value db "bar")
+  (d/delete-value db "bar")

   (esd/search (-> user/system :db :conn)
               index-name type-name :query (q/match-all)
@@ -139,12 +143,8 @@

   (get-value
     [this key-name]
-    (->> (esd/search conn index-name type-name
-                     :query {:filtered {:query (q/match-all)
-                                        :filter {:term {:key-name key-name}}}}
-                     :fields [:value])
-         (extract-field-from-hits :value)
-         first))
+    (get-in (esd/get conn index-name type-name key-name)
+            [:_source :value]))

   (set-value
     [this key-name value]


fix url too eager in EN

fix url too eager in EN

--- resources/languages/en/rules/communication.clj
+++ resources/languages/en/rules/communication.clj
@@ -12,7 +12,7 @@
   			(:value %5) (:value %6) (:value %7) (:value %8) (:value %9) (:value %10)])}

  "url"
- #"((https?://)?(\w+\.)+\w{2,4}(:\d+)?[^ ]*)"
+ #"((https?://)?(\w+\.)+[A-z]{2,4}(:\d+)?[^ ]*)"
  {:dim :url
   :value (-> %1 :groups first)}


Use with-env from a lib

Use with-env from a lib

--- build.boot
+++ build.boot
@@ -1,24 +1,3 @@
-(intern
-  (the-ns 'boot.core)
-  'resolve-dependencies? (atom true))
-
-(alter-var-root
-  #'boot.core/add-dependencies!
-  (fn [orig]
-    (fn [old new env]
-      (if @boot.core/resolve-dependencies? (orig old new env) new))))
-
-(defmacro with-env
-  [env-map expr]
-  `(let [orig-env# (boot.core/get-env)
-         new-env#  ~env-map]
-     (reset! boot.core/resolve-dependencies? false)
-     (apply boot.core/set-env! (mapcat identity new-env#))
-     (let [result# ~expr]
-       (apply boot.core/set-env! (mapcat identity orig-env#))
-       (reset! boot.core/resolve-dependencies? true)
-       result#)))
-
 (set-env! :target-path "target/dev"
             :source-paths #{"sass" "src" "resources" "dev-cljs"}
             :asset-paths #{"assets"}
@@ -36,7 +15,8 @@
                             [ch.qos.logback/logback-classic "1.1.3" :exclusions [org.slf4j/slf4j-api]]
                             [com.cemerick/piggieback "0.2.1" :scope "test"] ;; Needed for start-repl in cljs repl
                             [org.clojure/clojurescript "1.7.170"]
-                            [weasel "0.7.0" :scope "test"]]);; Websocket Server
+                            [weasel "0.7.0" :scope "test"];; Websocket Server
+                            [io.dominic/boot-snippets "0.1.0" :scope "test"]])

 (require '[adzerk.boot-cljs :refer [cljs]]
          '[adzerk.boot-cljs-repl :refer [cljs-repl start-repl]]
@@ -44,7 +24,8 @@
          '[boot.pod :as pod]
          '[clojure.java.shell :as sh]
          '[mathias.boot-sassc :refer [sass]]
-         '[deraen.boot-less :refer [less]])
+         '[deraen.boot-less :refer [less]]
+         '[io.dominic.boot-snippets :refer [with-env]])

 (def server-deps '[[aleph "0.4.1-beta3"]
                    [bidi "1.24.0"]


Post-release version bump

Post-release version bump

--- build.boot
+++ build.boot
@@ -25,7 +25,7 @@
          '[crisptrutski.boot-cljs-test :refer [test-cljs exit!]]
          '[pandeiro.boot-http :refer [serve]])

-(def version "0.2.0")
+(def version "0.2.0-SNAPSHOT")

 (bootlaces! version :dont-modify-paths? true)


Fix incorrect require

Fix incorrect require

--- build.boot
+++ build.boot
@@ -8,7 +8,7 @@
                           [adzerk/bootlaces "0.1.13" :scope "test"]])

 (require '[adzerk.boot-test :refer [test]]
-         '[adzerk.bootlaces :refer [bootlaces! build-jar push-repo]])
+         '[adzerk.bootlaces :refer [bootlaces! build-jar push-snapshot]])

 (task-options!
  pom {:project     project


combineTiles.clj: some refactoring and bug fixing

--- clojure/org/gavrog/clojure/combineTiles.clj
+++ clojure/org/gavrog/clojure/combineTiles.clj
@@ -1,6 +1,6 @@
 (ns org.gavrog.clojure.combineTiles
   (:use (clojure
-          [set :only [difference]])
+          [set :only [difference union]])
         (org.gavrog.clojure
           [util :only [empty-queue]]
           [generators :only [make-backtracker results]]
@@ -38,26 +38,33 @@
                  (into (rest q) (for [j (range (dec i))]
                                   [(s ds j D) (s ds j E)]))))))))

-(defn- children [d forms [symbol sig free-elements free-components]]
-  (when-let [D (first (free-elements))]
-    (let [face-idcs (range (dec d))
-          face (fn [D] (orbit-elements symbol face-idcs D))
-          adding (for [E free-elements :when (= (sig D) (sig E))]
-                   [(glue-faces symbol d D E)
-                    sig
-                    (difference free-elements (face D) (face E))
-                    free-components])
-          extending (for [[part n] free-components
-                          :when (pos? n)
-                          [form s] (forms part)
-                          :when (= (sig D) (s 1))]
-                      [(glue-faces (append symbol form) d D (inc (size symbol)))
-                       (into sig (for [D (range 1 (inc (size form)))]
-                                   [(+ (size symbol D)) (s D)]))
-                       (difference (union free-elements ...) (face D) ...)
-                       (assoc free-components part
-                              (dec (free-componets part)))])]
-      (concat adding extending))))
+(defn- augmentations [d forms [symbol sig free-elements free-components]]
+  (when-let [D (first free-elements)]
+    (let [face (fn [D] (orbit-elements symbol (range (dec d)) D))]
+      (for [E free-elements :when (= (sig D) (sig E))]
+        [(glue-faces symbol d D E)
+         sig
+         (difference free-elements (face D) (face E))
+         free-components]))))
+
+(defn- extensions [d forms [symbol sig free-elements free-components]]
+  (when-let [D (first free-elements)]
+    (let [sz (size symbol)]
+      (for [[part n] free-components
+            :when (pos? n)
+            [form s] (forms part)
+            :when (= (sig D) (s 1))
+            face (orbit-elements symbol (range (dec d)) D)]
+        [(glue-faces (append symbol form) d D (inc sz))
+         (into sig (for [D (range 1 (inc (size form)))] [(+ sz D) (s D)]))
+         (difference (union free-elements
+                            (range (inc sz) (inc (+ sz (size form)))))
+                     face
+                     (range (inc sz) (+ sz (count face))))
+         (assoc free-components part (dec (free-components part)))]))))
+
+(defn- children [d forms state]
+  (concat (augmentations d forms state) (extensions d forms state)))

 (defn combine-tiles [ds]
   (let [d (inc (dim ds))
@@ -71,7 +78,7 @@
       {:root (let [[sub sigs] (first (forms (first parts)))]
                [sub
                 sigs
-                (into #{} (orbit-reps sub face-idcs))
+                (into #{} (elements sub))
                 (assoc counts sub (dec (counts sub)))])
        :extract (fn [[symbol _ free-elements free-components]]
                   (when (and (empty? free-elements)


growl task

growl task

--- build.boot
+++ build.boot
@@ -16,7 +16,37 @@
  '[adzerk.boot-reload    :refer [reload]]
  '[deraen.boot-cljx      :refer [cljx]]
  '[pandeiro.http         :refer [serve]]
- '[clojure.tools.namespace.repl :refer [set-refresh-dirs]])
+ '[clojure.tools.namespace.repl :refer [set-refresh-dirs]]
+
+ '[boot.util            :as util]
+ '[boot.pod             :as pod])
+
+(deftask growl
+  "Growl notifications during build."
+  []
+  (let []
+    (pod/add-dependencies-worker {:dependencies '[[jakemcc/clojure-gntp "0.1.1"]]})
+    (fn [continue]
+      (fn [event]
+        (try
+          (util/with-let [ret (continue event)]
+            (pod/call-worker
+             (if (zero? @*warnings*)
+               `(jakemcc.clojure-gntp.gntp/message "Boot - success" ""
+                                                   :appname "boot"
+                                                   :app "boot"
+                                                   :notification "boot-notify")
+               `(jakemcc.clojure-gntp.gntp/message "Boot - warning(s)" ~(deref *warnings*)
+                                                   :appname "boot"
+                                                   :app "boot"
+                                                   :notification "boot-notify"))))
+          (catch Throwable t
+            (pod/call-worker
+             `(jakemcc.clojure-gntp.gntp/message "Boot - error" ~(str (.getMessage t))
+                                                 :appname "boot"
+                                                 :app "boot"
+                                                 :notification "boot-notify"))
+            (throw t)))))))

 (deftask development
   "watch and compile cljx, css, cljs, init cljs-repl and push changes to browser"
@@ -26,6 +56,8 @@
   (apply set-refresh-dirs (get-env :src-paths))
   (comp (serve :dir "target")
         (watch)
+        ;; (speak :success "")
+        (growl)
         (cljx)
         (cljs-repl)
         (cljs :output-to "main.js"


Made deftype BacktrackingGenerator actually backtrack.

--- clojure/org/gavrog/clojure/permutations.clj
+++ clojure/org/gavrog/clojure/permutations.clj
@@ -1,11 +1,37 @@
 (ns org.gavrog.clojure.permutations)

-(deftype BacktrackingGenerator [root children extract desc]
+(defprotocol ResumableGenerator
+  (result [_])
+  (step [_])
+  (checkpoint [_])
+  (resume [_ checkpoint]))
+
+(deftype BacktrackingGenerator [gen-children extract desc stack]
+  ResumableGenerator
+  (result [_] (extract (:node (first stack))))
+  (step [_]
+        (let [stack
+              (if-let [children (seq (gen-children (:node (first stack))))]
+                (conj stack
+                      {:node (first children)
+                       :branch-nr 0
+                       :siblings-left (rest children)})
+                (when-let [stack (seq (drop-while
+                                        #(not (seq (:siblings-left %))) stack))]
+                  (let [{:keys [siblings-left branch-nr]} (first stack)]
+                    (conj (rest stack)
+                          {:node (first siblings-left)
+                           :branch-nr (inc branch-nr)
+                           :siblings-left (rest siblings-left)}))))]
+          (when (seq stack)
+            (BacktrackingGenerator. gen-children extract desc stack))))
   clojure.lang.Seqable
-  (seq [_] (filter (comp not nil?)
-                   (map extract (tree-seq (constantly true) children root))))
+  (seq [bg] (lazy-seq (cons bg (step bg))))
   Object
   (toString [_] (str desc)))
+
+(defn make-backtracker [gen-children extract desc root]
+  (BacktrackingGenerator. gen-children extract desc (list {:node root})))

 (defn permutations [n]
   (let [keys (range 1 (inc n))
@@ -20,4 +46,4 @@
                                    :unseen (disj unseen k)}))))
         extract (fn [node] (when (empty? (:unused node)) (:perm node)))
         desc (list `permutations n)]
-        (BacktrackingGenerator. root children extract desc)))
+        (make-backtracker children extract desc root)))


update reagent version

update reagent version

--- build.boot
+++ build.boot
@@ -26,7 +26,7 @@
                  [nginx-clojure "0.4.4"]
                  [com.cemerick/piggieback "0.2.1" :scope "test"]
                  [posh "0.5.3.3"]
-                 [reagent "0.6.0-rc" :exclusions [org.clojure/tools.reader cljsjs/react]]
+                 [reagent "0.6.0" :exclusions [org.clojure/tools.reader cljsjs/react]]
                  [ring/ring-defaults "0.1.5"]
                  [com.taoensso/sente "1.10.0"]
                  [com.taoensso/timbre "4.7.2"]


Remove last update dates from docs.

Remove last update dates from docs.

--- src-cljs/frontend/components/documentation.cljs
+++ src-cljs/frontend/components/documentation.cljs
@@ -73,12 +73,6 @@
    [:div
     (om/build-all docs-category categories)]))

-(defrender docs-title [doc]
-  (html
-   [:div
-    (when-let [last-updated (:lastUpdated doc)]
-      [:p.meta [:strong "Last Updated "] last-updated])]))
-
 (defrender front-page [app owner]
   (let [query-results (get-in app state/docs-articles-results-path)
         query (get-in app state/docs-articles-results-query-path)
@@ -145,7 +139,6 @@
 (defrender docs-subpage [doc owner opts]
   (html
    [:div
-    (om/build docs-title doc)
     (if-not (empty? (:children doc))
       (om/build article-list (:children doc))
       (if (:markdown doc)


Fix test expectations.

Fix test expectations.

--- test/onyx/peer/single_peer_test.clj
+++ test/onyx/peer/single_peer_test.clj
@@ -95,16 +95,15 @@
  {:catalog catalog :workflow workflow
   :task-scheduler :onyx.task-scheduler/round-robin})

-(doseq [_ (range n-messages)]
-  (prn (<!! out-chan)))
+(def results (repeatedly n-messages (fn [] (<!! out-chan))))

-(comment
- (doseq [v-peer v-peers]
-   (onyx.api/shutdown-peer v-peer))
+(doseq [v-peer v-peers]
+  (onyx.api/shutdown-peer v-peer))

- #_(let [expected (set (map (fn [x] {:n (inc x)}) (range n-messages)))]
-     (fact (set (butlast results)) => expected)
-     (fact (last results) => :done))
+(let [expected (set (map (fn [x] {:n (inc x)}) (range n-messages)))]
+  (fact (set results) => expected)
+;  (fact (last results) => :done)
+  )

- (onyx.api/shutdown-env env))
+(onyx.api/shutdown-env env)


Improve start time and duration titles in dashboard

--- src-cljs/frontend/components/builds_table.cljs
+++ src-cljs/frontend/components/builds_table.cljs
@@ -193,18 +193,20 @@
                 (= "not_run" (:status build)))
           (list
            [:div.metadata-item.recent-time.start-time
+            {:title "Started: not started"}
             (dashboard-icon "Builds-StartTime")
             "–"]
            [:div.metadata-item.recent-time.duration
+            {:title "Duration: not run"}
             (dashboard-icon "Builds-Duration")
             "–"])
           (list [:div.metadata-item.recent-time.start-time
-                 {:title (datetime/full-datetime (js/Date.parse (:start_time build)))}
+                 {:title (str "Started: " (datetime/full-datetime (js/Date.parse (:start_time build))))}
                  (dashboard-icon "Builds-StartTime")
                  (om/build common/updating-duration {:start (:start_time build)} {:opts {:formatter datetime/time-ago-abbreviated}})
                  " ago"]
                 [:div.metadata-item.recent-time.duration
-                 {:title (build-model/duration build)}
+                 {:title (str "Duration: " (build-model/duration build))}
                  (dashboard-icon "Builds-Duration")
                  (om/build common/updating-duration {:start (:start_time build)
                                                      :stop (:stop_time build)})]))]]


add loading/success state

add loading/success state

--- src-cljs/frontend/components/builds_table.cljs
+++ src-cljs/frontend/components/builds_table.cljs
@@ -77,7 +77,9 @@
               [:button.cancel-build
                {:on-click #(raise! owner [:cancel-build-clicked {:build-id build-id
                                                                  :vcs-url vcs-url
-                                                                 :build-num build-num}])}
+                                                                 :build-num build-num}])
+                :data-loading-text "Canceling..."
+                :data-success-text "Canceled"}
                "Cancel"])))])]))

 (defn builds-table-v1 [builds owner {:keys [show-actions? show-branch? show-project? show-log? show-parallelism?]


Checking for existing stripe customer when selecting osx plans.

--- src-cljs/frontend/components/org_settings.cljs
+++ src-cljs/frontend/components/org_settings.cljs
@@ -459,7 +459,7 @@
               (om/build plan-payment-button {:text "Start 2 Week Free Trial"
                                              :loading-text "Starting..."
                                              :on-click-fn #(raise! owner [:activate-plan-trial {:osx {:template "osx-trial"}}])})
-              (if (and (pm/osx? plan) (not (pm/osx-trial-plan? plan)))
+              (if (pm/stripe-customer? plan)
                 (om/build plan-payment-button {:text "Update"
                                                :loading-text "Updating..."
                                                :disabled? (nil? chosen-plan-id)


Added nl2br fn for area local delivery considerations

--- src/acfe/area.clj
+++ src/acfe/area.clj
@@ -2,6 +2,7 @@
   "Generate area HTML from database"
   (:require [acfe.util :refer [formatted-fact-detail]]
 			[net.cgrand.enlive-html :as e]
+			[clojure.string :refer [replace]]
 			[yesql.core :refer [defqueries]]
 			))

@@ -38,6 +39,11 @@

 	 )))

+
+(defn nl2br
+  "Turn line breaks into
 tags."
+  [s]
+  (replace s #"[\r\n]" "
"))

 (defn area-html
@@ -104,7 +110,7 @@
 	  [:div#industry] (e/content (industry-html id config)))

 	 (e/at
-	  [:.about] (e/content about-text))
+	  [:.about] (e/html-content (nl2br about-text))) ; TODO: susceptible to html injection

 	 )))


Refactored extract-all-pager-links to read more clearly.

--- project/scrape-summitpost-data/src/scrape_summitpost_data/extract_pager_links.clj
+++ project/scrape-summitpost-data/src/scrape_summitpost_data/extract_pager_links.clj
@@ -30,10 +30,11 @@
   [page]
   (when-let [pager-links (-> page extract-pager-links not-empty)]
     (let [last-page (extract-last-page pager-links)
-          template (first pager-links)]
-      (->> (range 1 (+ 1 last-page))
-           (map #(clojure.string/replace
-                   template
-                   #"page=\d+"
-                   (str "page=" %)))))))
-
+          template (first pager-links)
+          page-numbers (range 1 (+ 1 last-page))
+          make-pager-link #(clojure.string/replace
+                             template
+                             #"page=\d+"
+                             (str "page=" %))
+          all-pager-links (map make-pager-link page-numbers)]
+      all-pager-links)))


Day 14 solved

Day 14 solved

--- src/adventofcode/solutions.clj
+++ src/adventofcode/solutions.clj
@@ -22,22 +22,22 @@
               val)) [0 0] (slurp-day-input 1)))

 ; day 2
-(defn -day2 [f-lwh]
+(defn- dday2 [f-lwh]
   (let [input (day-input-line-seq 2)
         val-ex (fn [s] (map #(Integer/parseInt %) (clojure.string/split s #"x")))]
     (reduce #(let [[l w h] (val-ex %2)]
               (+ % (f-lwh l w h))) 0 input)))

 (defn day2 []
-  (-day2 #(let [a (* % %2) b (* %2 %3) c (* % %3) m (min a b c)]
+  (dday2 #(let [a (* % %2) b (* %2 %3) c (* % %3) m (min a b c)]
            (+ (* 2 a) (* 2 b) (* 2 c) m))))

 (defn day2-part2 []
-  (-day2 #(let [[a b] (take 2 (sort [% %2 %3]))]
+  (dday2 #(let [[a b] (take 2 (sort [% %2 %3]))]
            (+ (* 2 a) (* 2 b) (* % %2 %3)))))

 ; day 3
-(def -move #(case %
+(defn- move #(case %
              \^ [%2 (inc %3)]
              \v [%2 (dec %3)]
              \< [(dec %2) %3]
@@ -47,7 +47,7 @@
   (let [input (slurp-day-input 3)]
     (count
       (second
-        (reduce #(let [[[x y] s] % nval (-move %2 x y)]
+        (reduce #(let [[[x y] s] % nval (move %2 x y)]
                   [nval (conj s nval)])
                 [[0 0] #{[0 0]}]
                 input)))))
@@ -57,7 +57,7 @@
   (let [input (partition 2 (slurp-day-input 3))]
     (count
       (second
-        (reduce #(let [[[[x1 y1] [x2 y2]] s] % nval (-move (first %2) x1 y1) m-nval (-move (second %2) x2 y2)]
+        (reduce #(let [[[[x1 y1] [x2 y2]] s] % nval (move (first %2) x1 y1) m-nval (move (second %2) x2 y2)]
                   [[nval m-nval] (conj s nval m-nval)])
                 [[[0 0] [0 0]] #{[0 0]}]
                 input)))))
@@ -71,7 +71,7 @@
         padding (apply str (repeat (- size (count sig)) "0"))]
     (str padding sig)))

-(fn day-4-both-parts []
+(defn day-4-both-parts []
   (let [input "iwrupvqb"]
     (reduce #(let [m5 (md5 (str input %2))]
               (if (.startsWith m5 "00000")                  ;part 2 just asks for one more zero :)
@@ -422,7 +422,7 @@
                          (fn [n] (s->int n)) (re-seq #"\-?\d+" %))))) (iterate rm-red-jsobj input)))

 ;day 13
-;part 1
+;parts 1 and 2 (part 2 is about changing input)
 (defn- d13-single-line-extractor
   "Extracts data from single line of input for day 13"
   [line]
@@ -453,3 +453,101 @@
            (map
              #(+ (happiness %) (happiness (reverse %)))
              arrangements))))
+
+;day 14
+;part 1
+(defn- d14-single-line-extractor
+  [line]
+  (let [[n s d r] (map first (re-seq #"(^\w+)|\d+" line))]
+    {:name               n
+     :moment-in-time     1
+     :speed              (s->int s)
+     :duration           (s->int d)
+     :rest               (s->int r)
+     :current-state      :idle
+     :current-state-time 0
+     :distance-travelled 0}))
+
+(defn- move-raindeer
+  [rd]
+  (update rd :distance-travelled #(+ % (:speed rd))))
+
+(defn- go-rest
+  [rd]
+  (-> rd
+      (assoc :current-state :resting)
+      (assoc :current-state-time 1)))
+
+(defn- go-fly
+  [rd]
+  (-> rd
+      (move-raindeer)
+      (assoc :current-state :flying)
+      (assoc :current-state-time 1)))
+
+(defn- simply-fly
+  [rd]
+  (-> rd
+      (move-raindeer)
+      (update :current-state-time inc)))
+
+(defn- simply-rest
+  [rd]
+  (update rd :current-state-time inc))
+
+(defn- transit-rd
+  [rd ref-state f1 f2]
+  (if (< (:current-state-time rd) (get rd ref-state))
+    (f1 rd)
+    (f2 rd)))
+
+(defn- go-raindeer
+  "Raindeer rd calculation"
+  [rd]
+  (let [cs (:current-state rd)
+        transitioned (case cs
+                       :idle (go-fly rd)
+                       :flying (transit-rd rd :duration simply-fly go-rest)
+                       :resting (transit-rd rd :rest simply-rest go-fly))]
+    (update transitioned :moment-in-time inc)))
+
+(defn- d14-part2-reporter
+  [reporter value]
+  (let [key (:moment-in-time value)]
+    (update reporter key #(conj % %2) [(:name value) (:distance-travelled value)])))
+
+(defn- find-max-points [data]
+  (apply max
+         (map second
+              (reduce
+                (fn [a [_ i]]
+                  (let [m (apply max (map second i))
+                        who-has-max (filter #(= m (second %)) i)]
+                    (reduce #(update % (first %2) (fn [v] (if (nil? v) 1 (inc v)))) a who-has-max)))
+                {}
+                data))))
+
+(defn- find-longest-distance-travelled [raindeers]
+  (:distance-travelled (reduce
+                         #(if (> (:distance-travelled %2) (:distance-travelled %)) %2 %)
+                         (first raindeers)
+                         (rest raindeers))))
+
+(defn day14
+  "Expects sequence of lines from file - easily achieved by using day-input-line-seq like (day-input-line-seq 14)"
+  [input]
+  (let [collector (agent (into {} (map #(identity [% []]) (range 2 2504))))
+        watcher (fn [_ _ _ new]
+                  (send collector d14-part2-reporter new))
+        raindeers (map #(let [a (agent (d14-single-line-extractor %))]
+                         (add-watch a :reporter watcher)
+                         a)
+                       input)]
+    (doall
+      (repeatedly 2503 #(doall
+                         (for [r raindeers] (send r go-raindeer)))))
+    (apply await raindeers)
+    (await collector)
+    (let [values (map #(identity @%) raindeers)]
+      {:part1 (find-longest-distance-travelled values)
+       :part2 (find-max-points @collector)})))


Add test for three collaborating resources running in jetty-async-adapter

--- spec/rook/dispatcher_spec.clj
+++ spec/rook/dispatcher_spec.clj
@@ -500,6 +500,9 @@
                               ["barney"] 'barney middleware))
                           (into
                             (dispatcher/namespace-dispatch-table
+                              ["betty"] 'betty middleware))
+                          (into
+                            (dispatcher/namespace-dispatch-table
                               ["slow"] 'slow middleware))
                           (into
                             (dispatcher/namespace-dispatch-table
@@ -568,11 +571,18 @@
         (should= HttpServletResponse/SC_NOT_FOUND (:status response))))

     ;; FIXME: this passes, but needs more thought; see FIXME in dispatcher
-    (xit "can calculate :resource-uri after a loopback"
+    (it "can calculate :resource-uri after a loopback"
       (let [response (http/post "http://localhost:9988/creator-loopback"
                        {:throw-exceptions false})]
         (should= "http://localhost:9988/creator/<ID>"
           (get-in response [:headers "Location"]))))

+    (it "should allow three resources to collaborate"
+      (let [response (http/get "http://localhost:9988/fred/123"
+                       {:accept :edn
+                        :throw-exceptions true})]
+        (should= ":barney says `:betty says `123 is a very fine id!''"
+          (-> response :body edn/read-string :message))))
+
     (after-all
       (.stop @server))))


added :startup transition event and replaced kill and rebalance :monitor transitions with it

--- src/clj/backtype/storm/daemon/nimbus.clj
+++ src/clj/backtype/storm/daemon/nimbus.clj
@@ -95,12 +95,6 @@
     nil
     ))

-;; there's a minor problem where rebalancing is scheduled over and over until it finally happens
-;; can fix this by either:
-;; 1. detecting whether it's scheduled or not...
-;; 2. not using monitor event, but rather some sort of "on startup" event
-;; 3. generating a "rebalance id" and only rebalancing if current status has that id
-
 (defn state-transitions [nimbus storm-id status]
   {:active {:monitor (reassign-transition nimbus storm-id)
             :inactivate :inactive
@@ -114,7 +108,7 @@
               :rebalance (rebalance-transition nimbus storm-id status)
               :kill (kill-transition nimbus storm-id)
               }
-   :killed {:monitor (fn [] (delay-event nimbus
+   :killed {:startup (fn [] (delay-event nimbus
                                          storm-id
                                          (:kill-time-secs status)
                                          :remove))
@@ -125,7 +119,7 @@
                                       storm-id)
                       nil)
             }
-   :rebalancing {:monitor (fn [] (delay-event nimbus
+   :rebalancing {:startup (fn [] (delay-event nimbus
                                               storm-id
                                               (:delay-secs status)
                                               :do-rebalance))
@@ -143,7 +137,8 @@
      (transition! nimbus storm-id event false))
   ([nimbus storm-id event error-on-no-transition?]
      (locking (:submit-lock nimbus)
-       (let [[event & event-args] (if (keyword? event) [event] event)
+       (let [system-events #{:startup :monitor}
+             [event & event-args] (if (keyword? event) [event] event)
              status (topology-status nimbus storm-id)]
          ;; handles the case where event was scheduled but topology has been removed
          (if-not status
@@ -156,8 +151,10 @@
                                               " storm-id: " storm-id)]
                                  (if error-on-no-transition?
                                    (throw-runtime msg)
-                                   (do (log-message msg) nil)
-                                   ))))
+                                   (do (when-not (contains? system-events event)
+                                         (log-message msg))
+                                       nil))
+                                 )))
                  transition (-> (state-transitions nimbus storm-id status)
                                 (get (:type status))
                                 (get-event event))
@@ -623,12 +620,13 @@
 (defserverfn service-handler [conf]
   (log-message "Starting Nimbus with conf " conf)
   (let [nimbus (nimbus-data conf)]
+    (doseq [storm-id (.active-storms (:storm-cluster-state nimbus))]
+      (transition! nimbus storm-id :startup))
     (schedule-recurring (:timer nimbus)
                         0
                         (conf NIMBUS-MONITOR-FREQ-SECS)
                         (fn []
-                          (doseq [storm-id (.active-storms
-                                            (:storm-cluster-state nimbus))]
+                          (doseq [storm-id (.active-storms (:storm-cluster-state nimbus))]
                             (transition! nimbus storm-id :monitor))
                           (do-cleanup nimbus)
                           ))


cleanup

cleanup

--- src/cljs/just_married/home/language.cljs
+++ src/cljs/just_married/home/language.cljs
@@ -16,43 +16,6 @@
       (get "language" "en")
       keyword))

-(def dicts
-  "List of all the words/sentences that need localization"
-  {:en {:home "Home"
-        :timeline "Timeline"
-        :story "Our Story"
-        :find-us "Find Us"
-        :find-us-text "The wedding will be done in the beautiful Abruzzo region, between Chieti and Pescara."
-        :countdown "Countdown"
-        :accomodation "Accommodation"
-        :contacts "Contacts"
-        :add-to-calendar "Add to Calendar"
-        :date "27th May, 2018"
-        :days "Days"
-        :hours "Hours"
-        :minutes "Minutes"
-        :read-more "Read More"
-        :read-less "Read Less"
-
-        ;; timeline translation
-        :waiting "Waiting for the bride Aperitif"
-        }
-
-   :it {:home "Home"
-        :timeline "Programma"
-        :story "La Nostra Storia"
-        :find-us "Trovaci"
-        :countdown "Conto Alla Rovescia"
-        :accomodation "Dove Dormire"
-        :contacts "Contatti"
-        :add-to-calendar "Aggiungi al Calendario"
-        :date "27 Maggio 2018"
-        :days "Giorni"
-        :hours "Ore"
-        :minutes "Minuti"
-        :read-more "Leggi di piu'"
-        :read-less "Leggi di meno"}})
-
 (defn translate
   [dict key]
   ((tongue/build-translate dict) (get-language) key))


Improved socket closing on websocket handler.

--- src/clojure/catacumba/impl/websocket.clj
+++ src/clojure/catacumba/impl/websocket.clj
@@ -53,6 +53,7 @@
 (deftype WebSocketSession [in out ctrl context handler]
   java.io.Closeable
   (close [_]
+    (a/put! ctrl :close)
     (a/close! in)
     (a/close! out)
     (a/close! ctrl))
@@ -66,7 +67,9 @@
           (do
             (a/<! (send! ws (str value)))
             (recur))
-          (.close ws)))
+          (do
+            (.close ws)
+            (.close this))))
       (handler (merge context
                       {:in in :out out :ctrl ctrl
                        :ws ws :wssession this}))))
@@ -75,7 +78,6 @@
     (a/put! in (.getData msg) (fn [_] (.execute callback nil))))

   (^void onClose [this]
-    (a/put! ctrl :close)
     (.close this)))

 (defn websocket


New function: read-product-names

New function: read-product-names

--- src/arachnida/db_interface.clj
+++ src/arachnida/db_interface.clj
@@ -8,6 +8,12 @@
     (jdbc/query db-spec/data-db  "select id, name
                                   from   products
                                   order  by id;"))
+
+(defn read-product-names
+    []
+    (jdbc/query db-spec/data-db  "select name
+                                  from   products
+                                  order  by name;"))

 (defn read-repo-list
     [product-id]


fix :share-sem rule

fix :share-sem rule

--- src/babel/english/lexicon.cljc
+++ src/babel/english/lexicon.cljc
@@ -2263,7 +2263,8 @@
                  (default
                   (let [obj (atom :top)]
                     {:share-sem :obj
-                     :synsem {:sem {:obj obj}
+                     :synsem {:cat :verb
+                             :sem {:obj obj}
                               :subcat {:2 {:cat :prep
                                            :sem {:obj obj}}}}}))


bag, car, and key are all edible=false

bag, car, and key are all edible=false

--- src/babel/english/lexicon.cljc
+++ src/babel/english/lexicon.cljc
@@ -108,6 +108,7 @@
    "bag" {:synsem {:cat :noun
                    :sem {:pred :bag
                          :animate false
+                         :edible false
                          :place false}}}

    "base" {:synsem {:cat :verb
@@ -346,6 +347,7 @@
    "car" {:synsem {:cat :noun
                    :sem {:pred :car
                          :animate false
+                         :edible false
                          :place false}}}

    "carry" {:synsem {:cat :verb
@@ -1067,6 +1069,7 @@
    "key" {:synsem {:cat :noun
                    :sem {:pred :key
                          :animate false
+                         :edible false
                          :place false}}}

    "kill" {:synsem {:cat :verb


fix treatment of intransitives with phrasal verbs

--- src/babel/english/lexicon.cljc
+++ src/babel/english/lexicon.cljc
@@ -161,8 +161,10 @@
                       :subcat {:2 {:cat :noun}}
                       :sem {:obj {:pred :top}}}})

-   (new-entries ;; remove the second argument and semantic object to make verbs intransitive.
+   ;; inttransitivize:  remove the second argument and semantic object to make verbs intransitive.
+   (new-entries
     {:intransitivize false
+     :phrasal-verb false
      :synsem {:cat :verb
               :aux false
               :sem {:obj {:top :top}
@@ -175,8 +177,26 @@
       (unify
        (dissoc-paths lexeme [[:synsem :sem :obj]
                              [:synsem :subcat :2]])
-       {:applied {:1 true}
+       {:applied {:intransitivize true}
         :synsem {:subcat {:2 '()}}})))
+
+   ;; phrasal-verb-intransitivize: remove the third argument,
+   ;; but not the second, to make it intransitive.
+   (new-entries
+    {:intransitivize false
+     :phrasal-verb true
+     :synsem {:cat :verb
+              :aux false
+              :subcat {:2 {:cat :prep}}}}
+    (fn [lexeme]
+      (unify
+       (dissoc-paths
+       (unify lexeme {:applied {:phrasal-verb-intransitivize true}})
+       [[:synsem :subcat :3]])
+
+       ;; prevent filling-in this
+       ;; in a later processing step below.
+       {:synsem {:subcat {:3 '()}}})))

    (default ;; intransitive verbs' :obj is :unspec.
     {:modal-with false


Hide :sub/create traces for cached subscriptions

Fixes #93

--- src/day8/re_frame/trace/view/traces.cljs
+++ src/day8/re_frame/trace/view/traces.cljs
@@ -94,6 +94,10 @@
                                                       (set/union % category-keys))))

             visible-traces     (cond->> @traces
+                                        ;; Remove cached subscriptions. Could add this back in as a setting later
+                                        ;; but it's pretty low signal/noise 99% of the time.
+                                        true (remove (fn [trace] (and (= :sub/create (:op-type trace))
+                                                                      (get-in trace [:tags :cached?]))))
                                         (seq @categories) (filter (fn [trace] (when (contains? @categories (:op-type trace)) trace)))
                                         (seq @filter-items) (filter (apply every-pred (map query->fn @filter-items))))
             save-query         (fn [_]


Use recommended start options for http-kit

* Allow provisioning a random port (primarily for testing) for all
three servers.
* Scrap `println` logging in favor of timbre.

--- src/braid/core/server/core.clj
+++ src/braid/core/server/core.clj
@@ -1,14 +1,13 @@
 (ns braid.core.server.core
-  (:require
-    [braid.core.server.handler :refer [mobile-client-app
-                                       desktop-client-app
-                                       api-server-app]]
-    [braid.base.server.ws-handler] ; for mount
-    [braid.core.server.sync] ; for multimethods
-    [braid.base.server.jobs] ; for mount
-    [mount.core :as mount :refer [defstate]]
-    [org.httpkit.server :refer [run-server]]
-    [taoensso.timbre :as timbre]))
+  (:require [braid.core.server.handler :refer [mobile-client-app
+                                               desktop-client-app
+                                               api-server-app]]
+            [braid.base.server.ws-handler] ; for mount
+            [braid.core.server.sync] ; for multimethods
+            [braid.base.server.jobs] ; for mount
+            [mount.core :as mount :refer [defstate]]
+            [org.httpkit.server :refer [run-server server-port server-stop!]]
+            [taoensso.timbre :as timbre]))

 ;; server

@@ -18,28 +17,30 @@
               :api #'api-server-app
               :desktop #'desktop-client-app
               :mobile #'mobile-client-app)]
-    (run-server app {:port port})))
+    (run-server app {:port port :legacy-return-value? false})))

 (defn start-servers! []
   (let [desktop-port (:port (mount/args))
-        mobile-port (inc desktop-port)
-        api-port (inc mobile-port)
         desktop-server (do
-                         (println "starting desktop client on port " desktop-port)
+                         (timbre/debugf "starting desktop server on port %d" desktop-port)
                          (start-server! :desktop desktop-port))
-        mobile-server (do (println "starting mobile client on port " mobile-port)
-                          (start-server! :mobile mobile-port))
-        api-server (do (println "starting api on port " api-port)
-                       (start-server! :api api-port))]
-    {:desktop desktop-server
-     :mobile mobile-server
-     :api api-server}))
+        desktop-port (server-port desktop-server)]
+    (timbre/debugf "Started desktop server on port %d" desktop-port)
+    (let [mobile-port (inc desktop-port)
+          api-port (inc mobile-port)
+          mobile-server (do (timbre/debugf "starting mobile server on port %d" mobile-port)
+                            (start-server! :mobile mobile-port))
+          api-server (do (timbre/debugf "starting api server on port %d" api-port)
+                         (start-server! :api api-port))]
+      {:desktop desktop-server
+       :mobile mobile-server
+       :api api-server})))

 (defn stop-servers!
   [srvs]
   (doseq [[typ srv] srvs]
-    (println "stopping server " (name typ))
-    (srv :timeout 100)))
+    (timbre/debugf "stopping server %s" (name typ))
+    @(server-stop! srv {:timeout 100})))

 (defstate servers
   :start (start-servers!)
@@ -50,11 +51,10 @@
 (defn set-default-exception-handler
   []
   (Thread/setDefaultUncaughtExceptionHandler
-    (reify Thread$UncaughtExceptionHandler
-      (uncaughtException [_ thread ex]
-        (timbre/errorf "Uncaught exception %s on %s" ex (.getName thread))
-        (.printStackTrace ex)))))
+   (reify Thread$UncaughtExceptionHandler
+     (uncaughtException [_ thread ex]
+       (timbre/errorf "Uncaught exception %s on %s" ex (.getName thread))
+       (.printStackTrace ex)))))

 (defstate thread-handler
   :start (set-default-exception-handler))
-


Update docstring for create-entity-txn

Update docstring for create-entity-txn

--- src/braid/server/db/common.clj
+++ src/braid/server/db/common.clj
@@ -4,7 +4,7 @@
             [clojure.edn :as edn]))

 (defn create-entity-txn
-  "create entity with attrs, return entity"
+  "create entity with attrs, return (after-fn entity)"
   [attrs after-fn]
   (let [new-id (d/tempid :entities)]
     [(with-meta


Shorten our API

Shorten our API

--- src/devtools/core.cljs
+++ src/devtools/core.cljs
@@ -64,7 +64,7 @@
         api-gen (fn [[name api-call]] [name (api-call-wrapper name api-call)])]
     (apply js-obj (mapcat #(api-gen %) api-mapping))))

-(defn install-devtools! []
+(defn install! []
   (if *devtools-installed*
     (debug/log-info "devtools already installed - nothing to do")
     (do
@@ -72,14 +72,14 @@
       (set! *original-formatter* (aget js/window formatter-key))
       (aset js/window formatter-key (cljs-formatter)))))

-; NOT SAFE
-(defn uninstall-devtools! []
+(defn uninstall! []
+  "this may be not safe if someone chained their formatter after us"
   (aset js/window formatter-key *original-formatter*)
   (set! *original-formatter* nil)
   (set! *devtools-installed* false))

-(defn disable-devtools! []
+(defn disable! []
   (set! *devtools-enabled* false))

-(defn enable-devtools! []
+(defn enable! []
   (set! *devtools-enabled* true))


CMR-964: Replaced some with seq

CMR-964: Replaced some with seq

--- search-app/src/cmr/search/data/complex_to_simple_converters/spatial.clj
+++ search-app/src/cmr/search/data/complex_to_simple_converters/spatial.clj
@@ -86,7 +86,7 @@
                   number-of-orbits
                   start-circular-latitude]} orbit-params]
       (when (and type
-                 (some? coords)
+                 (seq coords)
                  (and swath-width
                       period
                       inclination-angle


Don't need types anymore.

Don't need types anymore.

--- src/hxgm30/language/syntagmata/types.clj
+++ src/hxgm30/language/syntagmata/types.clj
@@ -1,58 +0,0 @@
-class BaseType(object):
-    '''
-    A base type for several types of object that are tracked in this module.
-    '''
-    def __init__(self):
-        self.name = self.__class__.__name__
-
-
-class IllegalType(BaseType):
-    '''
-    A character which does not belong to the alphabet being used.
-    '''
-
-
-class LetterType(BaseType):
-    '''
-    Just letters.
-    '''
-
-
-class VowelType(LetterType):
-    '''
-    A type for vowels.
-    '''
-
-
-class ConsonantType(LetterType):
-    '''
-    A type for consonants.
-    '''
-
-
-class InitialType(BaseType):
-    '''
-    A marker for initial pseudo-syllables.
-    '''
-
-
-class MedialType(BaseType):
-    '''
-    A marker for medial pseudo-syllables.
-    '''
-
-
-class FinalType(BaseType):
-    '''
-    A marker for final pseudo-syllables.
-    '''
-
-
-IllegalType = IllegalType()
-LetterType = LetterType()
-VowelType = VowelType()
-ConsonantType = ConsonantType()
-InitialType = InitialType()
-MedialType = MedialType()
-FinalType = FinalType()
-


add refresh task for remote dbs

add refresh task for remote dbs

--- build.boot
+++ build.boot
@@ -89,17 +89,52 @@

   (require 'user))

+(defn- get-datomic-uri
+  [{{uri :uri
+     auth? :requires-auth} :datomic}
+   {{akid :access-key-id
+     sk :secret-key} :aws}]
+
+  (if auth?
+    (str uri "?aws_access_key_id=" akid "&aws_secret_key=" sk)
+    uri))
+
+(defn- build-connection-string
+  []
+  (let [env (System/getProperty "APP_ENV")
+        env-settings (-> (str env ".edn")
+                         (clojure.java.io/resource)
+                         (clojure.java.io/file)
+                         (slurp)
+                         (clojure.edn/read-string))
+        config-settings (load-file
+                         (str (System/getProperty "user.home") "/.wombats/config.edn"))]
+    (get-datomic-uri env-settings config-settings)))
+
+(defn- refresh-db!
+  [uri]
+  (d/delete-database uri)
+  (d/create-database uri)
+  (let [conn (d/connect uri)]
+    @(d/transact conn (load-file "resources/datomic/schema.edn"))
+    @(d/transact conn (load-file "resources/datomic/roles.edn"))
+    @(d/transact conn (load-file "resources/datomic/users.edn"))))
+
+(deftask refresh-dev-ddb
+  "Resets the dev dynamo db"
+  []
+  (System/setProperty "APP_ENV" "dev-ddb")
+
+  (-> (build-connection-string)
+      refresh-db!))
+
 (deftask refresh-db
   "resets the database"
   []
+  (System/setProperty "APP_ENV" "dev")

-  (let [datomic-uri "datomic:free://localhost:4334/wombats-dev"
-        _ (d/delete-database datomic-uri)
-        _ (d/create-database datomic-uri)
-        conn (d/connect datomic-uri)]
-    @(d/transact conn (load-file "resources/datomic/schema.edn"))
-    @(d/transact conn (load-file "resources/datomic/roles.edn"))
-    @(d/transact conn (load-file "resources/datomic/users.edn"))))
+  (-> (build-connection-string)
+      refresh-db!))

 (deftask build
   "Creates a new build"


Update more deps. fix hot reload

Update more deps. fix hot reload

--- build.boot
+++ build.boot
@@ -2,7 +2,7 @@
  :source-paths   #{"src"}
  :resource-paths #{"resources"}
  :dependencies '[[org.clojure/clojurescript     "1.9.473"]
-                 [org.clojure/core.async        "0.2.391"]
+                 [org.clojure/core.async        "0.2.395"]
                  [reagent                       "0.6.0"]
                  [re-frame                      "0.9.2"]
                  [org.martinklepsch/boot-garden "1.3.2-0"]
@@ -12,7 +12,7 @@
                  [weasel                        "0.7.0"      :scope "test"]
                  [adzerk/boot-cljs              "1.7.228-1"  :scope "test"]
                  [adzerk/boot-cljs-repl         "0.3.3"      :scope "test"]
-                 [adzerk/boot-reload            "0.4.12"     :scope "test"]])
+                 [adzerk/boot-reload            "0.5.1"      :scope "test"]])

 (require
   '[adzerk.boot-cljs              :refer [cljs]]
@@ -38,7 +38,8 @@
         (cljs-repl :ids #{"renderer"})
         (reload    :ids #{"renderer"}
                    :ws-host "localhost"
-                   :on-jsload 'eion.renderer.core/init)
+                   :on-jsload 'eion.renderer.core/init
+                   :target-path "target")
         ; Compile renderer =========================================
         (cljs      :ids #{"renderer"})
         ;; Compile JS for main process ==============================


don't print every file

don't print every file

--- src/clj/runbld/tests/junit.clj
+++ src/clj/runbld/tests/junit.clj
@@ -103,12 +103,9 @@
                                     (debug/log e "Full trace")
                                     nil))]
                       :when xml]
-                  (do
-                    (rio/log "Looking for testsuite node in"
-                             (.getName (io/file failure)))
-                    (if-let [testsuite (x/select xml [[(x/tag= :testsuite)]])]
-                      (merge-default (make-failure-report testsuite))
-                      (rio/log "No testsuite node found."))))]
+                  (if-let [testsuite (x/select xml [[(x/tag= :testsuite)]])]
+                    (merge-default (make-failure-report testsuite))
+                    (rio/log "No testsuite node found.")))]
     (debug/log "Made" (count reports) "reports")
     (debug/log "Combining reports")
     (let [summary (reduce combine-failure-reports