diff --git a/project.clj b/project.clj index b70514a..8803ce4 100644 --- a/project.clj +++ b/project.clj @@ -1,4 +1,4 @@ -(defproject com.taoensso/timbre "4.10.0" +(defproject status-im/timbre "4.10.0-2-status" :author "Peter Taoussanis " :description "Pure Clojure/Script logging library" :url "https://github.com/ptaoussanis/timbre" diff --git a/src/taoensso/timbre.cljx b/src/taoensso/timbre.cljx index 2aab93e..bd02074 100644 --- a/src/taoensso/timbre.cljx +++ b/src/taoensso/timbre.cljx @@ -535,14 +535,19 @@ ;; NB waiting on CLJ-865: ?line (fline &form)}} opts - ?file (when (not= ?file "NO_SOURCE_PATH") ?file) + ?file (when-not (or (= ?file "NO_SOURCE_PATH") + (-> ?file + (str/split #"/") + last + (.startsWith "form-init"))) + ?file) ;; Identifies this particular macro expansion; note that this'll ;; be fixed for any fns wrapping `log!` (notably `tools.logging`, ;; `slf4j-timbre`, etc.): callsite-id (hash [level msg-type args ; Unevaluated args (arg forms) - ?ns-str ?file ?line (rand)])] + ?ns-str ?file ?line])] `(-log! ~config ~level ~?ns-str ~?file ~?line ~msg-type ~?err (delay [~@args]) ~?base-data ~callsite-id)))))