-
Notifications
You must be signed in to change notification settings - Fork 318
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Trim error stacktraces #729
Comments
copybara-service bot
pushed a commit
that referenced
this issue
Sep 2, 2020
… classic/non-orchestrator modes. This change should clean up test failure reporting by: - Remove test runner framework related stack frames - Truncate stack traces to a 64KB size when running under orchestrator to attempt to avoid binder transaction limits. This limit is already enforced when running in classic/non-orchestrator mode JUnit 4.13 has a really nice getTrimmedStackTrace feature, but androidx.test is fixed to 4.12 for the time being. So as a temporary workaround, copy the relevant JUnit utilty class into this project. Fixes #729, and hopefully #269 PiperOrigin-RevId: 329797783
copybara-service bot
pushed a commit
that referenced
this issue
Sep 3, 2020
… classic/non-orchestrator modes. This change should clean up test failure reporting by: - Remove test runner framework related stack frames - Truncate stack traces to a 64KB size when running under orchestrator to attempt to avoid binder transaction limits. This limit is already enforced when running in classic/non-orchestrator mode JUnit 4.13 has a really nice getTrimmedStackTrace feature, but androidx.test is fixed to 4.12 for the time being. So as a temporary workaround, copy the relevant JUnit utilty class into this project. Fixes #729, and hopefully #269 PiperOrigin-RevId: 329797783
copybara-service bot
pushed a commit
that referenced
this issue
Sep 16, 2020
… classic/non-orchestrator modes. This change should clean up test failure reporting by: - Remove test runner framework related stack frames - Truncate stack traces to a 64KB size when running under orchestrator to attempt to avoid binder transaction limits. This limit is already enforced when running in classic/non-orchestrator mode JUnit 4.13 has a really nice getTrimmedStackTrace feature, but androidx.test is fixed to 4.12 for the time being. So as a temporary workaround, copy the relevant JUnit change junit-team/junit4#1028 into this project. Fixes #729, and hopefully #269 PiperOrigin-RevId: 329797783
copybara-service bot
pushed a commit
that referenced
this issue
Sep 16, 2020
… classic/non-orchestrator modes. This change should clean up test failure reporting by: - Remove test runner framework related stack frames - Truncate stack traces to a 64KB size when running under orchestrator to attempt to avoid binder transaction limits. This limit is already enforced when running in classic/non-orchestrator mode JUnit 4.13 has a really nice getTrimmedStackTrace feature, but androidx.test is fixed to 4.12 for the time being. So as a temporary workaround, copy the relevant JUnit change junit-team/junit4#1028 into this project. Fixes #729, and hopefully #269 PiperOrigin-RevId: 329797783
copybara-service bot
pushed a commit
that referenced
this issue
Sep 16, 2020
… classic/non-orchestrator modes. This change should clean up test failure reporting by: - Remove test runner framework related stack frames - Truncate stack traces to a 64KB size when running under orchestrator to attempt to avoid binder transaction limits. This limit is already enforced when running in classic/non-orchestrator mode JUnit 4.13 has a really nice getTrimmedStackTrace feature, but androidx.test is fixed to 4.12 for the time being. So as a temporary workaround, copy the relevant JUnit change junit-team/junit4#1028 into this project. Fixes #729, and hopefully #269 PiperOrigin-RevId: 329797783
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Junit 4.13 provides
Failure.getTrimmedTrace()
as an alternative toFailure.getTrace()
:This could be used in
InstrumentationResultPrinter.reportFailure()
to report shorter stacktraces, avoiding binder transaction errors (#269) but also making those stacktraces more relevant.Related conversation: https://github.com/android/android-test/pull/711/files#r480418828
Unfortunately getTrimmedTrace is only available in JUnit 4.13 and Androidx.test still uses junit 4.12.
Another option is to bring in just the part we need until then: https://github.com/junit-team/junit4/blob/r4.13/src/main/java/org/junit/internal/Throwables.java
The text was updated successfully, but these errors were encountered: