More documentation changes around "log" to "logger".

--- src/main/clojure/clojure/tools/logging.clj
+++ src/main/clojure/clojure/tools/logging.clj
@@ -37,7 +37,7 @@
   this library."
   (impl-name [factory]
     "Returns some text identifying the underlying implementation.")
-  (impl-get-logger [factory log-ns]
+  (impl-get-logger [factory logger-ns]
     "Returns an implementation-specific Logger by namespace. End-users should not
     need to call this."))

@@ -88,10 +88,10 @@
     `(log ~level nil ~message))
   ([level throwable message]
     `(log ~*ns* ~level ~throwable ~message))
-  ([log-ns level throwable message]
-    `(log *logger-factory* ~log-ns ~level ~throwable ~message))
-  ([logger-factory log-ns level throwable message]
-    `(let [logger# (impl-get-logger ~logger-factory ~log-ns)]
+  ([logger-ns level throwable message]
+    `(log *logger-factory* ~logger-ns ~level ~throwable ~message))
+  ([logger-factory logger-ns level throwable message]
+    `(let [logger# (impl-get-logger ~logger-factory ~logger-ns)]
        (if (impl-enabled? logger# ~level)
          (log* logger# ~level ~throwable ~message)))))

@@ -124,15 +124,15 @@
 (defmacro enabled?
   "Returns true if the specific logging level is enabled.  Use of this function
   should only be necessary if one needs to execute alternate code paths beyond
-  whether the logger should be written to."
+  whether the log should be written to."
   ([level]
     `(enabled? ~level ~*ns*))
-  ([level log-ns]
-    `(impl-enabled? (impl-get-logger *logger-factory* ~log-ns) ~level)))
+  ([level logger-ns]
+    `(impl-enabled? (impl-get-logger *logger-factory* ~logger-ns) ~level)))

 (defmacro spy
-  "Evaluates expr and writes the form and its result to the logger. Returns the
-  result of expr. Defaults to debug log level."
+  "Evaluates expr and may write the form and its result to the log. Returns the
+  result of expr. Defaults to :debug log level."
   ([expr]
     `(spy :debug ~expr))
   ([level expr]
@@ -147,9 +147,9 @@
        a#)))

 (defn log-stream
-  "Creates a PrintStream that will output to the logger at the specified level."
-  [level log-ns]
-  (let [logger (impl-get-logger *logger-factory* log-ns)]
+  "Creates a PrintStream that will output to the log at the specified level."
+  [level logger-ns]
+  (let [logger (impl-get-logger *logger-factory* logger-ns)]
     (java.io.PrintStream.
       (proxy [java.io.ByteArrayOutputStream] []
         (flush []
@@ -166,24 +166,24 @@
       monitor (Object.)] ; sync monitor for calling setOut/setErr
   (defn log-capture!
     "Captures System.out and System.err, piping all writes of those streams to
-    the logger. If unspecified, levels default to :info and :error, respectively.
-    The specified log-ns value will be used to namespace all log entries.
+    the log. If unspecified, levels default to :info and :error, respectively.
+    The specified logger-ns value will be used to namespace all log entries.

     Note: use with-logs to redirect output of *out* or *err*.

     Warning: if the logging implementation is configured to output to System.out
     (as is the default with java.util.logging) then using this function will
-    result in StackOverflowException when writing to the logger."
+    result in StackOverflowException when writing to the log."
     ; Implementation Notes:
     ; - only set orig when nil to preserve original out/err
     ; - no enabled? check before making streams since that may change later
-    ([log-ns]
-      (log-capture! log-ns :info :error))
-    ([log-ns out-level err-level]
+    ([logger-ns]
+      (log-capture! logger-ns :info :error))
+    ([logger-ns out-level err-level]
       (locking monitor
         (compare-and-set! orig nil [System/out System/err])
-        (System/setOut  (log-stream out-level log-ns))
-        (System/setErr (log-stream err-level log-ns)))))
+        (System/setOut  (log-stream out-level logger-ns))
+        (System/setErr (log-stream err-level logger-ns)))))
   (defn log-uncapture!
     "Restores System.out and System.err to their original values."
     []
@@ -194,23 +194,23 @@
         (System/setErr err)))))

 (defmacro with-logs
-  "Evaluates exprs in a context in which *out* and *err* write to the logger. The
-  specified log-ns value will be used to namespace all log entries.
+  "Evaluates exprs in a context in which *out* and *err* write to the log. The
+  specified logger-ns value will be used to namespace all log entries.

   By default *out* and *err* write to :info and :error, respectively."
-  {:arglists '([log-ns & body]
-               [[log-ns out-level err-level] & body])}
+  {:arglists '([logger-ns & body]
+               [[logger-ns out-level err-level] & body])}
   [arg & body]
   ; Implementation Notes:
   ; - no enabled? check before making writers since that may change later
-  (let [[log-ns out-level err-level] (if (vector? arg)
+  (let [[logger-ns out-level err-level] (if (vector? arg)
                                        arg
                                        [arg :info :error])]
-    (if (and log-ns (seq body))
+    (if (and logger-ns (seq body))
       `(binding [*out* (java.io.OutputStreamWriter.
-                         (log-stream ~out-level ~log-ns))
+                         (log-stream ~out-level ~logger-ns))
                  *err* (java.io.OutputStreamWriter.
-                         (log-stream ~err-level ~log-ns))]
+                         (log-stream ~err-level ~logger-ns))]
          ~@body))))

@@ -322,8 +322,8 @@
          (reify LoggerFactory
            (impl-name [_#]
              "org.apache.commons.logging")
-           (impl-get-logger [_# log-ns#]
-             (org.apache.commons.logging.LogFactory/getLog (str log-ns#))))))
+           (impl-get-logger [_# logger-ns#]
+             (org.apache.commons.logging.LogFactory/getLog (str logger-ns#))))))
     (catch Exception e nil)))

 (defn slf4j-logging
@@ -358,8 +358,8 @@
         (reify LoggerFactory
           (impl-name [_#]
             "org.slf4j")
-          (impl-get-logger [_# log-ns#]
-            (org.slf4j.LoggerFactory/getLogger ^String (str log-ns#))))))
+          (impl-get-logger [_# logger-ns#]
+            (org.slf4j.LoggerFactory/getLogger ^String (str logger-ns#))))))
     (catch Exception e nil)))

 (defn log4j-logging
@@ -392,8 +392,8 @@
          (reify LoggerFactory
            (impl-name [_#]
              "org.apache.log4j")
-           (impl-get-logger [_# log-ns#]
-             (org.apache.log4j.Logger/getLogger ^String (str log-ns#))))))
+           (impl-get-logger [_# logger-ns#]
+             (org.apache.log4j.Logger/getLogger ^String (str logger-ns#))))))
     (catch Exception e nil)))

 (defn java-util-logging
@@ -428,8 +428,8 @@
          (reify LoggerFactory
            (impl-name [_#]
              "java.util.logging")
-           (impl-get-logger [_# log-ns#]
-             (java.util.logging.Logger/getLogger (str log-ns#))))))
+           (impl-get-logger [_# logger-ns#]
+             (java.util.logging.Logger/getLogger (str logger-ns#))))))
     (catch Exception e nil)))

 (defn find-factory


Fix OverigBouwwerk workaround for StUF-Geo

--- src/main/clojure/pdok/featured/feature.clj
+++ src/main/clojure/pdok/featured/feature.clj
@@ -186,6 +186,6 @@
                               (geometry-attribute-dispatcher obj)))
 (defmethod as-stufgeo-gml-lc "gml" [^GeometryAttribute obj]
            (when (.getGeometry obj)
-                 (map-replace (as-stufgeo-gml obj) #"(<imgeo:multiVlak>.+</imgeo:multiVlak>)" "<imgeo:multivlak>$1</imgeo:multivlak>"
-                              #"(<imgeo:multiPunt>.+</imgeo:multiPunt>)" "<imgeo:multipunt>$1</imgeo:multipunt>")))
+                 (map-replace (as-stufgeo-gml obj) #"<imgeo:multiVlak>(.+)</imgeo:multiVlak>" "<imgeo:multivlak>$1</imgeo:multivlak>"
+                              #"<imgeo:multiPunt>(.+)</imgeo:multiPunt>" "<imgeo:multipunt>$1</imgeo:multipunt>")))
 (defmethod as-stufgeo-gml-lc :default [_] nil)


Fixed minor bug, and made more dashes in inputs.

--- src/clojush/problems/software/benchmarks_v2/camel_case.clj
+++ src/clojush/problems/software/benchmarks_v2/camel_case.clj
@@ -29,13 +29,14 @@

 ;; Define test cases
 (defn camel-case-input
-  "Makes a Camel Case input of length len."
+  "Makes a Camel Case input of length len.
+   Note that 2/3 of spaces/dashes are dashes."
   [len]
   (loop [result-string (word-generator)]
     (if (>= (count result-string) len)
       (cleanup-length result-string len)
       (recur (str result-string
-                  (if (< (lrand) 0.5) \- \space)
+                  (if (< (lrand) 0.66) \- \space)
                   (word-generator))))))

 ; Atom generators
@@ -122,7 +123,7 @@
                          ; Record the behavior
                          (swap! behavior conj result)
                          ; Error is Levenshtein distance for printed string
-                         (levenshtein-distance correct-output result)
+                         (levenshtein-distance correct-output (str result))
                          )))]
         (if (= data-cases :train)
           (assoc individual :behaviors @behavior :errors errors)


Use the double-barrelled arrow because comp leads to reading things backwards.

--- src/overtunes/songs/canone_alla_quarta.clj
+++ src/overtunes/songs/canone_alla_quarta.clj
@@ -107,7 +107,7 @@
 (defn canone-alla-quarta# []
   (let [[timing pitch] [0 1]
         [tempo start] [(bpm 90) (now)]
-        in-time (comp (shift [start 0]) (skew timing tempo))
+        in-time #(=> % (skew timing tempo) (shift [start 0]))
         in-key (skew pitch g-major)
         play-now# #(=> % in-key in-time play#)]

@@ -122,4 +122,3 @@

-


Removed misaligning line

Removed misaligning line

--- src/overtunes/songs/canone_alla_quarta.clj
+++ src/overtunes/songs/canone_alla_quarta.clj
@@ -21,7 +21,6 @@
     (play# notes)))

 ;(demo# (range 60 73))
-


Fix failing tests

Fix failing tests

Caused be removing unneeded classes here:
092f97464192f6043d647a8f2c326a5016187e01

--- test/clojars/test/integration/jars.clj
+++ test/clojars/test/integration/jars.clj
@@ -4,7 +4,8 @@
             [kerodon.test :refer :all]
             [clojars.test.integration.steps :refer :all]
             [clojars.web :as web]
-            [clojars.test.test-helper :as help]))
+            [clojars.test.test-helper :as help]
+            [net.cgrand.enlive-html :as html]))

 (use-fixtures :each help/default-fixture)

@@ -19,7 +20,7 @@
       (visit "/fake/test")
       (within [:div#jar-title :h1 :a]
               (has (text? "fake/test")))
-      (within [:.lein-small :pre]
+      (within [[:.package-config-example html/first-of-type] :pre]
               (has (text? "[fake/test \"0.0.2\"]")))
       (within [:ul#versions]
               (has (text? "0.0.3-SNAPSHOT0.0.20.0.1")))))
@@ -32,7 +33,7 @@
       (visit "/fake/test")
       (within [:div#jar-title :h1 :a]
               (has (text? "fake/test")))
-      (within [:.lein-small :pre]
+      (within [[:.package-config-example html/first-of-type] :pre]
               (has (text? "[fake/test \"0.0.3-SNAPSHOT\"]")))
       (within [:span.commit-url]
               (has (text? " with this commit")))
@@ -49,7 +50,7 @@
       (visit "/fake")
       (within [:div#jar-title :h1 :a]
               (has (text? "fake")))
-      (within [:.lein-small :pre]
+      (within [[:.package-config-example html/first-of-type] :pre]
               (has (text? "[fake \"0.0.2\"]")))
       (within [:ul#versions]
               (has (text? "0.0.3-SNAPSHOT0.0.20.0.1")))))
@@ -65,7 +66,7 @@
       (follow "0.0.3-SNAPSHOT")
       (within [:div#jar-title :h1 :a]
               (has (text? "fake/test")))
-      (within [:.lein-small :pre]
+      (within [[:.package-config-example html/first-of-type] :pre]
               (has (text? "[fake/test \"0.0.3-SNAPSHOT\"]")))
       (within [:ul#versions]
               (has (text? "0.0.3-SNAPSHOT0.0.20.0.1")))))
@@ -81,7 +82,7 @@
       (follow "0.0.1")
       (within [:div#jar-title :h1 :a]
               (has (text? "fake")))
-      (within [:.lein-small :pre]
+      (within [[:.package-config-example html/first-of-type] :pre]
               (has (text? "[fake \"0.0.1\"]")))
       (within [:ul#versions]
               (has (text? "0.0.3-SNAPSHOT0.0.20.0.1")))))


Upgrade logging

Upgrade logging

--- lein-template/project.clj
+++ lein-template/project.clj
@@ -6,8 +6,14 @@
   :url "http://modularity.org/"
   :license {:name "The MIT License"
             :url "http://opensource.org/licenses/MIT"}
-  :dependencies [[org.clojure/clojure "1.7.0-RC2"]
-                 ;; EDN reader with location metadata
-                 [org.clojure/tools.reader "0.8.3"]
-                 [org.clojure/tools.logging "0.2.6"]]
-  :eval-in-leiningen true)
+
+  :dependencies []
+
+  :eval-in-leiningen true
+
+  :profiles {:dev
+             {:dependencies
+              [[org.clojure/clojure "1.7.0"]
+               ;; EDN reader with location metadata
+               [org.clojure/tools.reader "0.8.3"]
+               [org.clojure/tools.logging "0.3.1"]]}})


Filter changed test site name from sites-test

--- test/clj/comic_reader/sites_test.clj
+++ test/clj/comic_reader/sites_test.clj
@@ -368,7 +368,7 @@
   (try
     (let [site-names (->> (scraper/get-sites)
                           (map first)
-                          (filter (complement #{"test-site" "sites-list"})))]
+                          (filter (complement #{"test"})))]
       (prn site-names)
       `(do ~@(map testdef-form site-names)))
     (catch RuntimeException e


Version 0.0.8-SNAPSHOT

Version 0.0.8-SNAPSHOT

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject coffee-table "0.0.7"
+(defproject coffee-table "0.0.8-SNAPSHOT"
   :description "A site for Gaelan's café reviews"
   :url "http://github.com/RobotDisco/coffee-table"
   :license {:name "Eclipse Public License - v 1.0"


Version 0.4.0

Version 0.4.0

--- project.clj
+++ project.clj
@@ -2,7 +2,7 @@
 (def ks-version "1.3.0")

-(defproject puppetlabs/trapperkeeper-status "0.4.0-SNAPSHOT"
+(defproject puppetlabs/trapperkeeper-status "0.4.0"
   :description "A trapperkeeper service for getting the status of other trapperkeeper services."
   :url "https://github.com/puppetlabs/trapperkeeper-status"
   :license {:name "Apache License, Version 2.0"


Set version to 1.5.0-SNAPSHOT

Set version to 1.5.0-SNAPSHOT

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject funcool/promesa "1.4.0"
+(defproject funcool/promesa "1.5.0-SNAPSHOT"
   :description "A promise library for ClojureScript"
   :url "https://github.com/funcool/promesa"
   :license {:name "BSD (2 Clause)"


update version to release candidate

update version to release candidate

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


v0.5.17: dependencies; no dependency on specific Clojure version

--- project.clj
+++ project.clj
@@ -1,4 +1,4 @@
-(defproject matthiasn/systems-toolbox-sente "0.5.16"
+(defproject matthiasn/systems-toolbox-sente "0.5.17"
   :description "WebSocket components for systems-toolbox"
   :url "https://github.com/matthiasn/systems-toolbox"
   :license {:name "Eclipse Public License"
@@ -6,9 +6,7 @@

   :source-paths ["src/cljc" "src/clj" "src/cljs"]

-  :dependencies [[org.clojure/clojure "1.8.0"]
-                 [org.clojure/tools.reader "1.0.0-beta1"]
-                 [org.clojure/clojurescript "1.8.51"]
+  :dependencies [[org.clojure/tools.reader "1.0.0-beta1"]
                  [org.ow2.asm/asm-all "5.1"]
                  [org.clojure/core.async "0.2.374" :exclusions [org.clojure/tools.reader]]
                  [org.clojure/tools.logging "0.3.1"]
@@ -22,10 +20,13 @@
                  [ring/ring-defaults "0.2.0"]
                  [com.lucasbradstreet/cljs-uuid-utils "1.0.2"]
                  [org.jboss.logging/jboss-logging "3.3.0.Final"]
-                 [io.undertow/undertow-core "2.0.0.Alpha1"]
+                 [io.undertow/undertow-core "1.3.22.Final"]
                  [org.immutant/web "2.1.4" :exclusions [org.jboss.xnio/xnio-api
                                                         org.jboss.logging/jboss-logging
                                                         org.jboss.xnio/xnio-nio org.slf4j/slf4j-api]]]

+  :profiles {:dev {:dependencies [[org.clojure/clojure "1.9.0-alpha3"]
+                                  [org.clojure/clojurescript "1.9.36"]]}}
+
   :plugins [[lein-codox "0.9.5" :exclusions [org.clojure/clojure]]
             [lein-cljsbuild "1.1.3"]])


Add script/ to source-paths

Add script/ to source-paths

--- project.clj
+++ project.clj
@@ -26,7 +26,7 @@
             [lein-kibit "0.1.2"]
             [lein-doo "0.1.6"]]

-  :source-paths ["src/discuss"]
+  :source-paths ["src/discuss" "script"]

   :clean-targets ^{:protect false} ["resources/public/js/compiled" "target"]


riemann-clojure-client 0.0.6

riemann-clojure-client 0.0.6

--- project.clj
+++ project.clj
@@ -19,29 +19,28 @@
   }
   :maintainer {:email "aphyr@aphyr.com"}
   :dependencies [
+    [org.clojure/algo.generic "0.1.0"]
     [org.clojure/clojure "1.4.0"]
     [org.clojure/math.numeric-tower "0.0.1"]
-    [org.clojure/algo.generic "0.1.0"]
     [org.clojure/tools.logging "0.2.3"]
     [log4j/log4j "1.2.16" :exclusions [javax.mail/mail
                                        javax.jms/jms
                                        com.sun.jdmk/jmxtools
                                        com.sun.jmx/jmxri]]
-    [log4j/apache-log4j-extras "1.0"]
     [aleph "0.2.1-beta2"]
-    [io.netty/netty "3.3.0.Final"]
-    [org.antlr/antlr "3.2"]
-    [com.boundary/high-scale-lib "1.0.3"]
-    [clj-time "0.3.4"]
-    [com.draines/postal "1.8.0"]
-    [riemann-clojure-client "0.0.6-SNAPSHOT"]
-    [slingshot "0.10.2"]
-    [org.slf4j/slf4j-log4j12 "1.6.4"]
     [clj-http "0.4.1"]
     [clj-json "0.5.0"]
+    [clj-librato "0.0.2"]
     [clj-time "0.4.3"]
-    [clj-librato "0.0.2"]
+    [com.boundary/high-scale-lib "1.0.3"]
+    [com.draines/postal "1.8.0"]
     [incanter/incanter-charts "1.3.0"]
+    [io.netty/netty "3.3.0.Final"]
+    [log4j/apache-log4j-extras "1.0"]
+    [org.antlr/antlr "3.2"]
+    [org.slf4j/slf4j-log4j12 "1.6.4"]
+    [riemann-clojure-client "0.0.6"]
+    [slingshot "0.10.2"]
   ]
   :plugins [[codox "0.6.1"]]
   :test-selectors {:default (fn [x] (not (or (:integration x)


Upgrading library versions.

Upgrading library versions.

--- project.clj
+++ project.clj
@@ -4,7 +4,7 @@
   :url "***REMOVED***projects/CMR/repos/cmr-transmit-lib/browse"

   :dependencies [[org.clojure/clojure "1.6.0"]
-                 [clj-http "0.9.1"]
+                 [clj-http "1.0.0"]
                  [nasa-cmr/cmr-common-lib "0.1.1-SNAPSHOT"]
                  [nasa-cmr/cmr-system-trace-lib "0.1.0-SNAPSHOT"]]


bug #3735 - fixed broken send and request commands in chat (again)

Signed-off-by: Goran Jovic <fc686822162e6f379ea05b6f92d78d206147085c@gmail.com>

--- src/status_im/chat/events/send_message.cljs
+++ src/status_im/chat/events/send_message.cljs
@@ -35,7 +35,7 @@
 (handlers/register-handler-fx
   :chat-send-message/send-command
   message-model/send-interceptors
-  (fn [cofx [params]]
+  (fn [cofx [_ params]]
     (message-model/send-command cofx params)))

 (handlers/register-handler-fx


actually use the separate caches

actually use the separate caches

git-svn-id: 03a8048b5ee8463be5048a3801110fb50f378627@9933 d0ab736e-dc22-4aeb-8dc9-08def0aa14fd

--- plugins/SlideExplorer2/src/slide_explorer/view.clj
+++ plugins/SlideExplorer2/src/slide_explorer/view.clj
@@ -285,7 +285,7 @@
         memory-tiles2 (tile-cache/create-tile-cache 100 dir)
         frame (main-frame)
         [panel screen-state] (view-panel memory-tiles acquired-images)
-        [panel2 screen-state2] (view-panel memory-tiles acquired-images)
+        [panel2 screen-state2] (view-panel memory-tiles2 acquired-images)
         split-pane (JSplitPane. JSplitPane/HORIZONTAL_SPLIT true panel panel2)]
     (doto split-pane
       (.setResizeWeight 0.5)


Formatting

Formatting

--- cimi/src/com/sixsq/slipstream/ssclj/resources/connector.clj
+++ cimi/src/com/sixsq/slipstream/ssclj/resources/connector.clj
@@ -5,10 +5,8 @@
     [com.sixsq.slipstream.ssclj.resources.common.schema :as c]
     [com.sixsq.slipstream.ssclj.resources.common.crud :as crud]
     [com.sixsq.slipstream.ssclj.resources.common.utils :as u]
-    [com.sixsq.slipstream.auth.acl :as a]
-    [com.sixsq.slipstream.util.response :as sr])
-  (:import (clojure.lang ExceptionInfo))
-  )
+    [com.sixsq.slipstream.auth.acl :as a])
+  (:import (clojure.lang ExceptionInfo)))

 (def ^:const resource-tag :connectors)

@@ -146,10 +144,9 @@
 (defmethod activate-subtype :default
   [resource _]
   (let [err-msg (str "unknown Connector type: " (:cloudServiceType resource))]
-    (throw
-      (ex-info err-msg {:status  400
-                        :message err-msg
-                        :body    resource}))))
+    (throw (ex-info err-msg {:status  400
+                             :message err-msg
+                             :body    resource}))))

 (defmethod crud/do-action [resource-url "activate"]
   [{{uuid :uuid} :params :as request}]
@@ -169,8 +166,7 @@
 (defmethod set-compromised-subtype :default
   [resource _]
   (let [err-msg (str "unknown Connector type: " (:cloudServiceType resource))]
-    (throw
-      (ex-info err-msg {:status  400
+    (throw (ex-info err-msg {:status  400
                         :message err-msg
                         :body    resource}))))

@@ -184,15 +180,12 @@
     (catch ExceptionInfo ei
       (ex-data ei))))

-
-
 (defmulti set-subtype-ops
           (fn [resource _] (:cloudServiceType resource)))

 (defmethod set-subtype-ops :default
   [resource request]
-  (crud/set-standard-operations resource request)
-  )
+  (crud/set-standard-operations resource request))

 (defmethod crud/set-operations resource-uri
   [resource request]


fix wrong parentheses

fix wrong parentheses

--- components/sente/src/gorillalabs/tesla/component/router.clj
+++ components/sente/src/gorillalabs/tesla/component/router.clj
@@ -13,13 +13,13 @@
   (go-loop [event-msg (<! event-msg-channel)]
            (when event-msg
              (let [{:keys [id event ?reply-fn]} event-msg]
-               (go (if-let [event-fn (get @(:events router) id)]
-                     (try
+               (go (try
+                     (if-let [event-fn (get @(:events router) id)]
                        (event-fn event-msg)
                        (do (log/info "Unhandled event: %s" id)
                            (when ?reply-fn
-                             (?reply-fn {:umatched-event-as-echoed-from-from-server event})))
-                     (catch Exception e (log/error  "Caught exception: " (.getMessage e)))))
+                             (?reply-fn {:umatched-event-as-echoed-from-from-server event}))))
+                     (catch Exception e (log/error  "Caught exception: " (.getMessage e))))
                    ))
              (recur (<! event-msg-channel)))))


Fix minor typo

Fix minor typo

--- src/life/demo.clj
+++ src/life/demo.clj
@@ -69,7 +69,7 @@

 ;; Since the outer-product function is not standard in Clojure, a similar effect
 ;; can be made by performing the vertical rotations first, using the mapping
-;; echnique above, followed by the horizontal rotations. These are done by mapping
+;; technique above, followed by the horizontal rotations. These are done by mapping
 ;; the horizontal rotation operation across each element of the vertical-rotated
 ;; matrix vector
 (disp (map (fn [d] (map #(rotate %2 1 %1) [1 0 -1] (repeat d)))


CMR-1841: Addressed a test failure in translate-test

--- umm-spec-lib/src/cmr/umm_spec/test/expected_conversion.clj
+++ umm-spec-lib/src/cmr/umm_spec/test/expected_conversion.clj
@@ -144,8 +144,7 @@
      :Organizations [{:Role "ORIGINATOR"
                       :Party {:ServiceHours "24/7"
                               :OrganizationName {:ShortName "org 1"
-                                                 :LongName "longname"
-                                                 :Uuid "uuid"}
+                                                 :LongName "longname"}
                               :Addresses [{:StreetAddresses ["23 abc st"]
                                            :City "city"}]}}
                      {:Role "POINTOFCONTACT"


Added metadata to the sample blog.

Added metadata to the sample blog.

--- lambda-blog/test/lambda_blog/fixtures.clj
+++ lambda-blog/test/lambda_blog/fixtures.clj
@@ -44,12 +44,14 @@
              (i {:class [:fa :fa-feed]})
              " Feed"))))

+(def description "A static blog generator generator optimized for customizability.")
+
 (defn- banner [{:keys [logo path-to-root url]}]
   (row (div {:class [:col-xs-12 :col-sm-8 :col-md-10]}
             (h1 {:style "font-size: 300%;"}
                 "λ-blog")
             (p {:style "font-size: 150%;"}
-               "A static blog generator generator optimized for customizability."))
+               description))
        (div {:class [:hidden-xs :col-sm-2 :col-md-1 :pull-right]}
             (img {:style "height: 120px;"
                   :src (pathcat path-to-root logo)}))))
@@ -67,6 +69,8 @@
 (def docs {:author "Idorobots"
            :brand "λ-blog"
            :title "λ-blog documentation"
+           :description description
+           :keywords "λ-blog, lambda blog, static site generator, blogging platform, blogging software"
            :url "https://idorobots.github.io/lambda-blog/"
            :output-dir "/target/out/"
            :brand-logo "media/logo.svg"


code cleanup

code cleanup

--- test/metabase/api/common/throttle_test.clj
+++ test/metabase/api/common/throttle_test.clj
@@ -41,76 +41,76 @@

 ;;; # tests for check

-(defn- login
+(defn- attempt
   ([n]
-   (login n (gensym)))
+   (attempt n (gensym)))
   ([n k]
-   (let [login-once (fn []
+   (let [attempt-once (fn []
                       (try
                         (throttle/check test-throttler k)
                         :success
                         (catch Throwable e
                           (:test (:errors (ex-data e))))))]
-     (vec (repeatedly n login-once)))))
+     (vec (repeatedly n attempt-once)))))

-;; a couple of quick "logins" shouldn't trigger the throttler
+;; a couple of quick "attempts" shouldn't trigger the throttler
 (expect [:success :success]
-  (login 2))
+  (attempt 2))

 ;; nor should 3
 (expect [:success :success :success]
-  (login 3))
+  (attempt 3))

 ;; 4 in quick succession should trigger it
 (expect [:success :success :success "Too many attempts! You must wait 0 seconds before trying again."] ; rounded down
-  (login 4))
+  (attempt 4))

 ;; Check that throttling correctly lets you try again after certain delay
 (expect [[:success :success :success "Too many attempts! You must wait 0 seconds before trying again."]
          [:success]]
-  [(login 4 :a)
+  [(attempt 4 :a)
    (do
      (Thread/sleep 2)
-     (login 1 :a))])
+     (attempt 1 :a))])

 ;; Next attempt should be throttled, however
 (expect [:success "Too many attempts! You must wait 0 seconds before trying again."]
   (do
-    (login 4 :b)
+    (attempt 4 :b)
     (Thread/sleep 2)
-    (login 2 :b)))
+    (attempt 2 :b)))

 ;; Sleeping 2 ms after that shouldn't work due to exponential growth
 (expect ["Too many attempts! You must wait 0 seconds before trying again."]
   (do
-    (login 4 :c)
+    (attempt 4 :c)
     (Thread/sleep 2)
-    (login 2 :c)
+    (attempt 2 :c)
     (Thread/sleep 2)
-    (login 1 :c)))
+    (attempt 1 :c)))

 ;; Sleeping 8 ms however should work
 (expect [:success]
   (do
-    (login 4 :d)
+    (attempt 4 :d)
     (Thread/sleep 2)
-    (login 2 :d)
+    (attempt 2 :d)
     (Thread/sleep 8)
-    (login 1 :d)))
+    (attempt 1 :d)))

 ;; Check that the interal list for the throttler doesn't keep growing after throttling starts
 (expect [0 4]
   [(do (reset! (:attempts test-throttler) '()) ; reset it to 0
        (count @(:attempts test-throttler)))
-   (do (login 1000)
+   (do (attempt 1000)
        (count @(:attempts test-throttler)))])

-;; Check that login attempts clear after the TTL
+;; Check that attempts clear after the TTL
 (expect [0 3 1]
   [(do (reset! (:attempts test-throttler) '()) ; reset it to 0
        (count @(:attempts test-throttler)))
-   (do (login 3)
+   (do (attempt 3)
        (count @(:attempts test-throttler)))
    (do (Thread/sleep 10)
-       (login 1)
+       (attempt 1)
        (count @(:attempts test-throttler)))])


refactoring

refactoring

--- examples/lesson-carousel-starter-kit/src/carousel/core.cljs
+++ examples/lesson-carousel-starter-kit/src/carousel/core.cljs
@@ -1,8 +1,8 @@
 (ns ^:figwheel-always carousel.core
-  (:require-macros [cljs.core.async.macros :refer [go]])
-  (:require [com.famous.Famous]
-            [carousel.util :refer [events->chan]]
-            [cljs.core.async :refer [>! <! put! chan alts!]]))
+    (:require-macros [cljs.core.async.macros :refer [go]])
+    (:require [com.famous.Famous]
+              [carousel.util :refer [events->chan]]
+              [cljs.core.async :refer [>! <! put! chan alts!]]))

 (enable-console-print!)

@@ -25,6 +25,10 @@
 (defonce ABSOLUTE (.. Size -ABSOLUTE))

 (defn decorate-arrow-node [arrow-node text]
+  (.. arrow-node
+      (setSizeMode 1 1)
+      (setAbsoluteSize 40 40))
+
   (.. (DOMElement. arrow-node)
       (setProperty "color" "white")
       (setContent text)
@@ -35,137 +39,129 @@
       (setProperty "zIndex" "2")))

 (defn decorate-dots [dots-node]
-      (let [dot-nodes (.. dots-node getChildren)
-            resize (clj->js {:onSizeChange (fn [^Float32Array size]
-                                               "NOTE: this call back is called only once because root-dot setSizeMode is ABSOLUTE (value of 1)"
-                                               (let [size (IndexedSeq. size 0)
-                                                     dotWidth 10
-                                                     numPages 5
-                                                     spacing 5
-                                                     totalDotSize (+ (* numPages dotWidth)
-                                                                     (* spacing (dec numPages)))
-                                                     start-x (/ (- (nth size 0) totalDotSize)
-                                                                2)]
-                                                    (doseq [n (range (count dot-nodes))
-                                                            :let [dot-node (nth dot-nodes n)]]
-                                                           (.. dot-node (setPosition (+ start-x
-                                                                                (* n
-                                                                                (+ dotWidth spacing)))
-                                                                                0
-                                                                                0)))))})]
-           (doseq [dot-node dot-nodes]
-                  (.. (DOMElement. dot-node)
-                      (setProperty "borderRadius" "5px")
-                      (setProperty "border" "2px solid white")
-                      (setProperty "boxSizing" "border-box")))
+  (let [dot-nodes (.. dots-node getChildren)
+        resize (clj->js {:onSizeChange (fn [^Float32Array size]
+                                         "NOTE: this call back is called only once because root-dot setSizeMode is ABSOLUTE (value of 1)"
+                                         (let [size (IndexedSeq. size 0)
+                                               dotWidth 10
+                                               numPages 5
+                                               spacing 5
+                                               totalDotSize (+ (* numPages dotWidth)
+                                                               (* spacing (dec numPages)))
+                                               start-x (/ (- (nth size 0) totalDotSize)
+                                                          2)]
+                                           (doseq [n (range (count dot-nodes))
+                                                   :let [dot-node (nth dot-nodes n)]]
+                                             (.. dot-node (setPosition (+ start-x
+                                                                          (* n
+                                                                             (+ dotWidth spacing)))
+                                                                       0
+                                                                       0)))))})]
+    (doseq [dot-node dot-nodes]
+      (.. (DOMElement. dot-node)
+          (setProperty "borderRadius" "5px")
+          (setProperty "border" "2px solid white")
+          (setProperty "boxSizing" "border-box")))

-           (.. dots-node (addComponent resize))))
+    (.. dots-node (addComponent resize))))

 (defn create-dots [root-node]
-      (let [root-dot (.. root-node addChild)]
-           (doseq [i (range 5)
-                   :let [dot-node (.. root-dot addChild)]]
-                  (.. dot-node
-                      (setSizeMode ABSOLUTE ABSOLUTE)
-                      (setAbsoluteSize 5 5)))
-           (.. root-dot
-               (setSizeMode ABSOLUTE ABSOLUTE)
-               (setAbsoluteSize 20 20)
-               (setPosition 0 -50 0)
-               (setAlign 0.5 1 0)
-               (setMountPoint .5, 1, 0))
-           root-dot))
+  (let [root-dot (.. root-node addChild)]
+    (doseq [i (range 5)
+            :let [dot-node (.. root-dot addChild)]]
+      (.. dot-node
+          (setSizeMode ABSOLUTE ABSOLUTE)
+          (setAbsoluteSize 5 5)))
+    (.. root-dot
+        (setSizeMode ABSOLUTE ABSOLUTE)
+        (setAbsoluteSize 20 20)
+        (setPosition 0 -50 0)
+        (setAlign 0.5 1 0)
+        (setMountPoint .5, 1, 0))
+    root-dot))

 (defn create-pager [root-node]
-      (let [pager-node (.. root-node addChild)
-            simulation (PhysicsEngine.)
-            url-base "http://demo.famo.us.s3.amazonaws.com/hub/apps/carousel/Museo_del_Prado_-_Goya_-_Caprichos_-_No._"
-            image-names ["01_-_Autorretrato._Francisco_Goya_y_Lucientes2C_pintor_thumb.jpg"
-                         "02_-_El_si_pronuncian_y_la_mano_alargan_al_primero_que_llega_thumb.jpg"
-                         "03_-_Que_viene_el_Coco_thumb.jpg"
-                         "04_-_El_de_la_rollona_thumb.jpg"
-                         "05_-_Tal_para_qual_thumb.jpg"
-                         "06_-_Nadie_se_conoce_thumb.jpg"
-                         "07_-_Ni_asi_la_distingue_thumb.jpg"
-                         "09_-_Tantalo_thumb.jpg"
-                         "10_-_El_amor_y_la_muerte_thumb.jpg"
-                         "11_-_Muchachos_al_avC3ADo_thumb.jpg"
-                         "12_-_A_caza_de_dientes_thumb.jpg"
-                         "13_-_Estan_calientes_thumb.jpg"]
-            image-elements (map (fn [image-name]
-                                    (let [_image-url (str url-base image-name)
-                                          image-url (str "url('" _image-url "')")
-                                          image-node (.. root-node addChild)
-                                          el (DOMElement. image-node)
-                                          box (FamousBox. {:mass 100 :size [100 100 100]})
-                                          anchor (Vec3. 1 0 0)
-                                          spring (Spring. nil box {:period 0.5 :dampingRatio 0.5 :anchor anchor})
-                                          quaternion (.. (Quaternion.) (fromEuler 0 (/ (.. js/Math -PI) -2) 0))
-                                          rotational-spring (RotationalSpring. nil box {:period 1 :dampingRatio 0.2 :anchor quaternion})]
-                                         (.. image-node
-                                             (setSizeMode ABSOLUTE ABSOLUTE ABSOLUTE)
-                                             (setAbsoluteSize 500 500 0)
-                                             (setAlign 0.5 0.5)
-                                             (setMountPoint 0.5 0.5)
-                                             (setOrigin 0.5 0.5))
-                                         (.. el
-                                             (setProperty "backgroundImage" image-url)
-                                             (setProperty "background-repeat" "no-repeat")
-                                             (setProperty "background-size" "cover"))
-                                         ))
-                                image-names)
-            _ (doall image-elements)
-            pager {:node     pager-node
-                   :onUpdate (fn [time]
-                                 (.. simulation (update time))
+  (let [pager-node (.. root-node addChild)
+        simulation (PhysicsEngine.)
+        url-base "http://demo.famo.us.s3.amazonaws.com/hub/apps/carousel/Museo_del_Prado_-_Goya_-_Caprichos_-_No._"
+        image-names ["01_-_Autorretrato._Francisco_Goya_y_Lucientes2C_pintor_thumb.jpg"
+                     "02_-_El_si_pronuncian_y_la_mano_alargan_al_primero_que_llega_thumb.jpg"
+                     "03_-_Que_viene_el_Coco_thumb.jpg"
+                     "04_-_El_de_la_rollona_thumb.jpg"
+                     "05_-_Tal_para_qual_thumb.jpg"
+                     "06_-_Nadie_se_conoce_thumb.jpg"
+                     "07_-_Ni_asi_la_distingue_thumb.jpg"
+                     "09_-_Tantalo_thumb.jpg"
+                     "10_-_El_amor_y_la_muerte_thumb.jpg"
+                     "11_-_Muchachos_al_avC3ADo_thumb.jpg"
+                     "12_-_A_caza_de_dientes_thumb.jpg"
+                     "13_-_Estan_calientes_thumb.jpg"]
+        image-elements (map (fn [image-name]
+                              (let [_image-url (str url-base image-name)
+                                    image-url (str "url('" _image-url "')")
+                                    image-node (.. root-node addChild)
+                                    el (DOMElement. image-node)
+                                    box (FamousBox. {:mass 100 :size [100 100 100]})
+                                    anchor (Vec3. 1 0 0)
+                                    spring (Spring. nil box {:period 0.5 :dampingRatio 0.5 :anchor anchor})
+                                    quaternion (.. (Quaternion.) (fromEuler 0 (/ (.. js/Math -PI) -2) 0))
+                                    rotational-spring (RotationalSpring. nil box {:period 1 :dampingRatio 0.2 :anchor quaternion})]
+                                (.. image-node
+                                    (setSizeMode ABSOLUTE ABSOLUTE ABSOLUTE)
+                                    (setAbsoluteSize 500 500 0)
+                                    (setAlign 0.5 0.5)
+                                    (setMountPoint 0.5 0.5)
+                                    (setOrigin 0.5 0.5))
+                                (.. el
+                                    (setProperty "backgroundImage" image-url)
+                                    (setProperty "background-repeat" "no-repeat")
+                                    (setProperty "background-size" "cover"))
+                                ))
+                            image-names)
+        _ (doall image-elements)
+        pager {:node     pager-node
+               :onUpdate (fn [time]
+                           (.. simulation (update time))

-                                 )
-                   }]
-           pager-node
-           )
-      )
+                           )
+               }]
+    pager
+    )
+  )

 (defn Carousel [selector data]
-      (let [context (.. FamousEngine (createScene selector))
-            root-node (.. context addChild)
+  (let [context (.. FamousEngine (createScene selector))
+        root-node (.. context addChild)

-            back-node (.. root-node addChild)
-            back-clicks (events->chan back-node "tap")
-
-            next-node (.. root-node addChild)
-            next-clicks (events->chan next-node "tap")
-
-            dots-node (create-dots root-node)
-            pager-node (create-pager root-node)
+        back-node (.. root-node addChild)
+        back-clicks (events->chan back-node "tap")
+
+        next-node (.. root-node addChild)
+        next-clicks (events->chan next-node "tap")
+
+        dots-node (create-dots root-node)
+        pager (create-pager root-node)

-            back (decorate-arrow-node back-node "<")
-            next (decorate-arrow-node next-node ">")
-            dots (decorate-dots dots-node)
-            carousel-obj {:context context
-                          :root    root-node
-                          :back    back-node
-                          :next    next-node
-                          :dots    dots}]
-           (.. back-node
-               (setSizeMode 1 1)
-               (setAbsoluteSize 40 40)
-               (setPosition 40 0 0)
-               (setAlign 0 0.5 0)
-               (setMountPoint 0 0.5 0))
-           (.. next-node
-               (setSizeMode 1 1)
-               (setAbsoluteSize 40 40)
-               (setPosition -40 0 0)
-               (setAlign 1 0.5 0)
-               (setMountPoint 1 0.5 0))
-           (go
-             (while true
-               (let [[v channel] (alts! [back-clicks next-clicks])]
-                 (cond
-                   (= channel back-clicks) (println "back")
-                   (= channel next-clicks) (println "next")))))
-
-           carousel-obj))
+        back (decorate-arrow-node back-node "<")
+        next (decorate-arrow-node next-node ">")
+        dots (decorate-dots dots-node)
+        ]
+    (.. back-node
+        (setAlign 0 0.5 0)
+        (setPosition 40 0 0)
+        (setMountPoint 0 0.5 0))
+    (.. next-node
+        (setAlign 1 0.5 0)
+        (setPosition -40 0 0)
+        (setMountPoint 1 0.5 0))
+    (go
+      (while true
+        (let [[v channel] (alts! [back-clicks next-clicks])]
+          (cond
+            (= channel back-clicks) (println "back")
+            (= channel next-clicks) (println "next")))))
+
+    ))

 (Carousel "body" {})
 (.. FamousEngine init)


step1-HelloFamous

--- examples/lesson-carousel-starter-kit/src/carousel/core.cljs
+++ examples/lesson-carousel-starter-kit/src/carousel/core.cljs
@@ -8,80 +8,17 @@
 (defonce FamousEngine (.. famous -core -FamousEngine))
 (defonce GestureHandler (.. famous -components -GestureHandler))

-(defn Arrow [node options]
-  (let [el (DOMElement. node)
-        gestures (GestureHandler. node)
-        direction (.. options -direction)
-        arrow-direction (if (= direction 1)
-                          ">"
-                          "<")]
-    (.. el (setProperty "color" "white"))
-    (.. el (setContent arrow-direction))
-    (.. el (setProperty "fontSize" "40px"))
-    (.. el (setProperty "lineHeight" "40px"))
-    (.. el (setProperty "cursor" "pointer"))
-    (.. el (setProperty "textHighlight" "none"))
-    (.. el (setProperty "zIndex" "2"))
-
-    (.. gestures (on "tap" (fn []
-                             (.. node (emit "pageChange" (clj->js {:direction direction})))
-                             )))
-    {:node      node
-     :el        el
-     :direction direction
-     :gestures  gestures})
-
-  )
-
-(defn Dot [node]
-  (let [el (DOMElement. node)]
-    (.. el (setProperty "borderRadius" "5px"))
-    (.. el (setProperty "border" "2px solid white"))
-    (.. el (setProperty "boxSizing" "border-box"))
-
-    {:node node
-     :el el
-     :select (fn []
-               (.. el (setProperty "backgroundColor" "white")))
-     :deselect (fn []
-                 (.. el (setProperty "backgroundColor" "transparent")))}))
-
-(defn Dots [node options]
-  (let [numPages (:numPages options)
-        dotWidth (or (:dotWidth options) 10)
-        dots (for [i (range numPages)
-                   :let [dotNode (.. node addChild)]]
-               (do
-                 (.. dotNode (setSizeMode 1 1))
-                 (.. dotNode (setAbsoluteSize dotWidth dotWidth))
-                 (Dot dotNode)
-                 ))
-        resizeComponent {:onSizeChange (fn [size]
-                                         )}]
-    (.. (first dots) select)
-    (.. node (addComponent resizeComponent))
-
-    {:node node
-     :dots dots
-     :dotWidth dotWidth
-     :spacing  (or (:spacing options) 5)
-     :numPages numPages
-     :layoutDots (fn [size]
-                   )
-     })
-  )
-
 (defn Carousel [selector data]
   (let [context (.. FamousEngine (createScene selector))
         root (.. context addChild)
+        el (DOMElement. root)
+        _ (.. el (setContent "Hello World")
+              (setProperty "font-size" "40px")
+              (setProperty "color" "white"))
         carousel-obj {:context  context
                       :root     root
-                      :pageData data
-                      :arrows {:back (Arrow (.. root addChild) {:direction -1})
-                               :next (Arrow (.. root addChild) {:direction 1})}}
-        ]
-
-    carousel-obj
-    ))
+                      :el el}]
+    carousel-obj))

+(Carousel "body" {})
 (.. FamousEngine init)


added sort, sort-by and juxt as pure funcs

--- libs/permacode/src/permacode/validate.clj
+++ libs/permacode/src/permacode/validate.clj
@@ -82,6 +82,7 @@
                'take 'drop 'conj 'take-while 'drop-while 'split-with
                'count 'range 'apply 'concat 'reverse
                'first 'second 'nth 'rest 'next
+               'sort 'sort-by 'juxt
                'class 'name 'namespace
                'subs 're-find 're-matches 're-seq
                'list 'seq 'cons 'vector 'vec 'str 'set 'keyword 'symbol


Use hourglass icon for queue

Use hourglass icon for queue

--- src-cljs/frontend/components/insights/project.cljs
+++ src-cljs/frontend/components/insights/project.cljs
@@ -104,7 +104,7 @@
       [:i.material-icons "timer"]
       (first (datetime/millis-to-float-duration (:build_time_millis build)))]
      [:div.metadata-item.recent-time.queue-time
-      [:i.material-icons "av_timer"]
+      [:i.material-icons "hourglass_empty"]
       (first (datetime/millis-to-float-duration (:queued_time_millis build)))]
      [:div.metadata-item.build-number
       [:i.material-icons "storage"]


Update card heading and label

Update card heading and label

--- src-cljs/frontend/components/insights/project.cljs
+++ src-cljs/frontend/components/insights/project.cljs
@@ -106,12 +106,12 @@
                                   :formatter-use-start? true}})]]]
          [:div.card.insights-metadata
           [:dl
-           [:dt "median queue"]
-           [:dd (datetime/as-duration (insights/median (map :queued_time_millis bar-chart-builds)))]]]
+           [:dt "median queue time"]
+           [:dd (datetime/as-duration (insights/median (map :queued_time_millis bar-chart-builds))) " min"]]]
          [:div.card.insights-metadata
           [:dl
-           [:dt "median build"]
-           [:dd (datetime/as-duration (insights/median (map :build_time_millis bar-chart-builds)))]]]
+           [:dt "median build time"]
+           [:dd (datetime/as-duration (insights/median (map :build_time_millis bar-chart-builds))) " min"]]]
          [:div.card.insights-metadata
           [:dl
            [:dt "parallelism"]


Don't bind unused symbols

Don't bind unused symbols

--- src-cljs/frontend/components/pages/build/head.cljs
+++ src-cljs/frontend/components/pages/build/head.cljs
@@ -376,7 +376,7 @@
                                [:span.head "Next Job"]
                                [:span.value next-link]]])))]]))))))

