Skip to content

Commit e0a59fc

Browse files
committed
Do not log internal errors by default
1 parent ead0a77 commit e0a59fc

File tree

4 files changed

+8
-3
lines changed

4 files changed

+8
-3
lines changed

ci_common/common.hocon

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,7 @@ common : ${java8Downloads} ${packagesLinux} {
8888
environment : {
8989
PKG_TEST_ENV_miniUI : "LC_ALL=C"
9090
PKG_TEST_ENV_compare : "LC_ALL=C"
91+
FASTR_OPTION_PrintErrorStacktracesToFile: "true"
9192
}
9293
}
9394

com.oracle.truffle.r.engine/src/com/oracle/truffle/r/engine/REngine.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -653,7 +653,10 @@ public RNode getBody() {
653653

654654
@TruffleBoundary
655655
private static boolean checkResult(Object result) {
656-
return RAbstractVector.verify((RAbstractVector) result);
656+
if (result instanceof RAbstractVector) {
657+
return RAbstractVector.verify((RAbstractVector) result);
658+
}
659+
return true;
657660
}
658661

659662
@Override

com.oracle.truffle.r.runtime/src/com/oracle/truffle/r/runtime/FastROptions.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@
3838
*/
3939
public enum FastROptions {
4040
PrintErrorStacktraces("Prints Java and R stack traces for all errors", false),
41-
PrintErrorStacktracesToFile("Dumps Java and R stack traces to 'fastr_errors.log' for all errors", true),
41+
PrintErrorStacktracesToFile("Dumps Java and R stack traces to 'fastr_errors.log' for all errors", false),
4242
// TODO: this should be logging category
4343
Debug("Debug=name1,name2,...; Turn on debugging output for 'name1', 'name2', etc.", null, true),
4444
TraceCalls("Trace all R function calls", false),

com.oracle.truffle.r.runtime/src/com/oracle/truffle/r/runtime/RInternalError.java

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,8 @@ private static void reportError(String errMsg, Throwable throwable, int contextI
213213
RSuicide.rSuicide("FastR internal error");
214214
}
215215
} else {
216-
message += ".";
216+
message += ". You can rerun FastR with --jvm.DR:+" + FastROptions.PrintErrorStacktracesToFile.name() +
217+
" to turn on internal errors logging. Please attach the log file to the issue if possible.";
217218
}
218219
if (!FastROptions.PrintErrorStacktraces.getBooleanValue() && !FastROptions.PrintErrorStacktracesToFile.getBooleanValue()) {
219220
System.err.println(message);

0 commit comments

Comments
 (0)