ns collision fixed

ns collision fixed

--- src/etaoin/api.clj
+++ src/etaoin/api.clj
@@ -315,26 +315,26 @@
     (map? q)
     ["xpath" (q-xpath q)]))

-(defmulti find* dispatch-driver)
-
-(defmethod find* :firefox [driver locator term]
+(defmulti query* dispatch-driver)
+
+(defmethod query* :firefox [driver locator term]
   (with-resp driver :post
     [:session (:session @driver) :element]
     {:using locator :value term}
     resp
     (-> resp :value first second)))

-(defmethod find* :default [driver locator term]
+(defmethod query* :default [driver locator term]
   (with-resp driver :post
     [:session (:session @driver) :element]
     {:using locator :value term}
     resp
     (-> resp :value :ELEMENT)))

-(defn find [driver q]
+(defn query [driver q]
   (let [[locator term] (q-discover q)
         locator (or locator (:locator @driver))]
-    (find* driver locator term)))
+    (query* driver locator term)))

 ;;
 ;; mouse
@@ -362,7 +362,7 @@
   ([driver q]
    (with-resp driver :post
      [:session (:session @driver) :moveto]
-     {:element (find driver q)} _))
+     {:element (query driver q)} _))
   ([driver x y]
    (with-resp driver :post
      [:session (:session @driver) :moveto]
@@ -391,7 +391,7 @@
     nil _))

 (defn click [driver q]
-  (click* driver (find driver q)))
+  (click* driver (query driver q)))

 (defmulti double-click* dispatch-driver)

@@ -402,7 +402,7 @@
     nil _))

 (defn double-click [driver q]
-  (double-click* driver (find driver q)))
+  (double-click* driver (query driver q)))

 ;;
 ;; element size
@@ -427,7 +427,7 @@
     (-> resp (select-keys [:width :height]))))

 (defn get-element-size [driver q]
-  (get-element-size* driver (find driver q)))
+  (get-element-size* driver (query driver q)))

 ;;
 ;; element location
@@ -453,14 +453,14 @@
     (-> resp (select-keys [:x :y]))))

 (defn get-element-location [driver q]
-  (get-element-location* driver (find driver q)))
+  (get-element-location* driver (query driver q)))

 ;;
 ;; element box
 ;;

 (defn get-element-box [driver q]
-  (let [el (find driver q)
+  (let [el (query driver q)
         {:keys [width height]} (get-element-size* driver el)
         {:keys [x y]} (get-element-location* driver el)]
     {:x1 x
@@ -490,10 +490,10 @@
     (:value resp)))

 (defn get-element-attr [driver q name]
-  (get-element-attr* driver (find driver q) name))
+  (get-element-attr* driver (query driver q) name))

 (defn get-element-attrs [driver q & names]
-  (let [el (find driver q)]
+  (let [el (query driver q)]
     (mapv
      #(get-element-attr* driver el %)
      names)))
@@ -510,10 +510,10 @@
     (-> resp :value not-empty)))

 (defn get-element-css [driver q name]
-  (get-element-css* driver (find driver q) name))
+  (get-element-css* driver (query driver q) name))

 (defn get-element-csss [driver q & names]
-  (let [el (find driver q)]
+  (let [el (query driver q)]
     (mapv
      #(get-element-css* driver el %)
      names)))
@@ -550,7 +550,7 @@
     (:value resp)))

 (defn get-element-tag [driver q]
-  (get-element-tag* driver (find driver q)))
+  (get-element-tag* driver (query driver q)))

 (defn get-element-text* [driver el]
   (with-resp driver :get
@@ -560,7 +560,7 @@
     (:value resp)))

 (defn get-element-text [driver q]
-  (get-element-text* driver (find driver q)))
+  (get-element-text* driver (query driver q)))

 (defn get-element-value* [driver el]
   (with-resp driver :get
@@ -570,7 +570,7 @@
     (:value resp)))

 (defn get-element-value [driver q]
-  (get-element-value* driver (find driver q)))
+  (get-element-value* driver (query driver q)))

 ;;
 ;; cookes
@@ -786,7 +786,7 @@
     (:value resp)))

 (defn displayed? [driver q]
-  (visible* driver (find driver q)))
+  (visible* driver (query driver q)))

 (defn visible? [driver q]
   (and (exists? driver q)
@@ -802,7 +802,7 @@
     (:value resp)))

 (defn enabled? [driver q]
-  (enabled* driver (find driver q)))
+  (enabled* driver (query driver q)))

 (def disabled? (complement enabled?))

@@ -810,7 +810,7 @@
   (with-http-error
     (let [q (format "//*[contains(text(),'%s')]" text)]
       (with-xpath driver
-        (find driver q)
+        (query driver q)
         true))))

 (defn has-class* [driver el class]
@@ -821,7 +821,7 @@
       (str/includes? classes class))))

 (defn has-class? [driver q class]
-  (has-class* driver (find driver q) class))
+  (has-class* driver (query driver q) class))

 (def has-no-class? (complement has-class?))

@@ -895,7 +895,7 @@
   [driver q]
   (with-resp driver :post
     [:session (:session @driver) :touch :click]
-    {:element (find driver q)} _))
+    {:element (query driver q)} _))

 (defmulti touch-down dispatch-driver)

@@ -982,7 +982,7 @@
       {:value (vec keys)} _)))

 (defn fill [driver q text]
-  (fill* driver (find driver q) text))
+  (fill* driver (query driver q) text))

 ;;
 ;; submit
@@ -1015,7 +1015,7 @@
       (wait-key))))

 (defn fill-human [driver q text]
-  (fill-human* driver (find driver q) text))
+  (fill-human* driver (query driver q) text))

 ;;
 ;; screenshot
@@ -1117,3 +1117,12 @@
 (def chrome (partial boot-driver :chrome))
 (def phantom (partial boot-driver :phantom))
 (def safari (partial boot-driver :safari))