-(defn build-head [{:keys [build-data project-data workflow-data] :as data} owner]
+(defn build-head [{:keys [workflow-data] :as data} owner]
   (reify
     om/IRender
     (render [_]


[ProjectSettings] Add forks-receive-secret-env-vars

--- src-cljs/frontend/components/project_settings.cljs
+++ src-cljs/frontend/components/project_settings.cljs
@@ -651,12 +651,17 @@
                                     "builds to use them and let others see your builds, both through the "
                                     "web UI and the API."]})
             (describe-flag {:flag :build-fork-prs
-                            :title "Permissive building of fork pull requests"
+                            :title "Build forked pull requests"
                             :blurb (list
                                     [:p
-                                     "Run builds of fork pull request changes with this project's configuration. "
+                                     "Run builds of pull requests from forks. "
                                      "CircleCI will automatically update the commit status shown on GitHub's "
-                                     "pull request page."]
+                                     "pull request page."])})
+            (describe-flag {:flag :forks-receive-secret-env-vars
+                            :title "Pass secrets to forked pull requests"
+                            :blurb (list
+                                    [:p
+                                     "Run builds of fork pull request changes with this project's configuration and secrets. "]
                                     [:p
                                      "There are serious security concerns with this setting (see "
                                      [:a (open-ext {:href "https://circleci.com/docs/fork-pr-builds/"}) "the documentation"] " for details.) "


Don't need prog-world printf.

Don't need prog-world printf.

--- src/cbfg/world/t1.cljs
+++ src/cbfg/world/t1.cljs
@@ -161,7 +161,6 @@
               prog-js (str "with (cbfg.world.t1) {" prog "}")
               prog-res (try (js/eval prog-js) (catch js/Object ex ex))]
           (println :prog-res prog-res)
-          (println :prog-world @prog-world)
           (<! prog-ch)
           (close! event-ch)
           (close! render-ch)


Fixed bug in update-db!. Throw errors on bad CLI args.

--- src/com/lemondronor/orbital_detector/updatedb.clj
+++ src/com/lemondronor/orbital_detector/updatedb.clj
@@ -31,6 +31,14 @@
             [com.lemondronor.orbital-detector.basestationdb :as basestationdb]))

 (set! *warn-on-reflection* true)
+
+(def this-namespace *ns*)
+
+
+(defn error [& args]
+  (flush)
+  (binding [*out* *err*]
+    (apply println args)))

 (defn read-csv
@@ -79,13 +87,16 @@
     (jdbc/with-db-transaction [t-conn db-spec]
       (doseq [csv-rec csv]
         (let [db-rec (basestationdb/find-aircraft t-conn (:ICAO csv-rec))]
-          (if csv-rec
+          (if db-rec
             (update-aircraft! t-conn db-rec csv-rec)
             (insert-aircraft! t-conn csv-rec)))))))

 (defn -main [& args]
-  (let [csv-path (first args)
-        db-path (second args)]
-    (update-db! (basestationdb/db-spec db-path) csv-path)))
+  (if-not (= (count args) 2)
+    (do (error "Usage:" this-namespace "<csv path> <basestation.sqb path>")
+        1)
+    (let [csv-path (first args)
+          db-path (second args)]
+      (update-db! (basestationdb/db-spec db-path) csv-path))))


