~severeoverfl0w/ring-graph

870cbc695313cad44ee028961e2f9dc419480b02 — Dominic Monroe 2 years ago e7607df
Save graph as png after run
1 files changed, 2 insertions(+), 0 deletions(-)

M src/io/dominic/ring_graph/core.clj
M src/io/dominic/ring_graph/core.clj => src/io/dominic/ring_graph/core.clj +2 -0
@@ 2,6 2,7 @@
  (:require
    [clojure.string :as string]
    [clojure.edn :as edn]
    [clojure.java.io :as jio]
    [hiccup2.core :as h]
    hiccup.page
    [com.hypirion.clj-xchart :as c]


@@ 144,6 145,7 @@
                              (-> old-state
                                  (assoc-in [:results [arg main]] (str (.getMessage e)))
                                  (assoc-in [:requests main arg] -100))))))))
          (c/spit (results-graph @state*) (doto (str "graphs/" (java.time.Instant/now) ".png") jio/make-parents))
          (finally
            (send-off state* assoc :running? false :done? true)))))
    (.start)))