+
+(defmacro with-driver [type opt bind & body]
+  `(client/with-pool {}
+     (let [~bind (boot-driver ~type ~opt)]
+       (try
+         ~@body
+         (finally
+           (disconnect-driver ~bind)
+           (stop-driver ~bind))))))


use actions for double-click (#368)

use actions for double-click (#368)

--- src/etaoin/api.clj
+++ src/etaoin/api.clj
@@ -1014,13 +1014,16 @@

 (defmulti double-click-el dispatch-driver)

-(defmethods double-click-el
-  [:chrome :phantom]
+(defmethod double-click-el
+  :default
   [driver el]
   {:pre [(some? el)]}
-  (execute {:driver driver
-            :method :post
-            :path   [:session (:session driver) :element el :doubleclick]}))
+  (let [mouse   (-> (make-mouse-input)
+                    (add-pointer-move-to-el el)
+                    add-pointer-click
+                    (add-pause 10)
+                    add-pointer-click)]
+    (perform-actions driver mouse)))

 (defn double-click
   "Performs double click on an element.


Made translations dataset with rules feature of Datomic. Much more cleaner code!

--- src/kmg/domain.clj
+++ src/kmg/domain.clj
@@ -136,23 +136,25 @@
                  [?dbid :media/id ?id]]
                  db id)))

+(def translation-rule
+  '[[(translation ?mid1 ?mid2 ?locale)
+     [?rid :media.relationship/from ?mid1]
+     [?rid :media.relationship/to ?mid2]
+     [?rid :media.relationship/type :translation]
+     [?mid2 :media/locale ?locale]]
+    [(translation ?mid1 ?mid2 ?locale)
+     [?rid :media.relationship/from ?mid2]
+     [?rid :media.relationship/to ?mid1]
+     [?rid :media.relationship/type :translation]
+     [?mid2 :media/locale ?locale]]])
+
 (defn media-translations-dataset [db media-id locale]
-  (clojure.set/union   (d/q '[:find ?from
-         :in $ ?to ?locale
-         :where
-         [?rid :media.relationship/from ?from]
-         [?rid :media.relationship/to ?to]
-         [?rid :media.relationship/type :translation]
-         [?from :media/locale ?locale]]
-       db media-id locale)
-           (d/q '[:find ?to
-         :in $ ?from ?locale
-         :where
-         [?rid :media.relationship/from ?from]
-         [?rid :media.relationship/to ?to]
-         [?rid :media.relationship/type :translation]
-         [?to :media/locale ?locale]]
-       db media-id locale)))
+  (d/q '[:find ?mid2
+         :in $ % ?mid ?locale
+         :where
+         (translation ?mid ?mid2 ?locale)
+         [(< ?mid ?mid2)]]
+       db translation-rule media-id locale))

 ;;(media-translations-dataset (db) (media-dbid-by-id (db) "book1") :ru)


[#15]: preserving order of state changes

--- src/mount/core.clj
+++ src/mount/core.clj
@@ -116,7 +116,7 @@
          (sort-by :order))))

 (defn- bring [states fun order]
-  (let [done (atom #{})]
+  (let [done (atom [])]
     (->> states
          (sort-by (comp :order meta) order)
          (map #(fun % (meta %) done))


🐛 Exit with an error code if starting the app fails

Why:
- Docker build did not fail even though the app failed to start

--- src/territory_bro/main.clj
+++ src/territory_bro/main.clj
@@ -50,23 +50,23 @@
   (shutdown-agents))

 (defn start-app []
+  ;; start the public API only after the database is ready
+  (log-mount-states (mount/start #'config/env
+                                 #'db/database
+                                 #'projections/*cache
+                                 #'projections/refresher))
+  (migrate-database!)
+  (log/info "Database migrated")
+  (log-mount-states (mount/start))
+
+  (doto (Runtime/getRuntime)
+    (.addShutdownHook (Thread. ^Runnable stop-app)))
+  (log/info "Started"))
+
+(defn -main [& _args]
   (try
-    ;; start the public API only after the database is ready
-    (log-mount-states (mount/start #'config/env
-                                   #'db/database
-                                   #'projections/*cache
-                                   #'projections/refresher))
-    (migrate-database!)
-    (log/info "Database migrated")
-    (log-mount-states (mount/start))
-
-    (doto (Runtime/getRuntime)
-      (.addShutdownHook (Thread. ^Runnable stop-app)))
-    (log/info "Started")
+    (start-app)
     (catch Throwable t
       ;; XXX: clojure.tools.logging/error does not log the ex-data by default https://clojure.atlassian.net/browse/TLOG-17
       (log/error t (str "Failed to start\n" (pr-str t)))
-      (stop-app))))
-
-(defn -main [& _args]
-  (start-app))
+      (System/exit 1))))


Make ring uberjar work with vector profiles (fixes #131)

--- src/leiningen/ring/uberjar.clj
+++ src/leiningen/ring/uberjar.clj
@@ -5,11 +5,19 @@
             [leiningen.clean :as clean]
             leiningen.uberjar))

+(defn- assoc-profile [project profile-name key value]
+  (let [profile (get-in project [:profiles profile-name])]
+    (assoc-in project [:profiles profile-name]
+              (cond
+               (vector? profile) (conj profile {key value})
+               (map? profile)    (assoc profile key value)
+               (nil? profile)    {key value}))))
+
 (defn- no-uberjar-clean [project]
   "Modifies the uberjar profile so that no auto-clean is performed
   when leiningen takes control, thus avoiding the autogenerated main files
   from being wiped."
-  (vary-meta project assoc-in [:profiles :uberjar :auto-clean] false))
+  (vary-meta project assoc-profile :uberjar :auto-clean false))

 (defn uberjar
   "Create an executable $PROJECT-$VERSION.jar file with dependencies."
@@ -19,4 +27,4 @@
     (clean/clean project))
   (let [project (-> project add-server-dep jar/add-main-class no-uberjar-clean)]
     (jar/compile-main project)
-    (leiningen.uberjar/uberjar project)))+    (leiningen.uberjar/uberjar project)))


/dot redirect to dotfiles install script

--- src/nossal/web.clj
+++ src/nossal/web.clj
@@ -4,6 +4,7 @@
             [compojure.route :as route]
             [clojure.java.io :as io]
             [ring.adapter.jetty :as jetty]
+            [ring.util.response :as res]
             [environ.core :refer [env]]
             [hiccup.core :as h]
             [hiccup.page :as page]))
@@ -67,7 +68,7 @@

 (defn dot [req]
-  (str req))
+  (res/redirect "https://raw.githubusercontent.com/nossal/dotfiles/master/dot"))

 (defroutes app


stop using abbreviations in code

stop using abbreviations in code

--- src/yorck_ratings/core.clj
+++ src/yorck_ratings/core.clj
@@ -1,8 +1,8 @@
 (ns yorck-ratings.core
   (:require [org.httpkit.client :as http]
-            [clojure.core.async :as a]
-            [hickory.select :as h]
-            [clojure.string :as str])
+            [clojure.core.async :as async]
+            [hickory.select :as hickory]
+            [clojure.string :as string])
   (:use [hickory.core])
   (:import (java.util.regex Pattern)
            (java.net URLEncoder)))
@@ -30,10 +30,10 @@
             (fn [{:keys [status body error]}]
               (if error
                 (let [{cause :cause} (Throwable->map error)]
-                  (a/put! error-ch (error-message url cause)))
+                  (async/put! error-ch (error-message url cause)))
                 (if (> status 399)
-                  (a/put! error-ch (error-message url status))
-                  (a/put! result-ch (as-hickory (parse body))))))))
+                  (async/put! error-ch (error-message url status))
+                  (async/put! result-ch (as-hickory (parse body))))))))

 (defn fetch-yorck-list [result-ch error-ch]
   (async-get (str yorck-base-url "/filme?filter_today=true") result-ch error-ch))
@@ -44,33 +44,33 @@
     (async-get url result-ch error-ch)))

 (defn fetch-imdb-dp [error-ch movie-ch result-ch]
-  (a/go
-    (let [movie (a/<! movie-ch)]
+  (async/go
+    (let [movie (async/<! movie-ch)]
       (async-get (:imdb-url movie) result-ch error-ch)
       movie)))

 (defn rotate-article [title]
   (let [pattern (Pattern/compile "^([\\w\\s]+), (Der|Die|Das|The)", Pattern/UNICODE_CHARACTER_CLASS)]
-    (str/replace-first title pattern "$2 $1")))
+    (string/replace-first title pattern "$2 $1")))

 (defn remove-dimension [title]
   (let [pattern (Pattern/compile " (- )?2D.*", Pattern/UNICODE_CHARACTER_CLASS)]
-    (str/replace-first title pattern "")))
+    (string/replace-first title pattern "")))

 (defn yorck-titles [yorck-page]
   (->> yorck-page
-       (h/select (h/descendant
-                   (h/class :movie-details)
-                   (h/tag :h2)))
+       (hickory/select (hickory/descendant
+                         (hickory/class :movie-details)
+                         (hickory/tag :h2)))
        (mapcat :content)
        (mapv rotate-article)
        (mapv remove-dimension)))

 (defn yorck-urls [yorck-page]
   (->> yorck-page
-       (h/select (h/descendant
-                   (h/class :movie-details)
-                   (h/tag :a)))
+       (hickory/select (hickory/descendant
+                         (hickory/class :movie-details)
+                         (hickory/tag :a)))
        (mapv :attrs)
        (map :href)
        (map #(str yorck-base-url %))))
@@ -83,22 +83,22 @@

 (defn imdb-title [sp]
   (->> sp
-       (h/select (h/descendant
-                   (h/class :posters)
-                   (h/class :poster)
-                   (h/class :title)
-                   (h/tag :a)))
+       (hickory/select (hickory/descendant
+                         (hickory/class :posters)
+                         (hickory/class :poster)
+                         (hickory/class :title)
+                         (hickory/tag :a)))
        first
        :content
        first))

 (defn imdb-url [sp]
   (->> sp
-       (h/select (h/descendant
-                   (h/class :posters)
-                   (h/class :poster)
-                   (h/class :title)
-                   (h/tag :a)))
+       (hickory/select (hickory/descendant
+                         (hickory/class :posters)
+                         (hickory/class :poster)
+                         (hickory/class :title)
+                         (hickory/tag :a)))
        (mapv :attrs)
        (mapv :href)
        first
@@ -107,10 +107,10 @@
 (defn imdb-rating [dp]
   (try
     (->> dp
-         (h/select (h/descendant
-                     (h/id :ratings-bar)
-                     h/first-child
-                     (h/class :inline-block)))
+         (hickory/select (hickory/descendant
+                           (hickory/id :ratings-bar)
+                           hickory/first-child
+                           (hickory/class :inline-block)))
          first
          :content
          first
@@ -118,16 +118,16 @@
     (catch Exception e 0.0)))

 (defn- remove-comma [s]
-  (str/replace-first s "," ""))
+  (string/replace-first s "," ""))

 (defn imdb-rating-count [dp]
   (try
     (->> dp
-         (h/select (h/descendant
-                     (h/id :ratings-bar)
-                     h/first-child
-                     (h/class :inline-block)
-                     (h/class :text-muted)))
+         (hickory/select (hickory/descendant
+                           (hickory/id :ratings-bar)
+                           hickory/first-child
+                           (hickory/class :inline-block)
+                           (hickory/class :text-muted)))
          first
          :content
          last
@@ -140,38 +140,38 @@
    :imdb-url   (imdb-url sp)})

 (defn with-imdb-sp-infos [movie ch]
-  (a/go (merge movie (imdb-sp-infos (a/<! ch)))))
+  (async/go (merge movie (imdb-sp-infos (async/<! ch)))))

 (defn with-rating [movie-ch dp-ch]
-  (a/go
-    (let [movie (a/<! movie-ch)
-          page (a/<! dp-ch)]
+  (async/go
+    (let [movie (async/<! movie-ch)
+          page (async/<! dp-ch)]
       (merge movie {:rating (imdb-rating page)
                     :rating-count (imdb-rating-count page)}))))

 (defn remove-sneak-preview [movies]
-  (remove #(str/includes? (str/lower-case (:yorck-title %)) "sneak") movies))
+  (remove #(string/includes? (string/lower-case (:yorck-title %)) "sneak") movies))

 (defn rated-movies [cb]
-  (a/go
-    (let [result-ch (a/chan 1 (comp
+  (async/go
+    (let [result-ch (async/chan 1 (comp
                                 (map yorck-titles-urls)
                                 (map remove-sneak-preview)))
-          error-ch (a/chan)
-          imdb-sp-chs (repeatedly (partial a/chan 1))
-          imdb-dp-chs (repeatedly (partial a/chan 1))
+          error-ch (async/chan)
+          imdb-sp-chs (repeatedly (partial async/chan 1))
+          imdb-dp-chs (repeatedly (partial async/chan 1))

           _ (fetch-yorck-list result-ch error-ch)

-          yorck-infos (a/<! result-ch)
+          yorck-infos (async/<! result-ch)

-          _ (doall (map (partial fetch-imdb-sp error-ch) yorck-infos imdb-sp-chs))
+          _ (doall (map #(fetch-imdb-sp error-ch %1 %2) yorck-infos imdb-sp-chs))
           movie-chs (map with-imdb-sp-infos yorck-infos imdb-sp-chs)
-          m-chs (doall (map (partial fetch-imdb-dp error-ch) movie-chs imdb-dp-chs))
+          m-chs (doall (map #(fetch-imdb-dp error-ch %1 %2) movie-chs imdb-dp-chs))
           rated-movie-chs (map with-rating m-chs imdb-dp-chs)]

-      (a/map (fn [& movies] (cb (reverse (sort-by :rating movies)))) rated-movie-chs)
-      (a/close! result-ch)
-      (a/close! error-ch)
-      (map a/close! imdb-sp-chs)
-      (map a/close! imdb-dp-chs))))
+      (async/map (fn [& movies] (cb (reverse (sort-by :rating movies)))) rated-movie-chs)
+      (async/close! result-ch)
+      (async/close! error-ch)
+      (map async/close! imdb-sp-chs)
+      (map async/close! imdb-dp-chs))))


Return sorted data

Return sorted data


Add `of-minutes`

Add `of-minutes`

--- src/tick/core.cljc
+++ src/tick/core.cljc
@@ -597,6 +597,11 @@
   "Takes a java.lang.Long n and returns a duration of n seconds."
   [n]
   (new-duration n :seconds))
+
+(defn of-minutes
+  "Takes a java.lang.Long n and returns a duration of n minutes."
+  [n]
+  (new-duration n :minutes))

 ;; Coercions


Fix to new-plan script

Fix to new-plan script

--- backend/src/akvo/lumen/admin/new_plan.clj
+++ backend/src/akvo/lumen/admin/new_plan.clj
@@ -8,7 +8,8 @@
   $ env PG_HOST=***.db.elephantsql.com PG_DATABASE=*** \\
         PG_USER=*** PG_PASSWORD=*** \\
         lein run -m akvo.lumen.admin.new-plan example-tenant standard"
-  (:require [akvo.lumen.config :refer [error-msg]]
+  (:require [akvo.lumen.admin.util :refer [db-uri]]
+            [akvo.lumen.config :refer [error-msg]]
             [clojure.java.jdbc :refer [print-sql-exception-chain
                                        with-db-transaction]]
             [environ.core :refer [env]]
@@ -19,21 +20,17 @@

 (hugsql/def-db-fns "akvo/lumen/component/tenant_manager.sql")

+
 (defn check-env-vars []
   (assert (:pg-database env) (error-msg "Specify PG_DATABASE env var"))
   (assert (:pg-host env) (error-msg "Specify PG_HOST env var"))
   (assert (:pg-password env) (error-msg "Specify PG_PASSWORD env var"))
   (assert (:pg-user env) (error-msg "Specify PG_USER env var")))

-(defn db-uri []
-  (check-env-vars)
-  (format "jdbc:postgres://%s:5432/%s?user=%s&password=%s"
-          (:pg-host env) (:pg-database env)
-          (:pg-user env) (:pg-password env)))
-
 (defn -main [label tier]
   (try
-    (with-db-transaction [tx (db-uri)]
+    (check-env-vars)
+    (with-db-transaction [tx (db-uri {:database "lumen" :user "lumen"})]
       (end-tenant-plan tx {:label label})
       (add-new-plan tx {:label label
                         :tier (doto (PGobject.)


Register more matchmakers

Register more matchmakers

--- src/matchmaker_sparql/spec.clj
+++ src/matchmaker_sparql/spec.clj
@@ -35,10 +35,17 @@
 (s/def ::inferred-object-inhibition ::weight)

 (s/def ::kind #{:exact-cpv
+                :exact-cpv-goedel
                 :exact-cpv-additional-object
                 :exact-cpv-with-qualifier
                 :exact-cpv-additional-object-with-qualifier
-                :exact-cpv-with-zindex})
+                :exact-cpv-with-zindex
+                :exact-cpv-only-open-procedure
+                :expand-to-broader-cpv
+                :kind
+                :service-category
+                :top-page-rank-bidders
+                :top-winning-bidders})

 (s/def ::limit ::positive-int)


marks test-retry-failed-instances as flaky (#236)

--- waiter/test/waiter/scheduler/shell_test.clj
+++ waiter/test/waiter/scheduler/shell_test.clj
@@ -533,7 +533,9 @@
             (is (= {:num-reserved-ports 11} ex-data))
             (is (= "Unable to reserve 20 ports" (.getMessage ex)))))))))

-(deftest test-retry-failed-instances
+; Marked explicit due to:
+; - https://github.com/twosigma/waiter/issues/235
+(deftest ^:explicit test-retry-failed-instances
   (let [scheduler-config {:health-check-timeout-ms 1
                           :port-grace-period-ms 1
                           :port-range [10000 11000]


Make alpha/beta/etc versions incompatible with each other.

--- src/onyx/peer/log_version.cljc
+++ src/onyx/peer/log_version.cljc
@@ -3,7 +3,7 @@
 (def version "0.10.0-SNAPSHOT")

 (defn check-compatible-log-versions! [cluster-version]
-  (when-not (or (re-find #"-" version)
+  (when-not (or (re-find #"-SNAPSHOT" version)
                  (= version cluster-version))
     (throw (ex-info "Incompatible versions of the Onyx cluster coordination log.
                      A new, distinct, :onyx/tenancy-id should be supplied when upgrading or downgrading Onyx."


ledger-end-id not necessarily supplied

ledger-end-id not necessarily supplied

--- src/onyx/plugin/bookkeeper.clj
+++ src/onyx/plugin/bookkeeper.clj
@@ -68,14 +68,15 @@
         (recur entries
                (.nextElement entries))))))

+(def read-chunk-size 100)
+
 (defn read-ledger-entries! [^LedgerHandle ledger-handle last-acked max-id read-ch]
   (info "Starting BooKeeper input ledger reader at:" (inc last-acked))
-  (let [ledger-id (.getId ledger-handle)
-        chunk-size 1]
+  (let [ledger-id (.getId ledger-handle)]
     (loop [;; only need to read this once unless recover mode
            last-confirmed (.getLastAddConfirmed ledger-handle)
            start (inc last-acked)
-           end (min last-confirmed max-id (+ start chunk-size))]
+           end (min last-confirmed max-id (+ start read-chunk-size))]
       (when (and (not (neg? last-confirmed))
                  (< last-acked last-confirmed)
                  (< start last-confirmed))
@@ -83,7 +84,7 @@
         (let [last-confirmed (.getLastAddConfirmed ledger-handle)]
           (recur last-confirmed
                  (inc end)
-                 (min last-confirmed max-id (+ (inc end) chunk-size))))))))
+                 (min last-confirmed max-id (+ (inc end) read-chunk-size))))))))

 (defn inject-read-ledgers-resources
   [{:keys [onyx.core/task-map onyx.core/log onyx.core/task-id onyx.core/pipeline onyx.core/peer-opts] :as event} lifecycle]
@@ -92,7 +93,7 @@
   (let [start-id (if-let [start (:bookkeeper/ledger-start-id task-map)]
                    (dec start)
                    -1)
-        max-id (:bookkeeper/ledger-end-id task-map)
+        max-id (or (:bookkeeper/ledger-end-id task-map) Double/POSITIVE_INFINITY)
         {:keys [read-ch shutdown-ch commit-ch]} pipeline
         checkpoint-key (or (:checkpoint/key task-map) task-id)
         _ (set-starting-offset! log task-map checkpoint-key start-id)


util/hadoop.clj: truncate huge keys in reducer log

--- src/org/altlaw/util/hadoop.clj
+++ src/org/altlaw/util/hadoop.clj
@@ -127,11 +127,11 @@
 (defn standard-reduce [reduce-fn this wkey wvalues-iter output reporter]
   (let [key (read-string (str wkey))
         values (map #(read-string (str %)) (iterator-seq wvalues-iter))]
-    (log/debug "Reducer input: " (pr-str key)
+    (log/debug "Reducer input: " (log/logstr key)
                " => " (log/logstr values))
     (binding [*reporter* reporter]
       (doseq [[key value] (reduce-fn key values)]
-        (log/debug "Reducer OUTPUT: " (pr-str key)
+        (log/debug "Reducer OUTPUT: " (log/logstr key)
                    " => " (log/logstr value))
         (.collect output (Text. (pr-str key))
                   (Text. (pr-str value)))))))


adding synth control to sequencer test code

--- src/overtone/gui/sequencer.clj
+++ src/overtone/gui/sequencer.clj
@@ -58,6 +58,7 @@
 (comment
   (use 'overtone.live)
   (use 'overtone.gui.sequencer)
+  (use 'overtone.gui.control)
   (use 'overtone.inst.synth)
   (def m (metronome 128))
   (step-sequencer m 8 ks1 ping)


Fixed mod-update (tests passing)

Fixed mod-update (tests passing)

--- src/polismath/conversation.clj
+++ src/polismath/conversation.clj
@@ -394,7 +394,7 @@
 (defn mod-update
   "Take a conversation record and a seq of moderation data and updates the conversation's mod-out attr"
   [conv mods]
-  (let [mod-sep (fn [mod] (->> mods (filter #{mod}) (map :tid)))
+  (let [mod-sep (fn [mod] (->> mods (filter (comp #{mod} :mod)) (map :tid)))
         mod-out (mod-sep -1)
         mod-in  (mod-sep 1)]
     (update-in conv


Renamed protector to login-form

Renamed protector to login-form

--- src/cylon/core.clj
+++ src/cylon/core.clj
@@ -363,7 +363,7 @@
 ;; authenticator and session store. Different constructors can build this
 ;; component in different ways.

-(defrecord ProtectionSystem [protector user-authenticator http-session-store]
+(defrecord ProtectionSystem [login-form user-authenticator http-session-store]
   component/Lifecycle
   (start [this] (component/start-system this (keys this)))
   (stop [this] (component/stop-system this (keys this)))
@@ -375,7 +375,7 @@
   (routes [this] ["" (vec (keep #(when (satisfies? BidiRoutesProvider %) (routes %)) (vals this)))])
   (context [this] (or
                    (first (keep #(when (satisfies? BidiRoutesProvider %) (context %))
-                                ((juxt :protector :user-authenticator :http-session-store) this)))
+                                ((juxt :login-form :user-authenticator :http-session-store) this)))
                    ""))

   BidiRoutesProtector
@@ -383,7 +383,7 @@
     (add-bidi-protection-wrapper
      routes
      :http-request-authenticator (new-session-based-request-authenticator :http-session-store (:http-session-store this))
-     :failed-authentication-handler (->BidiFailedAuthenticationRedirect (get-in (:protector this) [:handlers :get-handler]))))
+     :failed-authentication-handler (->BidiFailedAuthenticationRedirect (get-in (:login-form this) [:handlers :get-handler]))))

   NewUserCreator
   (add-user! [_ uid pw]
@@ -400,14 +400,14 @@
 (defn new-default-protection-system [& {:as opts}]
   (s/validate new-default-protection-system-schema opts)
   (map->ProtectionSystem
-   {:protector (if-let [boilerplate (:boilerplate opts)]
-                 (new-login-form :boilerplate boilerplate)
-                 (new-login-form))
+   {:login-form (if-let [boilerplate (:boilerplate opts)]
+                  (new-login-form :boilerplate boilerplate)
+                  (new-login-form))
     :user-authenticator (component/using (new-user-domain) [:password-store])
     :password-store (new-password-file (:password-file opts))
     :http-session-store (new-atom-backed-session-store
                          (or (:session-timeout-in-seconds opts)
-                             (* 60 60) ; one hour by default
+                             (* 60 60)  ; one hour by default
                              ))}))

 ;; Now that we have a protection system, we want the ability to create
@@ -416,10 +416,10 @@
 (defrecord ProtectedBidiRoutes [routes context]
   component/Lifecycle
   (start [this]
-    (let [protector (get-in this [:protection-system])
+    (let [protection (get-in this [:protection-system])
           routes (cond-> routes
                          (fn? routes) (apply [this])
-                         protector ((partial protect-bidi-routes protector)))]
+                         protection ((partial protect-bidi-routes protection)))]
       (assoc this :routes routes)))
   (stop [this] this)


Postinst, not postinstall

Postinst, not postinstall

--- src/fatty/core.clj
+++ src/fatty/core.clj
@@ -98,7 +98,7 @@
 (defn build-rpm
   "Builds a rpm"
   [project-name version os-data]
-  (let [status (sh "fpm" "-s" "dir" "-t" "rpm" "-v" version "-n" project-name "/opt/opscode" "-m" "Opscode, Inc." "--post-install" "../source/postinstall" "--post-uninstall" "../source/postrm" "--description" "The full stack install of Opscode Chef" "--url" "http://www.opscode.com" :dir "./pkg")]
+  (let [status (sh "fpm" "-s" "dir" "-t" "rpm" "-v" version "-n" project-name "/opt/opscode" "-m" "Opscode, Inc." "--post-install" "../source/postinst" "--post-uninstall" "../source/postrm" "--description" "The full stack install of Opscode Chef" "--url" "http://www.opscode.com" :dir "./pkg")]
     (log-sh-result status
                    (str "Created rpm package")
                    (str "Failed to create rpm package"))))


update upload api handler to add images to coll

--- src/imago/core.clj
+++ src/imago/core.clj
@@ -274,16 +274,20 @@
             (let [user-id (-> req current-user :id)
                   files   (filter :tempfile (vals (:params req)))
                   presets (collection-presets coll-id)
+                  coll    (model/describe-as-collection @(:g graph) coll-id)
                   img-map (zipmap
-                           (repeatedly #(model/make-stillimage {:colls [coll-id] :publisher user-id}))
+                           (repeatedly #(model/make-stillimage {:colls [coll] :publisher user-id}))
                            (map :tempfile files))
                   _       (info :img-map img-map)
                   _       (info :presets presets)
                   images  (handle-uploaded-images img-map presets)
-                  versions (mapcat :versions images)]
+                  versions (mapcat :versions images)
+                  coll    (-> coll
+                              (update-in [:media] into (map :id images))
+                              (assoc :modified (utils/timestamp)))]
               (->> images
                    (map (fn [img] (update-in img [:versions] #(map :id %))))
-                   (concat [[coll-id (:modified dcterms) (utils/timestamp)]] versions)
+                   (concat [coll] versions)
                    (trio/triple-seq)
                    (gapi/add-triples graph))
               (api-response req (mapv :id images) 200)))))


Fix tests

Fix tests

--- test/asciinema_player/core_test.cljs
+++ test/asciinema_player/core_test.cljs
@@ -12,7 +12,7 @@
       (is (= (:duration player) 123.45))
       (is (= (:start-at player) 0))
       (is (= (:current-time player) 0))
-      (is (= (:theme player) "seti"))
+      (is (= (:theme player) "asciinema"))
       (is (= (:font-size player) "small"))
       (is (= (:speed player) 1))
       (is (= (:auto-play player) false))


Add test for reusable connection managers

Relates to #355

--- test/clj_http/test/conn_mgr_test.clj
+++ test/clj_http/test/conn_mgr_test.clj
@@ -119,3 +119,13 @@
     (is (nil? (:body response)) "response shouldn't have body")
     (is (= 304 (:status response)))
     (is @shutdown? "connection manager should be shutdown")))
+
+(deftest t-reusable-conn-mgrs
+  (let [regular (conn-mgr/make-regular-conn-manager {})
+        regular-reusable (conn-mgr/make-reusable-conn-manager {})
+        async (conn-mgr/make-regular-async-conn-manager {})
+        async-reusable (conn-mgr/make-reuseable-async-conn-manager {})]
+    (is (false? (conn-mgr/reusable? regular)))
+    (is (true? (conn-mgr/reusable? regular-reusable)))
+    (is (false? (conn-mgr/reusable? async)))
+    (is (true? (conn-mgr/reusable? async-reusable)))))


Dun goofed the link middleware test.

Dun goofed the link middleware test.

--- test/lambda_blog/middleware_test.clj
+++ test/lambda_blog/middleware_test.clj
@@ -55,8 +55,7 @@

 (deftest linking-entries-works
   (let [es [{:title 1} {:title 2} {:title 3}]
-        linked ((link :entries) {:entries es})
-        les (:entries linked)]
+        les (link es)]
     (is (= (:previous (first les))
            nil))
     (is (= (:next (first les))


Trap initial load error and cancel autotest #229 #215

--- src/midje/repl.clj
+++ src/midje/repl.clj
@@ -519,9 +519,14 @@
             (start-periodic-check)

             (empty? args)
-            (do
+            (try
               (project-state/load-everything (autotest-options))
-              (start-periodic-check))
+              (start-periodic-check)
+            (catch Throwable t
+              (autotest :stop)
+              (println (color/fail "Because failures in the initial load break autotest's dependency tracking,"))
+              (println (color/fail "autotest has been cancelled."))))
+

             (and (:files? option)
                  (complained-about-missing-on-filesystem? (:files-args option)))


And again...

And again...

--- src/notes/paas.clj
+++ src/notes/paas.clj
@@ -48,7 +48,7 @@
 (defn mongo-connection-uri [uid pwd]
   "Try to figure out runtime environment and resolve associated MongoDB
   connection URI. Defaults to localhost and standard port"
-  (println "System Envs: " (System/getenv)
+  (println "System Envs: " (System/getenv))
   (cond (is-dotcloud?) (dotcloud-uri uid pwd)
         (is-open-shift?) (open-shift-uri uid pwd)
         (is-heroku?) (heroku-uri uid pwd)


update todo

update todo

--- src/pc/datomic.clj
+++ src/pc/datomic.clj
@@ -53,8 +53,8 @@
 (defn uuid []
   (UUID/randomUUID))

+;; TODO: remove, deprecated by frontend ids
 (defn generate-eids [conn tempid-count]
-  ;; TODO: support for multiple parts
   (let [tempids (take tempid-count (repeatedly #(d/tempid :db.part/user)))
         transaction (d/transact conn (mapv (fn [tempid] {:db/id tempid :dummy :dummy/dummy}) tempids))]
     (mapv (fn [tempid] (d/resolve-tempid (:db-after @transaction) (:tempids @transaction) tempid)) tempids)))


Improve idiom in compare-seqs.

Improve idiom in compare-seqs.

--- src/puget/data.clj
+++ src/puget/data.clj
@@ -38,8 +38,7 @@
   sequences orders differently, it determines the ordering. Otherwise, if the
   prefix matches, the longer sequence sorts later."
   [order xs ys]
-  (or (some #(when-not (= 0 %) %)
-            (map order xs ys))
+  (or (first (remove zero? (map order xs ys)))
       (- (count xs) (count ys))))


🔥 Remove TODO comment

🔥 Remove TODO comment

Why:
- The presence-tracker should handle this case correctly.

--- src/territory_bro/gis_user.clj
+++ src/territory_bro/gis_user.clj
@@ -165,7 +165,6 @@
       :gis-user/password (generate-password)}]))

 (defmethod command-handler :gis-user.command/delete-gis-user [command state _injections]
-  ;; TODO: should this be idempotent? send event even if gis user is missing?
   (when-some [username (get-in state (username-path command))]
     [{:event/type :congregation.event/gis-user-deleted
       :event/version 1


Update org.akvo/commons to "0.4.6"

Update org.akvo/commons to "0.4.6"

--- backend/project.clj
+++ backend/project.clj
@@ -24,7 +24,7 @@
                  [honeysql "0.9.4"]
                  [meta-merge "1.0.0"]
                  [metosin/reitit "0.3.7" :exclusions [com.cognitect/transit-java org.clojure/spec.alpha org.ow2.asm/asm ring/ring-core mvxcvi/puget org.clojure/clojure ring/ring-codec org.clojure/core.rrb-vector mvxcvi/arrangement fipp r org.clojure/core.specs.alpha com.cognitect/transit-clj com.fasterxml.jackson.core/jackson-databind com.fasterxml.jackson.core/jackson-core]]
-                 [org.akvo/commons "0.4.5" :exclusions [org.postgresql/postgresql org.clojure/java.jdbc]]
+                 [org.akvo/commons "0.4.6" :exclusions [org.postgresql/postgresql org.clojure/java.jdbc]]
                  [org.akvo/resumed "1.46.266acfa5bb52c9b484af19f0bcfbfacb60b97319"]
                  [org.apache.tika/tika-core "1.18"]
                  [org.apache.tika/tika-parsers "1.18" :exclusions [org.slf4j/slf4j-api com.fasterxml.jackson.core/jackson-core org.apache.httpcomponents/httpcore org.apache.httpcomponents/httpclient org.apache.httpcomponents/httpmime]]


Don't autorun

Don't autorun

--- src/art/flower_01.clj
+++ src/art/flower_01.clj
@@ -26,7 +26,6 @@
         num-rings (- (* num-flowers 2) 1)
         flower-sizes (take num-flowers sizes)
         ring-sizes (take num-rings sizes)]
-
     (q/stroke-weight 1)
     (doseq [size flower-sizes] (flower size))
     (q/stroke-weight 2)
@@ -40,7 +39,7 @@
   (q/stroke 255)
   (q/stroke-weight 1)
   (render)
-  ; (q/save "flower.png")
+  (q/save "flower.png")
   )

 (defn step [state] state)
@@ -60,4 +59,4 @@
     :draw draw
     :size [width height]
     ))
-(run)
+; (run)


Indentation

Indentation

--- src/aurora/btree.cljs
+++ src/aurora/btree.cljs
@@ -42,7 +42,8 @@
             lo
             (let [mid (+ lo (js/Math.floor (/ (- hi lo) 2)))
                   mid-key (aget keys mid)]
-              (if (> mid-key key) (recur lo (- mid 1))
+              (if (> mid-key key)
+                (recur lo (- mid 1))
                 (if (< mid-key key)
                   (recur (+ mid 1) hi)
                   mid))))))


CMR-7197: removed some whitespace

CMR-7197: removed some whitespace

--- system-int-test/test/cmr/system_int_test/ingest/subscription_ingest_test.clj
+++ system-int-test/test/cmr/system_int_test/ingest/subscription_ingest_test.clj
@@ -35,10 +35,6 @@
     (subscription-util/grant-all-subscription-fixture {"provguid1" "PROV3"}
                                                       [:read]
                                                       [:read :update])]))
-
-
-
-

 (defn- process-subscriptions
   "Sets up process-subscriptions arguments. Calls process-subscriptions, returns granule concept-ids."


#2250: Fix Pedestal updates test

#2250: Fix Pedestal updates test

1. Fixed updates test to avoid lazy "for" that was not actually doing
the updates.
2. Cleaned up remaining code to match Compojure/http-kit implementation
as possible for easy diffing.

--- frameworks/Clojure/pedestal/src/pedestal/service.clj
+++ frameworks/Clojure/pedestal/src/pedestal/service.clj
@@ -13,19 +13,26 @@
             [clojure.data.json :as json]
             [clojure.java.jdbc :as jdbc]))

+(defn sanitize-queries-param
+  "Sanitizes the `queries` parameter. Clamps the value between 1 and 500.
+  Invalid (string) values become 1."
+  [request]
+  (let [queries (-> request
+                    :params
+                    :queries)
+        n (try (Integer/parseInt queries)
+               (catch Exception e 1))] ; default to 1 on parse failure
+    (cond
+      (< n 1) 1
+      (> n 500) 500
+      :else n)))

-(defn json-serialization
-  "Test 1: JSON serialization"
-  [request]
-  (bootstrap/json-response {:message "Hello, World!"}))
-
-
-;; MySQL connection
-(defdb mysql-db
+;; MySQL database connection
+(defdb db-mysql
   (mysql {
     :classname "com.mysql.jdbc.Driver"
     :subprotocol "mysql"
-    :subname "//127.0.0.1:3306/hello_world"
+    :subname "//127.0.0.1:3306/hello_world?jdbcCompliantTruncation=false&elideSetAutoCommits=true&useLocalSessionState=true&cachePrepStmts=true&cacheCallableStmts=true&alwaysSendSetIsolation=false&prepStmtCacheSize=4096&cacheServerConfiguration=true&prepStmtCacheSqlLimit=2048&zeroDateTimeBehavior=convertToNull&traceProtocol=false&useUnbufferedInput=false&useReadAheadInput=false&maintainTimeStats=false&useServerPrepStmts&cacheRSMetadata=true"
     :user "benchmarkdbuser"
     :password "benchmarkdbpass"
     ;;OPTIONAL KEYS
@@ -37,65 +44,32 @@
 (defentity world
   (pk :id)
   (table :world)
-  (entity-fields :id :randomNumber) ;; Default fields for select
-  (database mysql-db))
+  (entity-fields :id :randomNumber) ; Default fields for select
+  (database db-mysql))

-
-(defn random-world
+(defn get-random-world-korma
   "Query a random World record from the database"
   []
   (let [id (inc (rand-int 9999))] ; Num between 1 and 10,000
     (select world
             (where {:id id }))))

+(defn run-queries
+  "Run query repeatedly, return an array"
+  [queries]
+  (flatten ; Make it a list of maps
+    (take queries ; Number of queries to run
+          (repeatedly get-random-world-korma))))

-(defn run-queries
-  "Run query repeatedly -- Always returns an array"
-  [queries]
-  (flatten (take queries (repeatedly random-world))))
-
-
-(defn single-query-test
-  "Test 2: Single database query"
-  [request]
-  (bootstrap/json-response (first (run-queries 1))))
-
-
-(defn sanitizeQueriesParam
-  "Sanitizes the `queries` parameter. Caps the value between 1 and 500.
-  Invalid (stringy) values become 1"
-  [request]
-  (let [queries (-> request
-                    :params
-                    :queries)]
-    (if-let [n (if (= (re-find #"\A-?\d+" queries) nil)
-                   1
-                   (Integer/parseInt queries))]
-      (cond
-        (< n 1) 1
-        (> n 500) 500
-        :else n))))
-
-
-(defn multiple-query-test
-  "Test 3: Multiple database queries"
-  [request]
-  (-> request
-      (sanitizeQueriesParam)
-      (run-queries)
-      (bootstrap/json-response)))
-
-
-; Set up entity Fortune and the database representation
+;; Set up entity Fortune and the database representation
 (defentity fortune
   (pk :id)
   (table :fortune)
   (entity-fields :id :message)
-  (database mysql-db))
+  (database db-mysql))

-
-(defn get-all-fortunes
-  "Query all Fortune records from the database."
+(defn get-all-fortunes-korma
+  "Query all Fortune records from the database using Korma."
   []
   (select fortune
           (fields :id :message)))
@@ -107,9 +81,8 @@
   []
   (sort-by #(:message %)
     (conj
-      (get-all-fortunes)
+      (get-all-fortunes-korma)
       { :id 0 :message "Additional fortune added at request time." })))
-

 (defn fortunes-hiccup
   "Render the given fortunes to simple HTML using Hiccup."
@@ -128,6 +101,34 @@
         [:td (escape-html (:message x))]])
      ]]))

+(defn update-and-persist
+  "Using Korma: Changes the :randomNumber of a number of world entities.
+  Persists the changes to sql then returns the updated entities"
+  [queries]
+  (let [results (map #(assoc % :randomNumber (inc (rand-int 9999))) (run-queries queries))]
+    (doseq [{:keys [id randomNumber]} results]
+      (update world
+              (set-fields {:randomNumber randomNumber})
+              (where {:id id})))
+    results))
+
+(defn json-serialization
+  "Test 1: JSON serialization"
+  [request]
+  (bootstrap/json-response {:message "Hello, World!"}))
+
+(defn single-query-test
+  "Test 2: Single database query"
+  [request]
+  (bootstrap/json-response (first (run-queries 1))))
+
+(defn multiple-queries-test
+  "Test 3: Multiple database queries"
+  [request]
+  (-> request
+      (sanitize-queries-param)
+      (run-queries)
+      (bootstrap/json-response)))

 (defn fortune-test
   "Test 4: Fortunes"
@@ -137,28 +138,13 @@
     (fortunes-hiccup)
     (ring-resp/response)
     (ring-resp/content-type "text/html")
-    (ring-resp/charset "utf-8")))         ;; Apply charset after content type
-
-
-(defn update-and-persist
-  "Changes the :randomNumber of a number of world entities.
-  Persists the changes to sql then returns the updated entities"
-  [request]
-  (let [results (-> request
-                    (sanitizeQueriesParam)
-                    (run-queries))]
-    (for [w results]
-      (update-in w [:randomNumber (inc (rand-int 9999))]
-        (update world
-                (set-fields {:randomNumber (:randomNumber w)})
-                (where {:id [:id w]}))))
-    results))
-
+    (ring-resp/charset "utf-8")))

 (defn db-updates
   "Test 5: Database updates"
   [request]
   (-> request
+      (sanitize-queries-param)
       (update-and-persist)
       (bootstrap/json-response)))

@@ -168,15 +154,15 @@
   [request]
   (ring-resp/response "Hello, World!"))

-
+;; Define route handlers
 (defroutes routes
   [[
+  [  "/plaintext" {:get plaintext}]
   [  "/json"      {:get json-serialization}]
   [  "/db"        {:get single-query-test}]
-  [  "/queries"   {:get multiple-query-test}]
+  [  "/queries"   {:get multiple-queries-test}]
   [  "/fortunes"  {:get fortune-test}]
-  [  "/updates"   {:get db-updates}]
-  [  "/plaintext" {:get plaintext}]]])
+  [  "/updates"   {:get db-updates}]]])

 (def service


Consider roles with get-user. Restructure get-phrase.

--- src/cadence/model.clj
+++ src/cadence/model.clj
@@ -1,15 +1,14 @@
 (ns cadence.model
   (:refer-clojure :exclude [identity])
-  (:require [monger.core :as mg]
-            [monger.collection :as mc]
-            [monger.query :as mq]
+  (:require (monger [core :as mg]
+                    [collection :as mc]
+                    [query :as mq]
+                    [operators :refer :all])
             [noir.validation :as vali]
             [cadence.pattern-recognition :as patrec]
-            [noir.options :as options]
-            [cemerick.friend :as friend])
-  (:use clojure.walk
-        monger.operators
-        [cemerick.friend.credentials :only [hash-bcrypt]])
+            [clojure.walk :refer :all]
+            [cemerick.friend :as friend]
+            [cemerick.friend.credentials :refer [hash-bcrypt]])
   (:import [org.bson.types ObjectId]))

 ;; This namespace contains all functions related to manipulating the
@@ -20,15 +19,12 @@
   []
   ; Set up an index on random_point for cadence and phrases so we can
   ; *randomlyish* select a few of them.
-  (mc/ensure-index "cadences" {:phrase 1
-                               :user_id 1
-                               :random_point "2d"})
+  (mc/ensure-index "cadences" {:phrase 1 :user_id 1 :random_point "2d"})
   (mc/ensure-index "phrases" {:random_point "2d", :users 1})
   (mc/ensure-index "phrases" {:usersCount 1})
   (mc/ensure-index "phrases" {:phrase-id 1})
   (mc/ensure-index "phrases" {:phrase 1} {:unique 1 :dropDups 1})
-  (mc/ensure-index "classifiers" {:user_id 1
-                                  :phrase 1})
+  (mc/ensure-index "classifiers" {:user_id 1 :phrase 1})
   ; The `username` key should be unique.
   (mc/ensure-index "users" {:username 1} {:unique 1 :dropDups 1}))

@@ -46,26 +42,48 @@
   ; Set up the indexes necessary for decent performance.
   (ensure-indexes))

+(def ^:private security-namespace
+  "The namespace where the roles hierarchy is created"
+  "cadence.security/")
+
+(defn- namespace-and-keywordize-roles
+  "Turn the given vector of strings into a set of keywords."
+  [roles]
+  (set (map #(keyword (str security-namespace %)) roles)))
+
 (defn get-user
-  "Gets the user with the given username from mongo. Takes optional second
-  argument for selecting what fields to include in the result. (Used by `friend`
-  for user login)"
-  ([username fields] (let [get-f
-                           (partial
-                             mc/find-one-as-map "users" {:username username})]
-                       (if (nil? fields)
-                         (get-f)
-                         (get-f fields))))
-  ([username] (get-user username nil)))
+  "Gets the user with the given criteria or username from mongo. Takes optional
+  second argument for selecting what fields to include in the result (used by
+  `friend` for user login)."
+  ([criteria fields]
+   (when-let [user-map (mc/find-one-as-map "users"
+                                           (if (string? criteria)
+                                             {:username criteria}
+                                             criteria)
+                                           fields)]
+     (assoc user-map :roles (namespace-and-keywordize-roles
+                              (:roles user-map)))))
+  ([criteria] (get-user criteria [])))
+
+(defn add-roles-to-users
+  "Add the given roles to the user-id(s). If the first argument is a vector then
+  all user-ids in that vector will be updated with the given roles. If roles"
+  [criteria & roles]
+  (mc/update "users"
+             criteria
+             {$pushAll {:roles (let [roles-1 (first roles)]
+                                 (if (vector? roles-1) roles-1 roles))}}
+             :multi true))

 (defn add-user
   "Adds the given, validated user to mongo. Hashes the password with bcrypt."
   [user]
   (mc/insert "users"
-             (assoc (select-keys
+             (merge (select-keys
                       user
                       (for [[k v] user :when (vali/has-value? v)] k))
-                    :password (hash-bcrypt (:password user)))))
+                    {:password (hash-bcrypt (:password user))
+                     :roles [:user]})))

 (defn add-cadences
   "Batch inserts many cadences for the given user."
@@ -76,6 +94,7 @@
                                     :phrase_id phrase-id
                                     :random_point [(rand) 0]}))
                         cads)))
+
 (defn add-trained-user-to-phrase
   "Adds the given user-id to the array of users for the given phrase."
   [user-id phrase-id]
@@ -104,26 +123,20 @@
   "Get the current authenticaion map of the signed in user. This is effectively
   the document from mongodb.

-      EXAMPLE:
-
-          {:_id ObjectId(\"4fbe571a593e1633b6dfa6ad\"
-           :username \"Johnny\"
-           :name \"John Doe\"
-           :email \"johnny@example.com\"}"
+  EXAMPLE:
+
+  {:_id \"4fbe571a593e1633b6dfa6ad\"
+   :username \"Johnny\"
+   :name \"John Doe\"
+   :email \"johnny@example.com\"}"
   [] ((:authentications friend/*identity*) (:current friend/*identity*)))

-(defn get-phrase
-  "Find a phrase for the given user. If the seconf argument is true find one
-  they have already done training for. If it is false find one for which the
-  user is untrained."
-  [user-id for-auth?]
+(defn- get-phrase
+  "Randomly as possible get a phrase that matches the given query."
+  [query]
   (let [result (mc/find-one-as-map "phrases"
-                                   (if for-auth?
-                                     {:users user-id
-                                      :usersCount {$gt 5}
-                                      :random_point {"$near" [(rand) 0]}}
-                                     {:users {$ne user-id}
-                                      :random_point {"$near" [(rand) 0]}})
+                                   (assoc query
+                                          :random_point {"$near" [(rand) 0]})
                                    {:phrase 1})]
     ; Changes the random_point for increased randomlyishness.
     (when (not (nil? result))
@@ -132,6 +145,15 @@
                        {$set {:random_point [(rand) 0]}}))
     result))

+(defn get-phrase-for-auth [user-id]
+  "Get a random phrase for user authentication."
+  (get-phrase {:users user-id :usersCount {$gt 5}}))
+
+(defn get-phrase-for-training [user-id]
+  "Get a random phrase for user training."
+  (get-phrase {:users {$ne user-id}}))
+
+
 (defn get-training-data
   "Returns cadences to be used to train a classifier as a tuple of bad cadences
   and good cadences."
@@ -139,10 +161,10 @@
   (let [find-cadences (fn [by-user lim]
                         (mq/with-collection "cadences"
                           (mq/find {:phrase phrase
-                                 :user_id (if by-user
-                                            user-id
-                                            {$ne user-id})
-                                 :random_point {"$near" [(rand) 0]}})
+                                    :user_id (if by-user
+                                               user-id
+                                               {$ne user-id})
+                                    :random_point {"$near" [(rand) 0]}})
                           (mq/fields [:timeline :phrase])
                           (mq/limit lim)
                           (mq/snapshot)))]
@@ -159,8 +181,7 @@
                       $inc {:usersCount -1}})
     ;; Remove related cadences
     (mc/remove "cadences" {:phrase_id phrase-oid
-                           :user_id user-oid}))
-  )
+                           :user_id user-oid})))

 (defn store-classifier
   "Stores the given classifier with the given user/phrase pair."
@@ -178,7 +199,8 @@
                             :failures 0}))

 (defn get-classifier
-  "Gets the classifier needed for the specified user/phrase."
+  "Gets the classifier needed for the specified user/phrase. If the classifier
+  is not found in the database then generate one."
   [user-id phrase]
   (if-let [result (mc/find-one-as-map "classifiers"
                                       {:user_id user-id :phrase phrase})]


CLJS-1025: make REPL source mapping infrastructure generic

The canonicalized stacktrace is now more strict with regards to :file.
:file must a URL-style path without protocol relative to
:output-dir. This is a host agnostic representation from which we
can easily construct a host specific absolute file path.

Add IParseStacktrace protocol. All REPL environments should now
no longer attempt to parse stacktraces themselves at the time
they detect the exception. Instead they should implement
IParseStacktrace, they will receive the original stacktrace string
as well as all the compiler options. Access to compiler options
means :asset-path and/or :output-dir may be used to compute
 the canonical :file path.

--- src/clj/cljs/repl.clj
+++ src/clj/cljs/repl.clj
@@ -23,6 +23,7 @@
             [cljs.closure :as cljsc]
             [cljs.source-map :as sm])
   (:import [java.io File PushbackReader]
+           [java.net URL]
            [javax.xml.bind DatatypeConverter]))

 (def ^:dynamic *cljs-verbose* false)
@@ -91,18 +92,30 @@
 ;; CLJS Specifics

 (defprotocol IReplEnvOptions
-  (-repl-options [this] "Return default REPL options for a REPL Env"))
+  (-repl-options [repl-env] "Return default REPL options for a REPL Env"))

 (defprotocol IJavaScriptEnv
-  (-setup [this opts] "initialize the environment")
-  (-evaluate [this filename line js] "evaluate a javascript string")
-  (-load [this provides url] "load code at url into the environment")
-  (-tear-down [this] "dispose of the environment"))
+  (-setup [repl-env opts] "initialize the environment")
+  (-evaluate [repl-env filename line js] "evaluate a javascript string")
+  (-load [repl-env provides url] "load code at url into the environment")
+  (-tear-down [repl-env] "dispose of the environment"))

 (extend-type
   Object
   IReplEnvOptions
   (-repl-options [_] nil))
+
+(defprotocol IParseStacktrace
+  (-parse-stacktrace [repl-env stacktrace build-options]
+    "Given the original JavaScript stacktrace string and current compiler build
+     options, parse the stacktrace into the canonical form:
+
+     [{:file <string>
+       :function <string>
+       :line <integer>
+       :column <integer>}*]
+
+     :file must be a URL path (without protocol) relative to :output-dir."))

 (defn- env->opts
   "Returns a hash-map containing all of the entries in [repl-env], translating
@@ -197,14 +210,23 @@
 (defn print-mapped-stacktrace
   "Given a vector representing the canonicalized JavaScript stacktrace
    print the ClojureScript stacktrace. The canonical stacktrace must be
-   a vector of {:file <string> :function <string> :line <integer> :column <integer>}
-   maps."
+   in the form:
+
+    [{:file <string>
+      :function <string>
+      :line <integer>
+      :column <integer>}*]
+
+   :file must be a URL path (without protocol) relative to :output-dir."
   ([stacktrace] (print-mapped-stacktrace stacktrace nil))
   ([stacktrace opts]
     (let [read-source-map' (memoize read-source-map)
           ns-info' (memoize ns-info)]
       (doseq [{:keys [function file line column] :as frame} stacktrace]
-        (let [[sm {:keys [ns source-file] :as ns-info}] ((juxt read-source-map' ns-info') file)
+        ;; need to convert file, a relative URL style path, to host-specific file
+        (let [file (io/file (URL. (.toURL (io/file (util/output-directory opts))) file))
+              [sm {:keys [ns source-file] :as ns-info}]
+              ((juxt read-source-map' ns-info') file)
               [line' column'] (if ns-info
                                 (mapped-line-and-column sm line column)
                                 [line column])
@@ -234,10 +256,11 @@
   (:ns (ns-info "samples/hello/out/hello/core.js"))

   (print-mapped-stacktrace
-    [{:file "samples/hello/out/hello/core.js"
+    [{:file "hello/core.js"
       :function "first"
       :line 2
-      :column 1}])
+      :column 1}]
+    {:output-dir "samples/hello/out"})
   )

 (defn- display-error
@@ -248,8 +271,9 @@
     (println (:value ret))
     (when-let [st (:stacktrace ret)]
       (if (and (true? (:source-map opts))
-               (vector? st))
-        (print-mapped-stacktrace st opts)
+               (satisfies? IParseStacktrace repl-env))
+        (print-mapped-stacktrace
+          (-parse-stacktrace repl-env st opts) opts)
         (println st))
       (flush))))


update should actually update, not upsert

--- src/clj/tictag/db.clj
+++ src/clj/tictag/db.clj
@@ -119,19 +119,15 @@
   [{tagtime :tagtime}]
   (:pings tagtime))

-(defn to-db-ping [{:keys [user-id tags timestamp]}]
-  {:user_id user-id
-   :tags    (str/join " " tags)
-   :ts      (coerce/from-long timestamp)})
-
 (defn update-tags! [{db :db} pings]
   (timbre/debugf "Updating pings: %s" (pr-str pings))
-  (j/execute! db
-              (-> (insert-into :pings)
-                  (values (map to-db-ping pings))
-                  (upsert (-> (on-conflict :ts :user_id)
-                              (do-update-set :tags)))
-                  sql/format)))
+  (j/with-db-transaction [db db]
+    (doseq [{:keys [tags user-id timestamp]} pings]
+      (j/execute! db (-> (update :pings)
+                         (sset {:tags (str/join " " tags)})
+                         (where [:= :ts (coerce/from-long timestamp)]
+                                [:= :user_id user-id])
+                         sql/format)))))

 (defn sleepy-pings
   "Return the most recent contiguous set of pings marked :afk in the database"


no need for open connections

no need for open connections

--- src/clj_http/core.clj
+++ src/clj_http/core.clj
@@ -38,6 +38,7 @@
                       (str content-type "; charset=" character-encoding)))
         (if (and content-type (not character-encoding))
           (.addHeader http-req "Content-Type" content-type))
+        (.addHeader http-req "Connection" "close")
         (if body
           (let [http-body (ByteArrayEntity. body)]
             (.setEntity #^HttpEntityEnclosingRequest http-req http-body)))


I love the beatbox kick

I love the beatbox kick

--- src/codemash/core.clj
+++ src/codemash/core.clj
@@ -256,7 +256,7 @@
 (def kicks
   (doall
    (for [x (range 8)]
-     (mono-sequencer [:tail beats-g] :buf kick-s :beat-num x :vol 0.8
+     (mono-sequencer [:tail beats-g] :buf beatbox-kick-s :beat-num x :vol 0.8
                      :sequencer kick-sequencer-buffer))))

 (buffer-write! kick-sequencer-buffer [1 0 0 0 0 1 0 0])


created a lil demo of functionality in core

--- src/todos/core.clj
+++ src/todos/core.clj
@@ -1,8 +1,28 @@
 (ns todos.core
   (:gen-class)
+  (:require [todos.todo-item :as t-item])
   (:require [todos.storage :as storage]))

+(defn demo
+  "This is currently just a demo!"
+  []
+  (let
+    [todolist (t-item/todo-load-from-plain (storage/load-data
+                                             (((t-item/todo-create "main") :plain))
+                                             ))
+     sub-a    (t-item/todo-create "Privat")
+     sub-b    (t-item/todo-create "Arbeit")]
+    ((todolist :note-add) "Allgemeine Notizen")
+    ((todolist :todo-add) sub-a)
+    ((todolist :todo-add) sub-b)
+    ((sub-a :set-done) true)
+    ((sub-b :note-add) "arbeit arbeit")
+    ((todolist :print) "")
+    (println ((todolist :plain)))
+    ))
+
 (defn -main
-  "I don't do a whole lot ... yet."
+  "Start the demo ..."
   [& args]
-  (println (storage/load-data [])))
+  (demo))
+


Use dev build profile for port exposure.

--- src/topiq/core.clj
+++ src/topiq/core.clj
@@ -38,9 +38,7 @@
                     {:keys [protocol token user]}]
   (let [ext-tok (register-external-token token)
         body (str "Please visit: " proto "://"
-                  host (cond (and (= proto "http") (= port 80)) ""
-                             (and (= proto "https") (= port 443)) ""
-                             :else (str ":" port))
+                  host (when (= build :dev) (str ":" port))
                   "/auth/" ext-tok " to complete the authencation.")]
     (if-not (= protocol :mail)
       (warn "Cannot handle protocol" protocol " for " user)
@@ -81,9 +79,7 @@
         sender-token-store (<?? (new-mem-store))
         receiver-token-store (<?? (new-mem-store))
         uri (str (if (= proto "https") "wss" "ws") ;; should always be wss with auth
-                 "://" host (cond (and (= proto "http") (= port 80)) ""
-                                  (and (= proto "https") (= port 443)) ""
-                                  :else (str ":" port)) "/replikativ/ws")
+                 "://" host (when (= build :dev) (str ":" port)) "/replikativ/ws")
         peer (<?? (server-peer store err-ch uri
                                :middleware (comp (partial block-detector :server)
                                                  (partial fetch store (atom {}) err-ch)


do not nuke digits yet

do not nuke digits yet

--- src/crawler/utils.clj
+++ src/crawler/utils.clj
@@ -183,7 +183,7 @@
 (defn tokenize
   "Simplistic english tokenizer"
   [a-string]
-  (let [string-split (clojure.string/split a-string #"\s+|\d+|\p{P}")]
+  (let [string-split (clojure.string/split a-string #"\s+|\p{P}")]
     (filter
      #(not= % "")
      (map


this seems easier to understand

this seems easier to understand

--- src/useful/seq.clj
+++ src/useful/seq.clj
@@ -210,12 +210,12 @@
          [items])))))

 (defn prefix-of?
-  "Given needle is N elements long, are the first N elements of haystack equal to needle?"
-  [haystack needle]
-  (if-let [[n & ns] (seq needle)]
-    (when-let [[h & hs] (seq haystack)]
-      (and (= h (first needle))
-           (recur hs (rest needle))))
+  "Given prefix is N elements long, are the first N elements of coll equal to prefix?"
+  [coll prefix]
+  (if-let [[n & ns] (seq prefix)]
+    (when-let [[h & hs] (seq coll)]
+      (and (= h (first prefix))
+           (recur hs (rest coll))))
     true))

 (defn merge-sorted


-- avoid NPE in scheduler-state-query-chan (#59)

--- waiter/src/waiter/core.clj
+++ waiter/src/waiter/core.clj
@@ -826,7 +826,8 @@
                         (let [scheduler-state-query-chan (async/chan 32)]
                           (async/go-loop []
                             (let [{:keys [response-chan service-id]} (async/<! scheduler-state-query-chan)]
-                              (async/>! response-chan (scheduler/service-id->state scheduler service-id)))
+                              (when-let [scheduler-state (scheduler/service-id->state scheduler service-id)]
+                                (async/>! response-chan scheduler-state)))
                             (recur))
                           {:app-maintainer-state query-app-maintainer-chan
                            :autoscaler-state (:query autoscaler)


Workaround, start at the beginning after login, (See #12)

--- src/discuss/auth.cljs
+++ src/discuss/auth.cljs
@@ -13,7 +13,8 @@
     (lib/update-state-map! :user {:nickname   nickname
                                   :token      token
                                   :logged-in? true})
-    (lib/change-view! :discussion)))
+    (lib/change-view! :discussion)
+    (com/init!)))

 (defn ajax-login
   "Get cleaned data and send ajax request."


Tidy up

Tidy up

--- src/discuss/core.cljs
+++ src/discuss/core.cljs
@@ -18,8 +18,7 @@
 ;; Initialization
 (defn ^:export main []
   (lib/log (str "Loaded " config/project " " config/version))
-  (com/init-with-references!)
-  )
+  (com/init-with-references!))
 (main)

 ;; Register
@@ -29,7 +28,7 @@
   (when-let [div (gdom/getElement (lib/prefix-name div-name))]
     (om/root view state {:target div})))

-#_(doall (map register-view [["main" views/main-view lib/app-state]
+(doall (map register-view [["main" views/main-view lib/app-state]
                            ["sidebar" sidebar/view lib/app-state]
                            ["tooltip" tooltip/view lib/app-state]
                            ["contribute" contribute/view {}]


Fixed unit test failed

Fixed unit test failed

--- test/control/test/commands.clj
+++ test/control/test/commands.clj
@@ -10,47 +10,47 @@
   (is (= "export PATH=/home/sun/bin:$PATH; " (path "/home/sun/bin"))))

 (deftest test-env-run
-  (is (= "JAVA_OPTS=-XMaxPermSize=128m java -version; "
+  (is (= "JAVA_OPTS=-XMaxPermSize=128m java -version ; "
          (env "JAVA_OPTS" "-XMaxPermSize=128m"
               (run "java -version")))))

 (deftest test-cd-run
-  (is (= "cd /home/sun; ls; "
+  (is (= "cd /home/sun; ls ; "
          (cd "/home/sun"
              (run "ls")))))

 (deftest test-cd-prefix-run
-  (is (= "cd /home/sun; source ~/.bash_profile && ls; "
+  (is (= "cd /home/sun; source ~/.bash_profile && ls ; "
          (cd "/home/sun"
              (prefix "source ~/.bash_profile"
                      (run "ls"))))))

 (deftest test-sudo
-  (is (= "sudo service tomcat start; "
+  (is (= "sudo service tomcat start ; "
          (sudo "service tomcat start"))))

 (deftest test-append
-  (is (= "echo 'hello world' >> test.txt"
+  (is (= "echo 'hello world' >> test.txt ; "
          (append "test.txt" "hello world")))
-  (is (= "echo 'hello world' | sudo tee -a test.txt"
+  (is (= "echo 'hello world' | sudo tee -a test.txt ; "
          (append "test.txt" "hello world" :sudo true))))

 (deftest test-sed
-  (is (= "sed -i.back -r -e \"3 s/hello/world/g\" test"
+  (is (= "sed -i.back -r -e \"3 s/hello/world/g\" test ; "
          (sed "test" "hello" "world" :limit 3 :backup ".back")))
-  (is (= "sudo sed -i.bak -r -e \" s/hello/world/g\" test; "
+  (is (= "sudo sed -i.bak -r -e \" s/hello/world/g\" test ; "
          (sed "test" "hello" "world" :sudo true))))

 (deftest test-comm
-  (is   (= "sed -i.bak -r -e \" s/hello\\sworld/#&/g\" test"
+  (is   (= "sed -i.bak -r -e \" s/hello\\sworld/#&/g\" test ; "
            (comm "test" "hello\\sworld")))
-  (is    (= "sed -i.bak -r -e \" s/hello\\sworld/;&/g\" test"
+  (is    (= "sed -i.bak -r -e \" s/hello\\sworld/;&/g\" test ; "
             (comm "test" "hello\\sworld" :char ";"))))

 (deftest test-uncomm
-  (is   (= "sed -i.bak -r -e \" s/#(hello\\sworld)/\\1/g\" test"
+  (is   (= "sed -i.bak -r -e \" s/#(hello\\sworld)/\\1/g\" test ; "
            (uncomm "test" "hello\\sworld")))
-  (is    (= "sed -i.bak -r -e \" s/;(hello\\sworld)/\\1/g\" test"
+  (is    (= "sed -i.bak -r -e \" s/;(hello\\sworld)/\\1/g\" test ; "
             (uncomm "test" "hello\\sworld" :char ";"))))


Add multiple varities to handle html fragments

--- src/datemo/arb.clj
+++ src/datemo/arb.clj
@@ -2,8 +2,12 @@
   (:require [clojure.pprint :refer [pprint]])
   (:use hickory.core))

-(defn html->hiccup [html]
-  (as-hiccup (parse html)))
+(defn html->hiccup
+  ([html] (as-hiccup (parse html)))
+  ([html as-fragment]
+   (if (false? as-fragment)
+     (html->hiccup html)
+     (map as-hiccup (parse-fragment html)))))

 (defn hiccup->arb [hiccup]
   (if (string? (first hiccup))
@@ -19,5 +23,12 @@
             (recur (conj arb (hiccup->arb (list (first forms))))
                    (next forms))))))))

-(defn html->arb [html]
-  (hiccup->arb (html->hiccup html)))
+(defn html->arb
+  ([html] (html->arb html false))
+  ([html as-fragment]
+   (if (false? as-fragment)
+    (hiccup->arb (html->hiccup html)))
+    (hiccup->arb (html->hiccup html as-fragment))))
+
+(defn arb->tx [arb]
+  arb)


Fix segment container edge tracking during cross counting

--- src/fatlip/order.cljs
+++ src/fatlip/order.cljs
@@ -174,14 +174,27 @@
         ;; Edges between segment containers need to be counted as well but they
         ;; change with each new ordering, so we just temporarily merge the
         ;; current segment edges with the never-changing node -> node edges
+        next-segs-to-seg-cs (->> (filter vector? next-ordered)
+                                 (mapcat (fn [seg-c]
+                                           (map (fn [seg]
+                                                  [seg seg-c])
+                                                seg-c)))
+                                 (into {}))
+        seg->Edge (fn [seg-c]
+                    (fn [seg]
+                      (let [dest (get next-segs-to-seg-cs seg)
+                            seg-chars (set (mapcat :characters seg))
+                            dest-chars (set (mapcat :characters dest))
+                            edge-characters (set/intersection
+                                             seg-chars
+                                             dest-chars)]
+                        (Edge. seg-c dest
+                               edge-characters
+                               (count edge-characters)))))
         edges (->> (filter vector? ordered)
-                   (map (juxt identity
-                              (partial mapcat :characters)
-                              (partial map :weight)))
-                   (map (fn [[seg-c characters weights]]
-                          [seg-c #{(Edge. seg-c seg-c
-                                          (set characters)
-                                          (reduce + weights))}]))
+                   (map
+                    (fn [seg-c]
+                      [seg-c (set (map (seg->Edge seg-c) seg-c))]))
                    (into {})
                    (merge graph-edges))]
     (->> ordered


formatting

formatting

--- src/fowles/scrape.clj
+++ src/fowles/scrape.clj
@@ -22,10 +22,11 @@

 ;;---------------------------

-(def HEADERS {"User-Agent"      "Firefox/3.0.15"
-              "accept"          "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8"
-              "accept-language" "en-US,en;q=0.8"
-              "cache-control"   "max-age=0"})
+(def HEADERS
+  {"User-Agent"      "Firefox/3.0.15"
+   "accept"          "text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8"
+   "accept-language" "en-US,en;q=0.8"
+   "cache-control"   "max-age=0"})

 (defn get-html
   [uri]


Upgrading transit-clj

Upgrading transit-clj

--- project.clj
+++ project.clj
@@ -23,7 +23,7 @@
                  [inliner "0.1.0"]
                  [de.ubercode.clostache/clostache "1.4.0"]
                  [mount "0.1.10"]
-                 [com.cognitect/transit-clj "0.8.288" :exclusions [com.fasterxml.jackson.core/jackson-core]]
+                 [com.cognitect/transit-clj "0.8.300" :exclusions [com.fasterxml.jackson.core/jackson-core]]
                  [ring-transit "0.1.6" :exclusions [com.fasterxml.jackson.core/jackson-core]]
                  [clavatar "0.3.0"]


Bump to SNAPSHOT version.

Bump to SNAPSHOT version.

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject exegesis "0.2.0"
+(defproject exegesis "0.2.0-SNAPSHOT"
   :description "Simplify reflection of annotations on Java types."
   :url "http://github.com/tobyclemson/exegesis"
   :license {:name "The MIT License"


Update versions of plugins

Update versions of plugins

--- project.clj
+++ project.clj
@@ -47,15 +47,15 @@
                  [trptcolin/versioneer "0.2.0"]]

   :min-lein-version "2.0.0"
-
+
   :source-paths ["src/clj"]
   :test-paths ["test/clj"]
   :resource-paths ["resources"]
   :target-path "target/%s/"
   :main ^:skip-aot catalog.core

-  :plugins [[lein-kibit "0.1.2"]
-            [lein-codox "0.10.7"]]
+  :plugins [[lein-kibit "0.1.8"]
+            [lein-codox "0.10.8"]]

   :codox {:project {:name "Kati"}
           :source-paths ["src"]
@@ -87,9 +87,9 @@
                                  [prone "2021-04-23"]
                                  [ring/ring-devel "1.9.4"]
                                  [ring/ring-mock "0.4.0"]]
-                  :plugins      [[com.jakemccrary/lein-test-refresh "0.24.1"]
-                                 [jonase/eastwood "0.3.5"]]
-
+                  :plugins      [[com.jakemccrary/lein-test-refresh "0.25.0"]
+                                 [jonase/eastwood "0.9.9"]]
+
                   :source-paths ["env/dev/clj" ]
                   :resource-paths ["env/dev/resources"]
                   :repl-options {:init-ns user


Version bump.

Version bump.

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject pucks "0.1.22"
+(defproject pucks "0.1.23"
   :description "An environment for experiments and education in artificial intelligence and artificial life."
   :url "http://example.com/FIXME"
   :license {:name "Eclipse Public License"


start work on 1.8.3

start work on 1.8.3

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject babel "1.8.2"
+(defproject babel "1.8.3-SNAPSHOT"
   :description "A library for generation and parsing of expressions from grammars and lexicons."
   :url "http://github.com/ekoontz/babel"
   :license {:name "Proprietary: all rights reserved. No distribution allowed without consent of owners."}


Upgrade to 0.9.0-alpha6.

Upgrade to 0.9.0-alpha6.

--- project.clj
+++ project.clj
@@ -1,10 +1,10 @@
-(defproject workshop "0.9.0-alpha5"
+(defproject workshop "0.9.0-alpha6"
   :license {:name "Eclipse Public License"
             :url "http://www.eclipse.org/legal/epl-v10.html"}
   :dependencies [[org.clojure/clojure "1.7.0"]
                  [org.clojure/core.async "0.2.374"]
                  ^{:voom {:repo "git@github.com:onyx-platform/onyx.git" :branch "master"}}
-                 [org.onyxplatform/onyx "0.9.0-alpha5"]
+                 [org.onyxplatform/onyx "0.9.0-alpha6"]
                  [org.slf4j/slf4j-api "1.7.12"]
                  [org.slf4j/slf4j-nop "1.7.12"]]
   :profiles {:dev {:dependencies [[org.clojure/tools.namespace "0.2.10"]


Configure JVM for optimized server

Configure JVM for optimized server

--- project.clj
+++ project.clj
@@ -34,6 +34,8 @@

   :repl-options {:init-ns user
                  :welcome (println "Type (dev) to start")}
+
+  :jvm-opts ["-Xms4g" "-Xmx4g" "-server" "-Dio.netty.leakDetectionLevel=advanced"]

   :profiles
   {:dev {:main yada.dev.main


Update environ to 1.0.1

Update environ to 1.0.1

--- project.clj
+++ project.clj
@@ -29,6 +29,6 @@
                  [funcool/promissum "0.3.1"]
                  [funcool/cats "1.0.0"]
                  [danlentz/clj-uuid "0.1.6"]
-                 [environ "1.0.0"]
+                 [environ "1.0.1"]
                  [potemkin "0.4.1"]
                  [com.cognitect/transit-clj "0.8.281"]])


Version 3.0.1-SNAPSHOT

Version 3.0.1-SNAPSHOT

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject com.saga-it/mirthsync "3.0.0"
+(defproject com.saga-it/mirthsync "3.0.1-SNAPSHOT"
   :description "Mirthsync is a command line tool, created by Saga IT,
   for keeping a local copy of important aspects of Mirth Connect
   configuration in order to allow for the use of traditional version


v21.03.25

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject tupelo "21.01.26b"
+(defproject tupelo "21.03.25"
   :description "Tupelo:  Clojure With A Spoonful of Honey"
   :url "https://github.com/cloojure/tupelo"
   :scm "https://github.com/cloojure/tupelo"


Update Logback

Update Logback

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

   :dependencies [[amazonica "0.2.3"]
                  [bouncer "0.3.0"]
-                 [ch.qos.logback/logback-classic "1.0.13"]
+                 [ch.qos.logback/logback-classic "1.1.0"]
                  [cheshire "5.3.1"]
                  [clj-http "0.7.8"]
                  [clj-time "0.6.0"]


Removed unused dep.

Removed unused dep.

--- project.clj
+++ project.clj
@@ -27,7 +27,6 @@
     [clojusc/trifl "0.2.0"]
     [clojusc/twig "0.3.2"]
     [com.stuartsierra/component "0.3.2"]
-    [gov.nasa.earthdata/cmr-client "0.3.0-SNAPSHOT"]
     [http-kit "2.2.0"]
     [metosin/reitit-core "0.1.1-SNAPSHOT"]
     [metosin/reitit-ring "0.1.1-SNAPSHOT"]


Update dependencies

Update dependencies

--- project.clj
+++ project.clj
@@ -5,19 +5,19 @@
             :url  "https://opensource.org/licenses/MIT"}

   :dependencies [[org.clojure/clojure "1.8.0"]
-                 [org.clojure/clojurescript "1.9.198" :scope "provided"]
+                 [org.clojure/clojurescript "1.9.227" :scope "provided"]
                  [org.clojure/data.generators "0.1.2"]
                  [ring "1.5.0"]
                  [ring/ring-defaults "0.2.1"]
                  [bk/ring-gzip "0.1.1"]
                  [ring.middleware.logger "0.5.0"]
                  [compojure "1.5.1"]
-                 [metosin/compojure-api "1.1.6"]
+                 [metosin/compojure-api "1.1.8"]
                  [prismatic/schema "1.1.3"]
                  [environ "1.1.0"]
                  [garden "1.3.2"]
                  [reagent "0.6.0-rc"]
-                 [re-frame "0.8.0-alpha9"]
+                 [re-frame "0.8.0"]
                  [hiccup "1.0.5"]
                  [cheshire "5.6.3"]
                  [ns-tracker "0.3.0"]]
@@ -116,8 +116,8 @@
   :doo {:build "test"}

   :profiles {:dev
-             {:dependencies [[figwheel "0.5.4-7"]
-                             [figwheel-sidecar "0.5.4-7"]
+             {:dependencies [[figwheel "0.5.6"]
+                             [figwheel-sidecar "0.5.6"]
                              [com.cemerick/piggieback "0.2.1"]
                              [org.clojure/tools.nrepl "0.2.12"]
                              [ring/ring-mock "0.3.0"]


Bump lib version.

Bump lib version.

--- project.clj
+++ project.clj
@@ -41,7 +41,7 @@
     [zprint "0.5.4"]

     ;; Library for OC projects https://github.com/open-company/open-company-lib
-    [open-company/lib "0.17.29-alpha15a"]
+    [open-company/lib "0.17.29-alpha18"]
     ;; In addition to common functions, brings in the following common dependencies used by this project:
     ;; httpkit - HTTP client/server http://www.http-kit.org/
     ;; defun - Erlang-esque pattern matching for Clojure functions https://github.com/killme2008/defun


Version 0.29.1

Version 0.29.1

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject nhl-score-api "0.29.0"
+(defproject nhl-score-api "0.29.1"
   :description "A JSON API that returns the scores and goals from the latest finished NHL games."
   :license {:name "MIT"
             :url "https://opensource.org/licenses/MIT"}


Updates old core.logic version.

Updates old core.logic version.

--- project.clj
+++ project.clj
@@ -10,7 +10,7 @@
                  [lonocloud/synthread "1.0.5"]
                  [org.clojure/data.codec "0.1.0"]
                  [org.clojure/data.fressian "0.2.0"]
-                 [org.clojure/core.logic "0.8.5"]
+                 [org.clojure/core.logic "0.8.10"]
                  [org.clojure/test.check "0.6.1"]]
   :plugins [[lein-marginalia "0.8.0"]]
   :signing {:gpg-key "A4D5C342"}


Release 0.3.26

Release 0.3.26

--- project.clj
+++ project.clj
@@ -3,7 +3,7 @@
   [path]
   (str "resources/public/js/lib/" path))

-(defproject onaio/hatti "0.3.26-SNAPSHOT"
+(defproject onaio/hatti "0.3.26"
   :description "A cljs dataview from your friends at Ona.io"
   :license "Apache 2, see LICENSE"
   :url "https://github.com/onaio/hatti"


Fix css-guide build error

Fix css-guide build error

--- project.clj
+++ project.clj
@@ -20,7 +20,7 @@
             [lein-cljsbuild "1.1.5"]
             [lein-doo "0.1.7"]]

-  :source-paths ["dev" "src/main" "src/guide" "src/visuals"]
+  :source-paths ["dev" "src/main" "src/guide" "src/visuals" "src/css-guide"]
   :test-paths ["src/test"]
   :jar-exclusions [#".DS_Store" #"public" #"cards" #"user.clj"]


Version 1.0.3

Version 1.0.3

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


Upgrade clj-time

Upgrade clj-time

--- project.clj
+++ project.clj
@@ -29,7 +29,7 @@
                  [vimclojure/server "2.3.6" :exclusions [org.clojure/clojure]]
                  [clj-stacktrace "0.2.6"]
                  [metrics-clojure "0.7.0" :exclusions [org.clojure/clojure org.slf4j/slf4j-api]]
-                 [clj-time "0.3.7"]
+                 [clj-time "0.5.1"]
                  [org.clojure/java.jmx "0.1"]
                  ;; Filesystem utilities
                  [fs "1.1.2"]


fix pom license

fix pom license

--- project.clj
+++ project.clj
@@ -2,7 +2,7 @@
   :description "Save your fork, there's cake!"
   :dependencies [[clojure "1.2.0"]
                  [uncle "0.2.3"]
-                 [depot "0.1.7"]
+                 [depot "0.1.8"]
                  [classlojure "0.6.3"]
                  [useful "0.7.4-alpha4"]
                  [slingshot "0.7.2"]


Release 0.5.5

Release 0.5.5

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject org.pinkgorilla/notebook "0.5.5-SNAPSHOT"
+(defproject org.pinkgorilla/notebook "0.5.5"
   :description "A clojure notebook web-app"
   :url "https://github.com/pink-gorilla/notebook"
   :license {:name "MIT"}


Version 0.0.11

Version 0.0.11

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject pe-jdbc-utils "0.0.11-SNAPSHOT"
+(defproject pe-jdbc-utils "0.0.11"
   :description "A Clojure library of helper functions when working with JDBC."
   :url "https://github.com/evanspa/pe-jdbc-utils"
   :license {:name "MIT"


Version 0.1.1

Version 0.1.1

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject featured-gml "0.1.1-SNAPSHOT"
+(defproject featured-gml "0.1.1"
   :description "gml to featured json conversion lib"
   :url "http://github.so.kadaster.nl/PDOK/featured-gml"
   :license {:name "Eclipse Public License"


Adding cider as a plugin

Adding cider as a plugin

- this removes all warnings about unavailable middleware


update project.clj

update project.clj

Signed-off-by: Yen-Chin Lee <082d453d72dce940e12089a4ad48b97cfe1f3ec4@gmail.com>

--- project.clj
+++ project.clj
@@ -1,10 +1,9 @@
 (defproject coldnew/pangu "0.1.0-SNAPSHOT"
   :description "Paranoid text spacing in Clojure/ClojureScript."
+  :author "Yen-Chin, Lee"
   :url "https://github.com/coldnew/pangu.clj"
   :license {:name "MIT License"
-            :url "https://github.com/coldnew/pangu.clj/blob/master/LICENSE"
-            :distribution :repo
-            :comments "Copyright 2016 Yen-Chin, Lee <coldnew> All Rights Reserved."}
+            :url "https://github.com/coldnew/pangu.clj/blob/master/LICENSE"}

   :jar-exclusions [#"\.cljx|\.swp|\.swo|\.DS_Store"]

@@ -28,4 +27,6 @@
                                               :optimizations :advanced}}}
               :test-commands {"test" ["phantomjs"  "bin/speclj" "target/pangu.js"]}}

+  :deploy-repositories [["releases" :clojars]]
+
   :codox {:source-uri "https://github.com/coldnew/pangu.clj/blob/master/{filepath}#L{line}"})


Updated Ring version to 1.0.0

Updated Ring version to 1.0.0

--- project.clj
+++ project.clj
@@ -5,6 +5,6 @@
                  [org.clojure/core.incubator "0.1.0"]
                  [org.clojure/tools.macro "0.1.0"]
                  [clout "1.0.0-RC1"]
-                 [ring/ring-core "1.0.0-RC4"]]
+                 [ring/ring-core "1.0.0"]]
   :dev-dependencies [[ring-mock "0.1.1"]
                      [org.clojure/clojure-contrib "1.2.0"]])


version 0.1.4

version 0.1.4

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject reagent-liveedit/lein-template "0.1.4-SNAPSHOT"
+(defproject reagent-liveedit/lein-template "0.1.4"
   :description "A leiningen template based on reagent-template for live editing a clojurescript web app"
   :url "https://github.com/ejlo/reagent-liveedit/"
   :license {:name "MIT License"


Release version 0.8.1.0-alpha9.

Release version 0.8.1.0-alpha9.

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject org.onyxplatform/onyx-datomic "0.8.1.0-SNAPSHOT"
+(defproject org.onyxplatform/onyx-datomic "0.8.1.0-alpha9"
   :description "Onyx plugin for Datomic"
   :url "https://github.com/MichaelDrogalis/onyx-datomic"
   :license {:name "Eclipse Public License"
@@ -13,7 +13,7 @@
                              :sign-releases false}}
   :dependencies [[org.clojure/clojure "1.7.0"]
                  ^{:voom {:repo "git@github.com:onyx-platform/onyx.git" :branch "master"}}
-                 [org.onyxplatform/onyx "0.8.1-alpha8"]]
+                 [org.onyxplatform/onyx "0.8.1-alpha9"]]
   :profiles {:dev {:dependencies [[midje "1.7.0"]
                                   [com.datomic/datomic-free "0.9.5153"]]
                    :plugins [[lein-midje "3.1.3"]


Add prod profile

Add prod profile

This way we can run `lein with-profile prod run`

--- project.clj
+++ project.clj
@@ -53,6 +53,8 @@
              :uberjar-name "squad-share.jar"
              :source-paths ["env/prod/clj"]
              :resource-paths ["env/prod/resources"]}
+   :prod           [:project/prod]
+   :project/prod {:resource-paths ["env/prod/resources" "env/prod/resources"]}
    :dev           [:project/dev :profiles/dev]
    :test          [:project/test :profiles/test]
    :project/dev  {:dependencies [[prone "1.1.1"]


CMR-5145: Updated service-bridge to use the new OUS plugin.

--- project.clj
+++ project.clj
@@ -123,7 +123,8 @@
         [clojusc/ltest "0.3.0"]]
       :plugins [
         [lein-ltest "0.3.0"]
-        [test2junit "1.4.2"]]
+        [test2junit "1.4.2"]
+        [venantius/ultra "0.5.2"]]
       :jvm-opts [
         "-Dcmr.testing.config.data=testing-value"]
       :test2junit-output-dir "junit-test-results"


Version 4.1.5-SNAPSHOT

Version 4.1.5-SNAPSHOT

--- project.clj
+++ project.clj
@@ -1,6 +1,6 @@
 (def jetty-version "9.4.36.v20210114")

-(defproject puppetlabs/trapperkeeper-webserver-jetty9 "4.1.4"
+(defproject puppetlabs/trapperkeeper-webserver-jetty9 "4.1.5-SNAPSHOT"
   :description "A jetty9-based webserver implementation for use with the puppetlabs/trapperkeeper service framework."
   :url "https://github.com/puppetlabs/trapperkeeper-webserver-jetty9"
   :license {:name "Apache License, Version 2.0"


Update midje

Update midje

--- project.clj
+++ project.clj
@@ -38,7 +38,7 @@
   :exclusions [commons-logging
                log4j]

-  :profiles {:dev {:dependencies [[midje "1.6.0"]]
+  :profiles {:dev {:dependencies [[midje "1.6.2"]]
                    :plugins [[lein-rpm "0.0.5"]
                              [lein-midje "3.1.3"]
                              [jonase/kibit "0.0.8"]]}}


Set correct version number in project.clj.

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject sandbar "0.2.0-SNAPSHOT"
+(defproject sandbar "0.1.0-SNAPSHOT"
   :description "Clojure web application library."
   :dependencies [[org.clojure/clojure "1.2.0-master-SNAPSHOT"]
                  [org.clojure/clojure-contrib "1.2.0-master-SNAPSHOT"]


(MAINT) Bumped version of TK-Jetty9 dependency

--- project.clj
+++ project.clj
@@ -1,5 +1,5 @@
 (def tk-version "1.0.1")
-(def tk-jetty-version "0.9.0")
+(def tk-jetty-version "1.1.0")
 (def ks-version "1.0.0")

 (defn deploy-info


Upgraded clojurescript and plugins

Upgraded clojurescript and plugins

--- project.clj
+++ project.clj
@@ -16,20 +16,19 @@
                  [clj-time "0.12.2"]
                  [camel-snake-kebab "0.4.0"]
                  [environ "1.1.0"]
-                 [org.clojure/clojurescript "1.7.228"]
+                 [org.clojure/clojurescript "1.9.293"]
                  [reagent "0.6.0"]
                  [selmer "1.10.3"]
                  [org.clojure/data.json "0.2.6"]
                  [cljs-ajax "0.5.8"]
                  [ring-logger "0.7.6"]
                  #_[ch.qos.logback/logback-classic "1.1.1"]]
-  :plugins [[lein-ring "0.9.7"]
+  :plugins [[lein-ring "0.10.0"]
             [lein-ancient "0.6.10"]
-            [lein-environ "1.0.2"]
-            [lein-figwheel "0.5.0-6"]
-            [lein-bower "0.5.1"]
-            [lein-cljsbuild "1.1.3"]
-            [lein-pprint "1.1.1"]]
+            [lein-environ "1.1.0"]
+            [lein-figwheel "0.5.8"]
+            [lein-cljsbuild "1.1.5"]
+            [lein-pprint "1.1.2"]]
   :ring {:handler skuld.core/ring-handler}
   :main ^:skip-aot skuld.core
   :source-paths ["src/clojure"]


Version 0.2.17-SNAPSHOT

Version 0.2.17-SNAPSHOT

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


adding description

adding description

--- project.clj
+++ project.clj
@@ -1,6 +1,6 @@
 (defproject closp/lein-template "0.1.1"
-  :description "FIXME: write description"
-  :url "http://example.com/FIXME"
+  :description "A webframework combining several technologies based on luminus and chestnut."
+  :url "https://github.com/sveri/closp"
   :license {:name "Eclipse Public License"
             :url "http://www.eclipse.org/legal/epl-v10.html"}
   :dependencies [


Version 1.1.0-SNAPSHOT

Version 1.1.0-SNAPSHOT

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject puppetlabs/ring-middleware "1.0.3"
+(defproject puppetlabs/ring-middleware "1.1.0-SNAPSHOT"
   :dependencies [[org.clojure/clojure]
                  [org.clojure/tools.logging]
                  [cheshire]


Update to latest wunderboss that fixes IMMUTANT-563, IMMUTANT-564

See https://github.com/projectodd/wunderboss/commit/64aed06806f0bedf171b39e9f1c0d0986eb40265

--- project.clj
+++ project.clj
@@ -90,8 +90,8 @@
                         potemkin                   "0.3.12"
                         clj-http                   "1.0.1"

-                        org.projectodd.wunderboss  "0.8.0"
-                        ;; org.projectodd.wunderboss  "1.x.incremental.242"
+                        ;; org.projectodd.wunderboss  "0.8.0"
+                        org.projectodd.wunderboss  "1.x.incremental.244"
                         ;; org.projectodd.wunderboss  "0.8.1-SNAPSHOT"

                         org.immutant               :version


Updated deps.

Updated deps.

--- project.clj
+++ project.clj
@@ -25,7 +25,7 @@
     [cheshire "5.8.0"]
     [clojusc/trifl "0.2.0"]
     [clojusc/twig "0.3.2"]
-    [com.esri.geometry/esri-geometry-api "2.1.0"]
+    [com.esri.geometry/esri-geometry-api "2.2.0"]
     [com.stuartsierra/component "0.3.2"]
     [com.vividsolutions/jts "1.13"]
     [environ "1.1.0"]
@@ -35,19 +35,23 @@
     [gov.nasa.earthdata/cmr-site-templates "0.1.0-SNAPSHOT"]
     [http-kit "2.3.0"]
     [markdown-clj "1.0.2"]
-    [metosin/reitit-core "0.1.1-SNAPSHOT"]
-    [metosin/reitit-ring "0.1.1-SNAPSHOT"]
+    [metosin/reitit-core "0.1.3"]
+    [metosin/reitit-ring "0.1.3"]
     [metosin/ring-http-response "0.9.0"]
     [net.sf.geographiclib/GeographicLib-Java "1.49"]
     [org.clojure/clojure "1.9.0"]
     [org.clojure/core.async "0.4.474"]
     [org.clojure/core.cache "0.7.1"]
     [org.clojure/data.xml "0.2.0-alpha5"]
+    [org.geotools/gt-geometry "19.1"]
+    [org.geotools/gt-referencing "19.1"]
     [ring/ring-core "1.6.3"]
-    [ring/ring-codec "1.1.0"]
-    [ring/ring-defaults "0.3.1"]
-    [selmer "1.11.7"]
+    [ring/ring-codec "1.1.1"]
+    [ring/ring-defaults "0.3.2"]
+    [selmer "1.11.8"]
     [tolitius/xml-in "0.1.0"]]
+  :repositories [
+    ["osgeo" "https://download.osgeo.org/webdav/geotools"]]
   :jvm-opts ["-XX:-OmitStackTraceInFastThrow"
              "-Xms2g"
              "-Xmx2g"]
@@ -83,7 +87,7 @@
       :source-paths ^:replace ["src"]
       :test-paths ^:replace []
       :plugins [
-        [jonase/eastwood "0.2.5"]
+        [jonase/eastwood "0.2.8"]
         [lein-ancient "0.6.15"]
         [lein-bikeshed "0.5.1"]
         [lein-kibit "0.1.6"]
@@ -93,7 +97,7 @@
         [clojusc/ltest "0.3.0"]]
       :plugins [
         [lein-ltest "0.3.0"]
-        [test2junit "1.4.0"]]
+        [test2junit "1.4.2"]]
       :test2junit-output-dir "junit-test-results"
       :test-selectors {
         :unit #(not (or (:integration %) (:system %)))
@@ -104,7 +108,7 @@
       :dependencies [
         [gov.nasa.earthdata/codox-theme "1.0.0-SNAPSHOT"]]
       :plugins [
-        [lein-codox "0.10.3"]
+        [lein-codox "0.10.4"]
         [lein-marginalia "0.9.1"]]
       :source-paths ["resources/docs/src"]
       :codox {


Bumping dependencies before re-frame handler changes

Decided to go with the react version included on re-frame instead of
the one for react-bootsrap, as re-frame is a lot more likely to depend
on specific functionality.

--- project.clj
+++ project.clj
@@ -2,20 +2,20 @@
   :license {:name "MIT License"
             :url  "https://tldrlegal.com/license/mit-license"}
   :dependencies [[org.clojure/clojure "1.8.0"]
-                 [org.clojure/clojurescript "1.9.671"]
+                 [org.clojure/clojurescript "1.9.946"]
                  [org.clojure/core.async "0.3.443"]
                  [com.cognitect/transit-cljs "0.8.239"]
-                 [cljsjs/react-bootstrap "0.31.0-0"]
+                 [cljsjs/react-bootstrap "0.31.0-0" :exclusions [cljsjs/react]]
                  [khroma "0.3.0"]
                  [prismatic/dommy "1.1.0"]
-                 [re-frame "0.9.4" :exclusions [cljsjs/react]]]
+                 [re-frame "0.10.1"]]

   :source-paths ["src/ui" "src/common" "src/background" "src/content"]
   :test-paths ["test"]

-  :plugins [[lein-cljsbuild "1.1.6"]
+  :plugins [[lein-cljsbuild "1.1.7"]
             [org.clojars.ricardojmendez/lein-chromebuild "0.3.2"]
-            [lein-doo "0.1.7"]]
+            [lein-doo "0.1.8"]]

   :doo {:build "test"
@@ -67,7 +67,7 @@
                 :ui         {:compiler {:optimizations :advanced
                                         :pretty-print  false}}}}}
              :test
-             {:dependencies [[lein-doo "0.1.7"]]
+             {:dependencies [[lein-doo "0.1.8"]]
               :cljsbuild
                             {:builds
                              {:test


Add Deps

Add Deps

--- project.clj
+++ project.clj
@@ -3,4 +3,10 @@
   :url "http://example.com/FIXME"
   :license {:name "Eclipse Public License"
             :url "http://www.eclipse.org/legal/epl-v10.html"}
-  :dependencies [[org.clojure/clojure "1.6.0"]])
+  :dependencies [[org.clojure/clojure "1.6.0"]
+                 [liberator "0.12.0"]
+                 [compojure "1.1.3"]
+                 [http-kit "2.1.18"]
+                 [clj-mesos "0.1.0-SNAPSHOT"]
+                 [org.apache.curator/curator-test "2.4.0"]
+                 [org.apache.curator/curator-x-discovery "2.4.0"]])


try work around for heroku

try work around for heroku

--- project.clj
+++ project.clj
@@ -46,14 +46,12 @@

   :plugins [[lein-environ "1.0.0"]
             [migratus-lein "0.1.7"]
-            [lein-cljsbuild "1.0.6"]
-            [lein-sassc "0.10.4"]]
+            [lein-cljsbuild "1.0.6"]]
   :sassc [{:src "resources/scss/screen.scss"
            :output-to "resources/public/css/screen.css"
            :style "nested"
            :import-path "resources/scss"}]

-  :hooks [leiningen.sassc]
   :clean-targets ^{:protect false} [:target-path [:cljsbuild :builds :app :compiler :output-dir] [:cljsbuild :builds :app :compiler :output-to]]
   :cljsbuild
   {:builds


Story ID: develop fixed namespace of project

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject untangled-spec "0.3.4-SNAPSHOT"
+(defproject navis/untangled-spec "0.3.4-SNAPSHOT"
   :description "A Behavioral specification system for clj and cljs stacked on clojure.test"
   :url ""
   :license {:name "MIT Public License"


can't find speclj - core and core dependencies are cljx

--- project.clj
+++ project.clj
@@ -49,7 +49,7 @@
 ;                                                             :pretty-print true}
 ;                                                  ;:notify-command test-command
 ;                                                  }}
-                                   {:dev {:source-paths ["target/generated/src/cljs" "src/cljs" "src/clj" "target/classes"]
+                                   {:dev {:source-paths ["target/generated/src/cljs" "src/cljs" "src/clj" "target/classes" ]
                                                   :compiler {:output-to "target/tests.js"
                                                              :pretty-print true}
                                                   :notify-command test-command


Start repl inside lein ring server

Start repl inside lein ring server

--- project.clj
+++ project.clj
@@ -6,7 +6,8 @@
                  [enlive "1.1.5"]
                  ]
   :plugins [[lein-ring "0.8.10"]]
-  :ring {:handler clj-team-tasks.handler/app}
+  :ring {:handler clj-team-tasks.handler/app
+         :nrepl {:start? true}}
   :profiles
   {:dev {:dependencies [[javax.servlet/servlet-api "2.5"]
                         [ring-mock "0.1.5"]


GR - switch to old style lein deployments

--- project.clj
+++ project.clj
@@ -31,7 +31,6 @@
                  [org.pegdown/pegdown "1.2.0"]
                  [clojure-csv/clojure-csv "2.0.1"]]
   :main objective8.core
-  :uberjar-name "objective8-0.0.1-SNAPSHOT-standalone.jar"
   :plugins [[ragtime/ragtime.lein "0.3.8"]]
   :profiles {:dev {:source-paths ["dev"]
                    :repl-options {:init-ns user


Updated some connection pool settings.

Updated some connection pool settings.

--- src/hateoasql/dao.clj
+++ src/hateoasql/dao.clj
@@ -35,6 +35,7 @@
        :password db-password
        :max-connection-lifetime 50 * 1000
        :test-connection-on-borrow true
+       :test-idle-connections-period 10 * 1000
        :test-connection-query "SELECT 1"}
       )