Make sure returning new class from render works

--- test/testcloact.cljs
+++ test/testcloact.cljs
@@ -344,3 +344,63 @@
          (reagent/render-to-static-markup
           [:div.bar {:dangerously-set-inner-HTML
                      {:__html "
foobar
"}} ]))))
+
+(deftest test-return-class
+  (when isClient
+    (let [ran (atom 0)
+          top-ran (atom 0)
+          comp (fn []
+                 (swap! top-ran inc)
+                 (reagent/create-class
+                  {:component-did-mount #(swap! ran inc)
+                   :render
+                   (fn [this]
+                     (let [props (reagent/props this)]
+                       (is (map? props))
+                       (is (= props ((reagent/argv this) 1)))
+                       (is (= 1 (first (reagent/children this))))
+                       (is (= 1 (count (reagent/children this))))
+                       (swap! ran inc)
+                       [:div (str "hi " (:foo props) ".")]))}))
+          prop (atom {:foo "you"})
+          parent (fn [] [comp @prop 1])]
+      (with-mounted-component [parent]
+        (fn [C div]
+          (swap! ran inc)
+          (is (found-in #"hi you" div))
+          (is (= 1 @top-ran))
+          (is (= 3 @ran))
+
+          (swap! prop assoc :foo "me")
+          (reagent/flush)
+          (is (found-in #"hi me" div))
+          (is (= 1 @top-ran))
+          (is (= 4 @ran)))))))
+
+(deftest test-return-class-fn
+  (when isClient
+    (let [ran (atom 0)
+          top-ran (atom 0)
+          comp (fn []
+                 (swap! top-ran inc)
+                 (reagent/create-class
+                  {:component-did-mount #(swap! ran inc)
+                   :component-function
+                   (fn [p a]
+                     (is (= 1 a))
+                     (swap! ran inc)
+                     [:div (str "hi " (:foo p) ".")])}))
+          prop (atom {:foo "you"})
+          parent (fn [] [comp @prop 1])]
+      (with-mounted-component [parent]
+        (fn [C div]
+          (swap! ran inc)
+          (is (found-in #"hi you" div))
+          (is (= 1 @top-ran))
+          (is (= 3 @ran))
+
+          (swap! prop assoc :foo "me")
+          (reagent/flush)
+          (is (found-in #"hi me" div))
+          (is (= 1 @top-ran))
+          (is (= 4 @ran)))))))


acst to str

acst to str

--- src/ci3/build/core.clj
+++ src/ci3/build/core.clj
@@ -21,9 +21,9 @@
                       {:key "account" :path "account.json"}]}}]
    :containers
    [{:name "agent"
-     :image (or (System/getenv "AGENT_IMAGE")
-                (System/getenv "CI3_CONFIG_AGENT_IMAGE")
-                "healthsamurai/ci3:latest")
+     :image (str (or (System/getenv "CI3_CONFIG_AGENT_IMAGE")
+                     (System/getenv "AGENT_IMAGE")
+                     "healthsamurai/ci3:latest"))
      :imagePullPolicy "Always"
      :args ["agent"]
      :volumeMounts
@@ -51,7 +51,8 @@
     (when (and (= tp "ADDED") (= "pending" (:status build)))
       (log/info "Create build pod" (str "build-" nm))
       (let [pod (k8s/create cfg :pods
-                            {:kind "Pod"
+                            {:apiVersion "v1"
+                             :kind "Pod"
                              :metadata {:name (str "build-" nm)
                                         :annotations {:system "ci3"}
                                         :lables {:system "ci3"}}


Quicksand.

Quicksand.

--- src/clj/game/cards.clj
+++ src/clj/game/cards.clj
@@ -3258,9 +3258,10 @@
    {:abilities [{:msg "end the run" :effect (effect (end-run))}]}

    "Quicksand"
-   {:abilities [{:msg "add 1 power counter"
-                 :effect (effect (add-prop card :counter 1) (add-prop card :strength 1))}
-                {:msg "end the run" :effect (effect (end-run))}]}
+   {:events {:encounter-ice {:req (req (= (:cid target) (:cid card)))
+                             :effect (effect (add-prop card :counter 1))}}
+    :strength-bonus (req (or (:counter card) 0))
+    :abilities [{:msg "end the run" :effect (effect (end-run))}]}

    "Rainbow"
    {:abilities [{:msg "end the run" :effect (effect (end-run))}]}


fix Manhunt base

fix Manhunt base

--- src/clj/game/cards.clj
+++ src/clj/game/cards.clj
@@ -1056,7 +1056,7 @@
    {:effect (effect (gain :click 1 :click-per-turn 1))}

    "Manhunt"
-   {:events {:successful-run {:once :per-turn :trace {:base 3 :msg "give the Runner 1 tag"
+   {:events {:successful-run {:once :per-turn :trace {:base 2 :msg "give the Runner 1 tag"
                                                       :effect (effect (gain :runner :tag 1))}}}}

    "Marked Accounts"


Removed 'core' module not needed by the library

--- src/clj_flotr/core.clj
+++ src/clj_flotr/core.clj
@@ -1,7 +0,0 @@
-(ns clj-flotr.core
-  (:gen-class))
-
-(defn -main
-  "I don't do a whole lot ... yet."
-  [& args]
-  (println "Hello, World!"))


false! should return false, not true.

false! should return false, not true.

--- src/clojure/beckon.clj
+++ src/clojure/beckon.clj
@@ -18,4 +18,4 @@
   "Takes a function of no arguments, and returns a function taking no arguments
   which calls f and returns false. f has presumably side effects."
   [f]
-  (fn [] (f) true))
+  (fn [] (f) false))


Add random-insertion flag to random-plush-instruction-map

--- src/clojush/random.clj
+++ src/clojush/random.clj
@@ -42,30 +42,36 @@
   "Returns a random instruction map given the atom-generators and the required
    epigenetic-markers."
   ([atom-generators]
-    (random-plush-instruction-map atom-generators {}))
-  ([atom-generators {:keys [epigenetic-markers
-                            close-parens-probabilities
-                            silent-instruction-probability]
-                     :or {epigenetic-markers []
-                          close-parens-probabilities [0.772 0.206 0.021 0.001]
-                          silent-instruction-probability 0}}]
-    (let [markers (conj epigenetic-markers :instruction)]
-      (zipmap markers
-              (map (fn [marker]
-                     (case marker
-                       :instruction (let [element (lrand-nth atom-generators)]
-                                      (if (fn? element)
-                                        (let [fn-element (element)]
-                                          (if (fn? fn-element)
-                                            (fn-element)
-                                            fn-element))
-                                        element))
-                       :close (random-closes close-parens-probabilities)
-                       :silent (if (< (lrand) silent-instruction-probability)
-                                 true
-                                 false)
-                       ))
-                   markers)))))
+   (random-plush-instruction-map atom-generators {}))
+  ([atom-generators argmap]
+   (random-plush-instruction-map atom-generators false argmap))
+  ([atom-generators random-insertion {:keys [epigenetic-markers
+                                             close-parens-probabilities
+                                             silent-instruction-probability]
+                                      :or {epigenetic-markers []
+                                           close-parens-probabilities [0.772 0.206 0.021 0.001]
+                                           silent-instruction-probability 0}}]
+   (let [markers (concat epigenetic-markers
+                         (if random-insertion
+                           [:instruction :random-insertion]
+                           [:instruction]))]
+     (zipmap markers
+             (map (fn [marker]
+                    (case marker
+                      :instruction (let [element (lrand-nth atom-generators)]
+                                     (if (fn? element)
+                                       (let [fn-element (element)]
+                                         (if (fn? fn-element)
+                                           (fn-element)
+                                           fn-element))
+                                       element))
+                      :close (random-closes close-parens-probabilities)
+                      :silent (if (< (lrand) silent-instruction-probability)
+                                true
+                                false)
+                      :random-insertion true
+                      ))
+                  markers)))))

 (defn random-plush-genome-with-size
   "Returns a random Plush genome containing the given number of points."


(SERVER-882) Shorten bidi call line in valid-static-file-path?

--- src/clj/puppetlabs/services/master/master_core.clj
+++ src/clj/puppetlabs/services/master/master_core.clj
@@ -319,7 +319,8 @@
      ;; Here, keywords represent a single element in the path. Anything between two '/' counts.
      ;; The second vector takes anything else that might be on the end of the path.
      ;; Below, this corresponds to 'modules/*/files/**' in a filesystem glob.
-     (bidi.bidi/match-route [["modules/" :module-name "/files/" [#".*" :rest]] :_] canonicalized-path))))
+     (bidi.bidi/match-route [["modules/" :module-name "/files/" [#".*" :rest]] :_]
+                            canonicalized-path))))

 (defn static-file-content-request-handler
   "Returns a function which is the main request handler for the


Created initial footer component

Created initial footer component

--- src/cljs/org/broadinstitute/firecloud_ui/main.cljs
+++ src/cljs/org/broadinstitute/firecloud_ui/main.cljs
@@ -3,15 +3,20 @@
    [dmohs.react :as react]
    ))

+(defn footer []
+  (let [thisyear (.getFullYear (js/Date.))
+        startyear 2015
+        yeartext (if (= startyear thisyear) (str startyear) (str startyear "-" thisyear))]
+    [:div {:style {:padding-top "1em" :font-size 12}} (str "\u00A9 " yeartext " Broad Institute")]))

 (def App
   (react/create-class
    {:render
     (fn []
       [:div {:style {:padding "1em"}}
-       [:div {} [:img {:src "broad_logo.png" :style {:height 36}}]]
-        [:div {:style {:padding-top "1em"}} "Hello World!"]])}))
-
+        [:div {} [:img {:src "broad_logo.png" :style {:height 36}}]]
+        [:div {:style {:padding-top "1em"}} "Hello World!"]
+        (footer)])}))

 (defn ^:export render [element]
   (react/render (react/create-element App) element))


Commands: look-up added

Commands: look-up added

--- src/clojure/life/daemon/list_of_motor_commands.clj
+++ src/clojure/life/daemon/list_of_motor_commands.clj
@@ -11,3 +11,7 @@
 (defn look-down [amount time-in-ms]
   {1 [{:id 2 :amount (* -1 amount) :duration time-in-ms}]})

+
+(defn look-up [amount time-in-ms]
+  {1 [{:id 2 :amount  amount :duration time-in-ms}]})
+


Fix incorrect nesting from merge

Fix incorrect nesting from merge

Signed-off-by: Eric Baur <a1c9c5f8609c68027db0779b39e5f932d4cb0053@robeybaur.org>

--- src/obcc/core.clj
+++ src/obcc/core.clj
@@ -71,9 +71,9 @@
                         (do
                           (try
                             (func path config)
-                            (catch Exception e (println "error:" (:stderr (ex-data e))))))
-                          (exit 0 "done"))
-                        (exit 1 (usage summary)))))))))
+                            (catch Exception e (println "error:" (:stderr (ex-data e)))))
+                          (exit 0 ""))
+                        (exit 1 (usage summary))))))))))

 (defn -main [& args]
   (System/exit (apply -app args)))


