You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tinkerpop.apache.org by ok...@apache.org on 2016/05/03 16:22:00 UTC

[03/18] incubator-tinkerpop git commit: Better exception messaging on failure of -e.

Better exception messaging on failure of -e.


Project: http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/commit/1ed70437
Tree: http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/tree/1ed70437
Diff: http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/diff/1ed70437

Branch: refs/heads/TINKERPOP-1279
Commit: 1ed7043721214b04ebb278ae45503fc893f2b960
Parents: b6853f0
Author: Stephen Mallette <sp...@genoprime.com>
Authored: Thu Apr 28 14:01:53 2016 -0400
Committer: Stephen Mallette <sp...@genoprime.com>
Committed: Thu Apr 28 14:01:53 2016 -0400

----------------------------------------------------------------------
 .../org/apache/tinkerpop/gremlin/console/Console.groovy       | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/1ed70437/gremlin-console/src/main/groovy/org/apache/tinkerpop/gremlin/console/Console.groovy
----------------------------------------------------------------------
diff --git a/gremlin-console/src/main/groovy/org/apache/tinkerpop/gremlin/console/Console.groovy b/gremlin-console/src/main/groovy/org/apache/tinkerpop/gremlin/console/Console.groovy
index a35c44a..21ebc64 100644
--- a/gremlin-console/src/main/groovy/org/apache/tinkerpop/gremlin/console/Console.groovy
+++ b/gremlin-console/src/main/groovy/org/apache/tinkerpop/gremlin/console/Console.groovy
@@ -332,11 +332,14 @@ class Console {
                     lineNumber++
                     groovy.execute(line)
                 } catch (Exception ex) {
-                    io.err.println("Invalid line in $scriptFile at [$lineNumber: $line] - ${ex.message}")
+                    io.err.println("Error in $scriptFile at [$lineNumber: $line] - ${ex.message}")
                     if (interactive)
                         break
-                    else
+                    else {
+                        ex.printStackTrace(io.err)
                         System.exit(1)
+                    }
+
                 }
             }