aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authors-ol <s-ol@users.noreply.github.com>2020-02-13 08:39:22 +0000
committers-ol <s-ol@users.noreply.github.com>2020-02-13 08:39:27 +0000
commitb2fba2961426fca8ac8efe37c0254dd7cd87d190 (patch)
treede000bc70c46639742f4b6803447b29bb37004c4
parentnew Registry tagging mechanism (diff)
downloadalive-b2fba2961426fca8ac8efe37c0254dd7cd87d190.tar.gz
alive-b2fba2961426fca8ac8efe37c0254dd7cd87d190.zip
better tracebacks
-rw-r--r--lib/osc.moon1
-rw-r--r--logger.moon5
2 files changed, 3 insertions, 3 deletions
diff --git a/lib/osc.moon b/lib/osc.moon
index 880cb08..dae6737 100644
--- a/lib/osc.moon
+++ b/lib/osc.moon
@@ -13,7 +13,6 @@ class out extends Op
setup: (@host, @port, @path, @value) =>
update: (dt) =>
- L\trace "updating #{@}"
for p in *{@host, @port, @path, @value}
L\push p\update, dt
diff --git a/logger.moon b/logger.moon
index 5175ad4..e1d6611 100644
--- a/logger.moon
+++ b/logger.moon
@@ -22,7 +22,8 @@ class Logger
where = debug.traceback '', 2
line = where\match '^.-\n%s+([%w:/%.]+): '
- line = line\match '[%./]*(.*)'
+ line = (line\match '[%./]*(.*)') or line
+ line = (line\match '^core/(.*)') or line
line ..= string.rep ' ', 20-#line
if level == levels.error or @level == levels.debug
@@ -38,7 +39,7 @@ class Logger
last = @prefix
@prefix ..= ' '
- res = { pcall fn, ... }
+ res = { xpcall fn, debug.traceback, ... }
@prefix = last