Documents defmsg

Documents defmsg

--- src/expound/alpha.cljc
+++ src/expound/alpha.cljc
@@ -812,7 +812,13 @@
   [spec form]
   (print (expound-str spec form)))

-(defn defmsg [k error-message]
+(s/fdef defmsg
+        :args (s/cat :k qualified-keyword?
+                     :error-message string?)
+        :ret nil?)
+(defn defmsg
+  "Associates the spec named `k` with `error-message`."
+  [k error-message]
   (swap! registry-ref assoc k error-message)
   nil)

@@ -820,7 +826,7 @@
    (defmacro def
      "Define a spec with an optional error message.

-This is a replacement for `clojure.spec.alpha/def` but optionally takes a human-readable error message (will only be used for predicates) e.g. 'should be a string'"
+This is a replacement for `clojure.spec.alpha/def` but optionally takes a human-readable `error-message` (will only be used for predicates) e.g. 'should be a string'"
      ([k spec-form]
       `(s/def ~k ~spec-form))
      ([k spec-form error-message]


Try using wrap-protect-origins again

Try using wrap-protect-origins again

--- src/main/cawala/server_components/middleware.clj
+++ src/main/cawala/server_components/middleware.clj
@@ -102,7 +102,7 @@
       (wrap-api "/api")
       server/wrap-transit-params
       server/wrap-transit-response
-      #_(server/wrap-protect-origins {:allow-when-origin-missing? false
+      (server/wrap-protect-origins {:allow-when-origin-missing? true
                                     :legal-origins              legal-origins})
       (wrap-html-routes)
       ;; If you want to set something like session store, you'd do it against


Add dir/scan-all

Add dir/scan-all

--- src/main/clojure/clojure/tools/namespace/dir.clj
+++ src/main/clojure/clojure/tools/namespace/dir.clj
@@ -48,7 +48,7 @@
                 (Pattern/compile (Pattern/quote File/pathSeparator))))))

 (defn scan
-  "Scan directories for files which have changed since the last time
+  "Scans directories for files which have changed since the last time
   'scan' was run; update the dependency tracker with
   new/changed/deleted files.

@@ -61,3 +61,13 @@
     (if (or deleted modified)
       (update-files tracker deleted modified)
       tracker)))
+
+(defn scan-all
+  "Scans directories for all Clojure source files and updates the
+  dependency tracker to reload files. If no dirs given, defaults to
+  all directories on the classpath."
+  [tracker & dirs]
+  (let [ds (or (seq dirs) (dirs-on-classpath))
+        files (find-files ds)
+        deleted (seq (deleted-files tracker files))]
+    (update-files tracker deleted files)))


fixed clear songs

fixed clear songs

--- src/frontend/core.cljs
+++ src/frontend/core.cljs
@@ -283,6 +283,8 @@
   (fn []
     (println "Received clear-songs signal")
     (player/destroy-track (:current-sound-id @app-state))
+    (swap! app-state assoc :track-id-hashes {})
+    (swap! app-state assoc :track-order [])
     (swap! app-state assoc :music-info [])
     (swap! app-state assoc :current-track-id nil)
     (swap! app-state assoc :current-sound-id nil)))


Add randomized test case for learn-implications-by-queries

Signed-off-by: Daniel Borchmann <3d0f3b9ddcacec30c4008c5e030e6c13a478cb4f@algebra20.de>

--- src/test/clojure/conexp/fca/implications_test.clj
+++ src/test/clojure/conexp/fca/implications_test.clj
@@ -400,7 +400,14 @@
                                            (membership-oracle-by-implications background-hypothesis)
                                            (equivalence-oracle-by-implications background-hypothesis)))
            #{(make-implication '#{a b} '#{c d})
-             (make-implication '#{a c} '#{d})}))))
+             (make-implication '#{a c} '#{d})})))
+  (with-testing-data [ctx (random-contexts 10 15)]
+    (let [base (canonical-base ctx)]
+      (equivalent-implications?
+       base
+       (learn-implications-by-queries (attributes ctx)
+                                      (membership-oracle-by-implications base)
+                                      (equivalence-oracle-by-implications base))))))

 ;;;


desc tweak

desc tweak

--- .desc.clj
+++ .desc.clj
@@ -54,7 +54,7 @@
  {:name "clojure.zip/zipper",
   :desc "[children? children create-branch]"}
  {:name "clojure.core/partition",
-  :desc "similar to enum chunking meth"}
+  :desc "useful for converting flat list/vec to sublists/subvecs"}
  {:name "clojure.core/with-meta", :desc "replace meta"}
  {:name "clojure.core/vary-meta", :desc "assoc meta"}
  {:name "clojure.core/subseq",


more script fixes

more script fixes

--- dev/strictly_specking_tasks/core.clj
+++ dev/strictly_specking_tasks/core.clj
@@ -49,19 +49,16 @@
         add-newline)))

 (defn standalone []
-  (fix-spec-requires (partial fix-spec-require-in-file standalone))
+  (fix-spec-requires (partial fix-spec-require-in-file standalone-spec-require))
   (output-spec-shim))

 (defn with-clojure-spec []
   (fix-spec-requires (partial fix-spec-require-in-file fix-spec-require))
-  (.delete (io/file "src/strictly_specking/spec.clj"))
-  )
-
-
+  (.delete (io/file "src/strictly_specking/spec.clj")))

 (comment
   (with-clojure-spec)
-  (fix-spec-requires)
+  (standalone)
   (fix-spec-require-in-file (io/file "src/strictly_specking/core.clj"))
   (fix-spec-require "   [clojure.spec :as s]")

@@ -76,5 +73,7 @@

 (defn -main [command & args]
   (condp = command
-    ":standalone" (standalone)))
+    ":standalone" (standalone)
+    ":with-clojure-spec" (with-clojure-spec))
+  )


move from using om/transact! to regular swap!

--- src/leftover/core.cljs
+++ src/leftover/core.cljs
@@ -45,22 +45,24 @@
                ))))

 (defn enter-payment [app owner]
-  (reify om/IRenderState
-    (render-state [this {:keys [actions]}]
-      (dom/div {:class "col-sm-6 component"}
-               (dom/form
-                 (obi/input {:type "text" :placeholder "Location"})
-                 (obi/input {:type "text" :placeholder "Amount"})
-                 (obb/button-group {:justified? true}
-                                 (obb/button-group {} (obb/button { :bs-style "success" :on-click (fn [] (put! actions {:type "add-payment"})) } "Add"))))))))
+  (reify om/IRender
+    (render [this]
+      (let [actions (om/get-shared owner :actions)]
+        (dom/div {:class "col-sm-6 component"}
+                 (dom/form
+                   (obi/input {:type "text" :placeholder "Location"})
+                   (obi/input {:type "text" :placeholder "Amount"})
+                   (obb/button-group {:justified? true}
+                                     (obb/button-group {} (obb/button { :bs-style "success" :on-click (fn [] (put! actions {:type "add-payment"})) } "Add")))))))))

 (defn button-bar [app owner]
-  (reify om/IRenderState
-    (render-state [this {:keys [actions]}]
-      (dom/div {:class "col-sm-6 component"}
-               (obb/button-group {:justified? true}
-                                 (obb/button-group {} (obb/button { :bs-style "primary" :on-click (fn [] (put! actions {:type "enter-payment"})) } "Enter Payment"))
-                                 (obb/button-group {} (obb/button { :bs-style "primary" :on-click (fn [] (put! actions {:type "view-history"})) } "View History")))))))
+  (reify om/IRender
+    (render [this]
+      (let [actions (om/get-shared owner :actions)]
+        (dom/div {:class "col-sm-6 component"}
+                 (obb/button-group {:justified? true}
+                                   (obb/button-group {} (obb/button { :bs-style "primary" :on-click (fn [] (put! actions {:type "enter-payment"})) } "Enter Payment"))
+                                   (obb/button-group {} (obb/button { :bs-style "primary" :on-click (fn [] (put! actions {:type "view-history"})) } "View History"))))))))

 (defn running-total [app owner]
   (reify om/IRender
@@ -69,31 +71,27 @@
                (str "Current Total: " (apply - (:start-amount app) (map :amount (:previous-payments app))))))))

 (defn main-view [app owner]
-  (reify
-    om/IInitState
-    (init-state [_]
-      {:actions (chan)})
-    om/IWillMount
-    (will-mount [_]
-      (let [actions (om/get-state owner :actions)]
-        (go (loop []
-              (let [action (<! actions)]
-                (case (:type action)
-                  "enter-payment" (om/transact! app :state (fn [_] "enter-payment"))
-                  "view-history" (om/transact! app :state (fn [_] "view-history"))
-                  "add-payment" (.log js/console "add")
-                  )
-                (recur))))))
-    om/IRenderState
-    (render-state [this {:keys [actions]}]
+  (reify om/IRender
+    (render [this]
       (dom/div
         (om/build running-total app)
-        (om/build button-bar app {:init-state {:actions actions}})
+        (om/build button-bar app)
         (case (:state app)
-          "enter-payment" (om/build enter-payment app {:init-state {:actions actions}})
+          "enter-payment" (om/build enter-payment app)
           "view-history" (om/build view-history app))))))
+
+(def actions (chan))
+
+(go (loop []
+      (let [action (<! actions)]
+        (case (:type action)
+          "enter-payment" (swap! app-state assoc :state "enter-payment")
+          "view-history" (swap! app-state assoc :state "view-history")
+          "add-payment" (.log js/console "add"))
+        (recur))))

 (om/root
   main-view
   app-state
-  {:target (. js/document (getElementById "app"))})
+  {:target (. js/document (getElementById "app"))
+   :shared {:actions actions}})


Add git tree facts to Datomic exploration.

--- src/leiningen/voom.clj
+++ src/leiningen/voom.clj
@@ -91,6 +91,9 @@
     ::dt/string ::c/one]
    [:branch/tip "Commit this branch is currently pointing to"
     ::dt/ref ::c/one]
+
+   [:node/name-sha "A concatenation of the name and the sha for upsert."
+    ::dt/string ::c/one :db.unique/identity]

    ;; lein version stuff
    [:project-node/version "Lein semantic version declared in this project.clj"
@@ -1168,9 +1171,25 @@
                                    :let [pid (d/tempid :db.part/user)]]
                                [[:db/add pid :git/type :commit]
                                 [:db/add pid :git/sha p]
-                                [:db/add id :commit/parents pid]])))))]
-    @(d/transact conn stxn)
-    @(d/transact conn txn)
+                                [:db/add id :commit/parents pid]])))))
+        trees (git-trees gitdir (all-git-trees gitdir))
+        ttxn (apply concat
+                    (for [[tsha entries] trees
+                          [fname {:keys [sha ftype]}] entries
+                          :let [[tid nid oid fid]
+                                , (repeatedly #(d/tempid :db.part/user))]]
+                      [[:db/add tid :git/sha tsha]
+                       [:db/add tid :git/type :tree]
+                       [:db/add tid :tree/nodes nid]
+                       [:db/add nid :node/name-sha (str tsha "-" fname)]
+                       [:db/add nid :node/object oid]
+                       [:db/add nid :node/filename fid]
+                       [:db/add fid :file/name fname]
+                       [:db/add oid :git/sha sha]
+                       [:db/add oid :git/type (keyword ftype)]]))]
+    (time @(d/transact conn stxn))
+    (time @(d/transact conn txn))
+    (time @(d/transact conn ttxn))
     :done))

 (def subtasks [#'build-deps #'deploy #'find-box #'freshen #'install


london upd

london upd

--- src/lights/my_show.clj
+++ src/lights/my_show.clj
@@ -50,6 +50,25 @@
               (chan/color 3 :blue)]
    :name "Simple RGB"})

+(defn rgbd-simple
+  "A simple RGBD from London pub"
+  []
+  {:channels [(chan/color 1 :red)
+              (chan/color 2 :green)
+              (chan/color 3 :blue)
+              (chan/functions :dimmer 4)]
+    })
+
+(defn rgbw-simple
+  "A simple RGBW from London pub"
+  []
+  {:channels [(chan/color 1 :red)
+              (chan/color 2 :green)
+              (chan/color 3 :blue)
+              (chan/color 4 :white)]
+    })
+
+
 (defn use-my-show
   "Set up the show on the OLA universes it actually needs."
   []
@@ -65,7 +84,7 @@
       ;;       your show needs to use if they are different than
       ;;       just universe 1, as below, and change the description
       ;;       to something descriptive and in your own style:
-      (show/show :universes [1] :description "Deepower"))))
+      (show/show :universes [1] :description "Accuraten"))))

   (show/patch-fixture! :back-1 (simple-rgbd) 1 1 :x 1)
   (show/patch-fixture! :back-2 (simple-rgbd) 1 5 :x 2)
@@ -76,7 +95,32 @@
   ;; all the expanded, patched fixtures in it.
   '*show*)

-(use-my-show)  ; Set up my show as the default show, using the function above.
+(defn use-london-show
+  "Show for the London club"
+  []
+  (set-default-show!
+    (swap! my-show (fn [s]
+      (when s
+        (show/unregister-show s)
+        (with-show s (show/stop!)))
+      ;; TODO: Edit this to list the actual OLA universe(s) that
+      ;;       your show needs to use if they are different than
+      ;;       just universe 1, as below, and change the description
+      ;;       to something descriptive and in your own style:
+      (show/show :universes [1] :description "London"))))
+
+  (show/patch-fixture! :front-1 (rgbd-simple) 1 1   :x 2)
+  (show/patch-fixture! :front-2 (rgbd-simple) 1 17  :x 3.5)
+
+  (show/patch-fixture! :scene-1 (rgbw-simple) 1 33  :x 0)
+
+  ;; Return the show's symbol, rather than the actual map, which gets huge with
+  ;; all the expanded, patched fixtures in it.
+  '*show*)
+
+;(use-my-show)  ; Set up my show as the default show, using the function above.
+
+(use-london-show)

 (defn global-color-effect
   "Make a color effect which affects all lights in the sample show.
@@ -154,6 +198,16 @@
   [beat-ratio]
   (let [light-param (params/build-oscillated-param
     (oscillators/sawtooth-beat :beat-ratio beat-ratio :down? true) :max :max-lightness)]
+    (show/add-effect! :color (global-color-effect
+      (params/build-color-param :h :main-hue :s 100 :l light-param)))
+  )
+)
+
+(defn light-sine
+  "Change light according to sine osc"
+  [beat-ratio]
+  (let [light-param (params/build-oscillated-param
+    (oscillators/sine-beat :beat-ratio beat-ratio :down? true) :max :max-lightness)]
     (show/add-effect! :color (global-color-effect
       (params/build-color-param :h :main-hue :s 100 :l light-param)))
   )


Get environment vars at runtime

Get environment vars at runtime

--- src/mbeanz/handler.clj
+++ src/mbeanz/handler.clj
@@ -3,26 +3,26 @@
   (:require [compojure.route :as route]
             [ring.middleware.defaults :refer [wrap-defaults api-defaults]]
             [ring.middleware.json :refer [wrap-json-response]]
-            [ring.middleware.logger :refer [wrap-with-logger]]
             [compojure.core :refer :all]
             [mbeanz.core :refer :all]
             [mbeanz.common :refer :all]
             [environ.core :refer [env]]
             [clojure.java.jmx :as jmx]
-            [ring.adapter.jetty :refer [run-jetty]]))
+            [ring.adapter.jetty :refer [run-jetty]])
+  (:import java.lang.management.ManagementFactory))

-(def object-pattern (env :mbeanz-object-pattern))
+(def object-pattern (delay (or (env :mbeanz-object-pattern) "*:*")))

-(def jmx-remote-host (env :mbeanz-jmx-remote-host))
+(def jmx-remote-host (delay (or (env :mbeanz-jmx-remote-host) "localhost")))

-(def jmx-remote-port (Integer/parseInt (env :mbeanz-jmx-remote-port)))
+(def jmx-remote-port (delay (or (Integer/parseInt (env :mbeanz-jmx-remote-port)) 11080)))

 (defn- identifier-string [identifiers]
   (map #(str (:bean %) " " (stringify (:operation %))) identifiers))

 (defn- handle-describe [operation]
   (fn [request]
-    (jmx/with-connection {:host jmx-remote-host :port jmx-remote-port}
+    (jmx/with-connection {:host @jmx-remote-host :port @jmx-remote-port}
       (let [mbean (get-in request [:params :bean])
             op (keyword operation)]
         {:body (hash-map :description (doall (describe mbean op))
@@ -30,7 +30,7 @@

 (defn- handle-invoke [operation]
   (fn [request]
-    (jmx/with-connection {:host jmx-remote-host :port jmx-remote-port}
+    (jmx/with-connection {:host @jmx-remote-host :port @jmx-remote-port}
       (let [mbean (get-in request [:params :bean])
             args (get-in request [:params :args])]
         (if (string? args)
@@ -39,8 +39,8 @@

 (defn- handle-list-beans []
   (fn [request]
-    (jmx/with-connection {:host jmx-remote-host :port jmx-remote-port}
-      (identifier-string (doall (list-beans object-pattern))))))
+    (jmx/with-connection {:host @jmx-remote-host :port @jmx-remote-port}
+      (identifier-string (doall (list-beans @object-pattern))))))

 (defroutes app-routes
   (GET "/list" [] (handle-list-beans))
@@ -50,7 +50,6 @@

 (def app
   (-> app-routes
-      (wrap-with-logger)
       (wrap-json-response)
       (wrap-defaults api-defaults)))


Add test for pathom connect graphql `tempid?` config.

--- test/com/wsscode/pathom/connect/graphql2_test.cljc
+++ test/com/wsscode/pathom/connect/graphql2_test.cljc
@@ -4,7 +4,9 @@
             [com.wsscode.pathom.core :as p]
             [com.wsscode.pathom.connect :as pc]
             [com.wsscode.pathom.connect.graphql2 :as pcg]
-            [com.wsscode.pathom.graphql :as pg]))
+            [com.wsscode.pathom.graphql :as pg]
+            [clojure.string :as str]
+            [fulcro.client.primitives :as fp]))

 (def query-root-type
   (pcg/normalize-schema
@@ -370,9 +372,17 @@
                            [:clientMutation {:starrable [:viewerHasStarred]}]}]
       {})))

+(defn- normalize-query-whitespace [s]
+  (str/trim (str/replace s #"\s+" " ")))
+
 (deftest test-query->graphql
-  (is (= (pcg/query->graphql [{:credit-card [:number]}] {::pcg/demung pg/camel-case})
-         "query {\n  creditCard {\n    number\n  }\n}\n")))
+  (are [query out] (= (normalize-query-whitespace query) out)
+
+    (pcg/query->graphql [{:credit-card [:number]}] {::pcg/demung pg/camel-case})
+    "query { creditCard { number } }"
+
+    (pcg/query->graphql [(list 'call {:id (fp/tempid) :param "value"})] {::pcg/tempid? fp/tempid?})
+    "mutation { call(param: \"value\") { id} }"))

 (defn q [query]
   (p/query->ast1 [query]))


better uberkey specification for denormalization

--- test/er_cassandra/model/alia/relationship_test.clj
+++ test/er_cassandra/model/alia/relationship_test.clj
@@ -92,11 +92,12 @@
                     "(idb uuid primary key, value int)")

    (tu/create-table :tpr_target
-                    (str "(idt uuid primary key, "
+                    (str "(idt uuid, "
                          " source_a_id uuid, "
                          " source_b_id uuid, "
                          " factor int, "
-                         " value int)"))
+                         " value int, "
+                         " primary key ((source_a_id, source_b_id, idt)))"))

    (tu/create-table :tpr_target_by_source_a_id
                     (str "(idt timeuuid, "
@@ -117,7 +118,7 @@

    (let [target (t/create-entity
                  {:primary-table {:name :tpr_target
-                                  :key [:idt]}
+                                  :key [[:source_a_id :source_b_id :idt]]}
                   :secondary-tables [{:name :tpr_target_by_source_a_id
                                       :key [:source_a_id :idt]}
                                      {:name :tpr_target_by_source_b_id
@@ -143,13 +144,13 @@
 (deftest update-two-sources-many-records-test
   (let [[sa sb t] (create-two-source-relationship :none)

-        acnt 10
+        acnt 1
         ;; all source-a records start out with :factor 1
         saids (repeatedly acnt uuid/v1)
         sars (for [said saids] {:ida said :factor 1})

-        bcnt 100
+        bcnt 10
         ;; initial source-b record :values are drawn from 1..bcnt
         sbids (repeatedly bcnt uuid/v1)
         sbrs (map (fn [sbid v] {:idb sbid :value v}) sbids (iterate inc 1))


Improved countdown timer logic.

Improved countdown timer logic.

--- src/cljs/wombats_web_client/components/countdown_timer.cljs
+++ src/cljs/wombats_web_client/components/countdown_timer.cljs
@@ -31,12 +31,6 @@
   [start-time]
   (< 0 (seconds-until start-time)))

-(defn- clear-timers [cmpnt-state]
-  (let [{:keys [interval-fn timeout-fn]} @cmpnt-state]
-    (.clearTimeout js/window timeout-fn)
-    (.clearInterval js/window interval-fn))
-  (swap! cmpnt-state assoc :update-time-counter 0))
-
 (defn- format-time
   [time cmpnt-state]
   (let [seconds-left (seconds-until time)]
@@ -53,42 +47,24 @@
             minutes-formatted (str (when (< minutes-adjusted 10) "0") minutes-adjusted)]
         (str (when (> hours 0) (str hours ":")) minutes-formatted ":" seconds-formatted))

-      ;; set to 0 time
+      ;; set to 0 time
       "0:00")))

 (defn countdown-timer
   [start-time]

-  (let [cmpnt-state (reagent/atom {:interval-fn nil
-                                   :timeout-fn nil
-                                   :update-time-counter 0})
-        swap-interval-fn! (fn []
-                            (swap! cmpnt-state
-                                   assoc
-                                   :interval-fn
-                                   (.setInterval js/window
-                                                 ;; update state to trigger rerender
-                                                 #(swap! cmpnt-state update-in [:update-time-counter] inc)
-                                                 1000)))
-        swap-timeout-fn! (fn []
-                           (swap! cmpnt-state
-                                  assoc
-                                  :timeout-fn
-                                  (.setTimeout js/window
-                                               swap-interval-fn!
-                                               ;; Give the browser some extra time to render the next second
-                                               (- (millis-until start-time) 100))))]
+  (let [cmpnt-state (reagent/atom {:update nil})]
     (reagent/create-class
-     {:component-will-mount
-      ;; Force timer to redraw every second, start interval when the countdown timer should switch
-      #(swap-timeout-fn!)
-
-      :component-will-unmount #(clear-timers cmpnt-state)
-
-      :reagent-render
+     {:reagent-render
       (fn [start-time]
+        ;; Force timer to redraw every second
+        (if (time-left? start-time)
+          (.setTimeout js/window
+                       #(swap! cmpnt-state update-in [:update] not)
+                       1000))
+
         ;; triggers a rerender for active timers, will not affect timers with no interval timer
-        (:update-counter @cmpnt-state)
+        (:update @cmpnt-state)

         [:span {:class-name "countdown-timer"}
          (format-time start-time cmpnt-state)])})))


Hide output when testing

Hide output when testing

--- test/clojars/test/unit/tools/remove_deletions.clj
+++ test/clojars/test/unit/tools/remove_deletions.clj
@@ -20,7 +20,8 @@
     (.mkdirs (.getParentFile local-file))
     (io/copy file local-file)
     (with-redefs [connect (constantly conn)]
-      (-main (.getAbsolutePath repo) "test" "xx" "yy"))
+      (with-out-str
+        (-main (.getAbsolutePath repo) "test" "xx" "yy")))
     (is (cf/artifact-exists? conn "foo/bar/baz.jar"))
     (is (not (cf/artifact-exists? conn "boo/far/baz.jar")))))

@@ -35,7 +36,8 @@
         (.mkdirs (.getParentFile local-file))
     (io/copy file local-file)
     (with-redefs [connect (constantly conn)]
-      (-main (.getAbsolutePath repo) "test" "xx" "yy" "foo"))
+      (with-out-str
+        (-main (.getAbsolutePath repo) "test" "xx" "yy" "foo")))
     (is (cf/artifact-exists? conn "foo/bar/baz.jar"))
     (is (cf/artifact-exists? conn "boo/far/baz.jar"))
     (is (not (cf/artifact-exists? conn "foo/far/baz.jar")))))


Add a test that demonstrates how to map entries are deleted

Fixes #82.

--- test/clojurewerkz/cassaforte/collections_test.clj
+++ test/clojurewerkz/cassaforte/collections_test.clj
@@ -111,6 +111,18 @@
          (is (= {"a" "b" "c" "d"} (get-in (select s :users_map)
                                           [0 :test_map])))
          (truncate s :users_map)))
+
+      (testing "Deleting"
+        (th/test-combinations
+         (insert s :users_map
+                 {:name "user1"
+                  :test_map {"a" "b" "c" "d"}})
+         (delete s :users_map
+                 (columns {:test_map "c"})
+                 (where [[= :name "user1"]]))
+         (is (= {"a" "b"} (get-in (select s :users_map)
+                                  [0 :test_map])))
+         (truncate s :users_map)))
       (drop-table s :users_map))


(maint) Remove 'install-terminus-into' from integration tests

We can work around this by:
- Pointing the MRI agent at our terminus using --vardir
- Copying the puppetdb_query function into the master codedir when starting
  puppetserver

--- test/puppetlabs/puppetdb/integration/fixtures.clj
+++ test/puppetlabs/puppetdb/integration/fixtures.clj
@@ -195,20 +195,6 @@
        (map :file)
        last))

-(defn install-terminus-into [puppet-dir]
-  ;; various pieces of the terminus have to actually be inside of puppet itself to work
-  (let [base-dir "puppet"
-        base-uri (.toURI (io/file base-dir))
-        terminus-files (->> (fs/find-files base-dir #".*")
-                            (filter #(.isFile %))
-                            (map #(-> (.relativize base-uri (.toURI %))
-                                      .getPath)))]
-    (doseq [relative-path terminus-files]
-      (let [in (str base-dir "/" relative-path)
-            out (str puppet-dir "/" relative-path)]
-        (println "Copying puppetdb terminus file" in "to" out)
-        (fs/copy+ in out)))))
-
 (defn puppet-server-config-with-name [node-name]
   {:main {:certname "localhost"}
    :agent {:server "localhost"}
@@ -232,14 +218,20 @@
   (let [puppetdb-conf (io/file "target/puppetserver/master-conf/puppetdb.conf")
         puppet-conf (io/file "target/puppetserver/master-conf/puppet.conf")
         {puppetserver-config-overrides :puppetserver
-         terminus-config-overrides :terminus} config-overrides]
+         terminus-config-overrides :terminus} config-overrides
+        env-dir "target/puppetserver/master-code/environments/production"]
     (fs/copy-dir "test-resources/puppetserver/ssl" "./target/puppetserver/master-conf/ssl")
     (-> puppet-conf .getParentFile .mkdirs)
     (spit (.getAbsolutePath puppet-conf) "")
     (ks/spit-ini puppet-conf (puppet-server-config-with-name node-name))
-    (fs/mkdirs "target/puppetserver/master-code/environments/production/modules")
-
-    (install-terminus-into (jruby-agent-dir))
+    (fs/mkdirs (str env-dir "/modules"))
+
+    ;; copy our custom puppet functions into the code-dir, since puppet can't
+    ;; find them in the ruby load path
+    (let [functions-dir (str env-dir "/lib/puppet/functions")]
+      (fs/mkdirs functions-dir)
+      (fs/copy-dir-into "puppet/lib/puppet/functions/" functions-dir))
+
     (write-puppetdb-terminus-config pdb-servers puppetdb-conf terminus-config-overrides))

   (let [services (tk-bootstrap/parse-bootstrap-config! dev-bootstrap-file)
@@ -310,27 +302,28 @@
               (assoc opts :certname certname)))

 (defn run-puppet-node-deactivate [pdb-server certname-to-deactivate]
-  (install-terminus-into (mri-agent-dir))
   (with-synchronized-command-processing pdb-server 1 tu/default-timeout-ms
     (bundle-exec {}
                  "puppet" "node" "deactivate"
                  "--confdir" "target/puppetserver/master-conf"
                  "--color" "false"
+                 "--vardir" "puppet"
                  certname-to-deactivate)))

 (defn run-puppet-node-status [pdb-server certname]
-  (install-terminus-into (mri-agent-dir))
   (bundle-exec {}
                "puppet" "node" "status" certname
                "--confdir" "target/puppetserver/master-conf"
-               "--color" "false"))
+               "--color" "false"
+               "--vardir" "puppet"))

 (defn run-puppet-facts-find [puppet-server certname]
   (let [{:keys [conf-dir]} (server-info puppet-server)]
     (-> (bundle-exec {}
                      "puppet" "facts" "find" certname
                      "--confdir" conf-dir
-                     "--terminus" "puppetdb")
+                     "--terminus" "puppetdb"
+                     "--vardir" "puppet")
         :out
         json/parse-string)))

@@ -346,8 +339,6 @@
          timeout tu/default-timeout-ms}
     :as opts}]

-  (install-terminus-into (mri-agent-dir))
-
   (let [agent-conf-dir (io/file "target/puppet-apply-conf")
         manifest-file  (fs/temp-file "manifest" ".pp")
         puppet-conf-file (io/file (str agent-conf-dir "/puppet.conf"))]
@@ -381,6 +372,7 @@
       (apply bundle-exec env
              "puppet" "apply" (.getCanonicalPath manifest-file)
              "--confdir" (.getCanonicalPath agent-conf-dir)
+             "--vardir" "puppet"
              extra-puppet-args))))

 (def date-formatter (tfmt/formatters :date-time))


clean up example

clean up example

--- env/dev/cljs/reagent_slider/dev.cljs
+++ env/dev/cljs/reagent_slider/dev.cljs
@@ -19,14 +19,13 @@
         model (reagent/atom {:min 2 :max 3})]

     (reagent/render [:div {:style {:width 290}}
+
+                     [:button {:on-click #(reset! model {:min 1 :max 5})} "switch!"]
+
                      [core/tooltipped-range-component
                       {:min 0
                        :max (dec (count index->time))
-                       ;; this doesn't work, not sure why. You'd think it wouldn't rerender
-                       ;; until after you let go and the value is set, but that's not so. Instead
-                       ;; it locks the handles in place, as if it rerendered right away...
-                       ;;:value [(:min @model) (:max @model)]
-                       :defaultValue [2 3]
+                       :defaultValue [(:min @model) (:max @model)]
                        :marks index->time
                        :onAfterChange (fn [[v1 v2]]
                                         (reset! model {:min (min v1 v2)


Resizeable bar top edge bugfix

Resizeable bar top edge bugfix

--- flatguiwidgets/src/flatgui/widgets/resizeablebar.clj
+++ flatguiwidgets/src/flatgui/widgets/resizeablebar.clj
@@ -47,7 +47,7 @@
                     (m/x old-clip-size)
                     (do ;(println " (get-mouse-y component) " (float (get-mouse-y component)) " (:y mce) " (float (:y mce)))
                       (+ (m/y (:clip-size mce)) (- (mouse/get-mouse-y component) (:y mce)))))
-          :bottom (m/defpoint
+          :top (m/defpoint
                     (m/x old-clip-size)
                     (do ;(println " (get-mouse-y component) " (float (get-mouse-y component)) " (:y mce) " (float (:y mce)))
                       (+ (m/y (:clip-size mce)) (max 0 (- (mouse/get-mouse-y component) (:y mce))))))


pace is set to ex, when the exercise is created

--- src/ontrail/mutate.clj
+++ src/ontrail/mutate.clj
@@ -11,14 +11,22 @@

 (def #^{:private true} logger (org.slf4j.LoggerFactory/getLogger (str *ns*)))

+(defn calc-pace [duration distance]
+    (try
+      (int (Math/round (* (/ distance  duration) 360000.0)))
+    (catch Exception exception
+      (.info logger (str exception " with " duration distance))
+      nil)))
+
 (defn from-user-ex [user user-ex]
   (let [now (time/now)
         creation-date (parse-date (:date user-ex))
         last-modified (if (> (time/in-minutes (time/interval (parse-date (:date user-ex)) (time/plus now (time/days 1)))) 43200)
                         creation-date
                         now)
+        duration (parse-duration (:duration user-ex))
         bare-ex {:title (:title user-ex)
-                 :duration (parse-duration (:duration user-ex))
+                 :duration duration
                  :sport (:sport user-ex)
                  :creationDate creation-date
                  :lastModifiedDate last-modified
@@ -26,13 +34,15 @@
         body (if (nil? (:body user-ex)) "" (:body user-ex))
         tags (parse-tags (:tags user-ex))
         avghr (parse-natural (:avghr user-ex))
-        distance (parse-distance (:distance user-ex))]
+        distance (parse-distance (:distance user-ex))
+        pace (calc-pace duration distance)]
     (-> bare-ex
         (assoc :body body)
         (assoc :tags tags)
         (assoc :distance distance)
         (assoc :avghr avghr)
-        (assoc :comments '()))))
+        (assoc :comments '())
+        (assoc :pace pace))))

 (defn delete-ex [user ex-id]
   (.trace logger (str "deleting " user " ex " ex-id))


add a poorly done scale to the users graph

--- src/pc/views/admin.clj
+++ src/pc/views/admin.clj
@@ -7,6 +7,11 @@
             [pc.models.cust :as cust-model]
             [ring.util.anti-forgery :as anti-forgery]))

+(defn count-users [db time]
+  (count (seq (d/datoms (d/as-of db (clj-time.coerce/to-date time))
+                        :avet
+                        :cust/email))))
+
 (defn users-graph []
   (let [db (pcd/default-db)
         now (time/now)
@@ -15,24 +20,51 @@
         times (take-while #(time/before? % (time/plus now (time/days 1)))
                           (iterate #(clj-time.core/plus % (clj-time.core/days 1))
                                    earliest))
-        count-users (fn [time] (count (seq (d/datoms (d/as-of db (clj-time.coerce/to-date time))
-                                                     :avet
-                                                     :cust/email))))
+        user-counts (map (partial count-users db) times)
+        users-per-day (map (fn [a b] (- b a)) (cons 0 user-counts) user-counts)
         width 1000
         height 500
-        max-users (count-users now)
         x-tick-width (/ 1000 (count times))
-        y-tick-width (/ 500 (+ max-users (* 0.10 max-users)))
+
+        max-users-per-day (apply max users-per-day)
+        y-tick-width (/ 500 (+ max-users-per-day (* 0.10 max-users-per-day)))
+
+        max-users (apply max user-counts)
+        y-cumulative-tick-width (/ 500 (+ max-users (* 0.10 max-users)))
         padding 20]
-    [:svg {:width "100%" :height "100%"}
-     [:rect {:x 20 :y 20 :width 1000 :height 500
-             :fill "none" :stroke "black"}]
-     (map-indexed (fn [i time]
-                    [:circle {:cx (+ padding (* x-tick-width i))
-                              :cy (+ padding (- 500 (* y-tick-width (count-users time))))
-                              :r 5
-                              :fill "blue"}])
-                  times)]))
+    (list
+     [:svg {:width 1200 :height 600}
+      [:rect {:x 20 :y 20 :width 1000 :height 500
+              :fill "none" :stroke "black"}]
+      (for [i (range 0 (inc 500) 25)]
+        (list
+         [:line {:x1 padding :y1 (+ padding i)
+                 :x2 (+ padding 1000) :y2 (+ padding i)
+                 :strokeWidth 1 :stroke "black"}]
+         [:text {:x 0 :y (+ padding i)}
+          (- max-users-per-day (int (* i (/ max-users-per-day 500))))]))
+      (map-indexed (fn [i user-count]
+                     [:circle {:cx (+ padding (* x-tick-width i))
+                               :cy (+ padding (- 500 (* y-tick-width user-count)))
+                               :r 5
+                               :fill "blue"}])
+                   users-per-day)]
+     [:svg {:width 1200 :height 600}
+      [:rect {:x 20 :y 20 :width 1000 :height 500
+              :fill "none" :stroke "black"}]
+      (for [i (range 0 (inc 500) 25)]
+        (list
+         [:line {:x1 padding :y1 (+ padding i)
+                 :x2 (+ padding 1000) :y2 (+ padding i)
+                 :strokeWidth 1 :stroke "black"}]
+         [:text {:x 0 :y (+ padding i)}
+          (- max-users (int (* i (/ max-users 500))))]))
+      (map-indexed (fn [i user-count]
+                     [:circle {:cx (+ padding (* x-tick-width i))
+                               :cy (+ padding (- 500 (* y-cumulative-tick-width user-count)))
+                               :r 5
+                               :fill "blue"}])
+                   user-counts)])))

 (defn early-access-users []
   (let [db (pcd/default-db)