-
-
Notifications
You must be signed in to change notification settings - Fork 127
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
Annotation truncates failure output/callstack #1006
Comments
After some digging, I think this is the source of my issue: const message: string = (
(failure && failure._attributes && failure._attributes.message) ||
(testcase.error && testcase.error._attributes && testcase.error._attributes.message) ||
stackTrace.split('\n').slice(0, 2).join('\n') || // <- here
testcase._attributes.name
).trim() It looks like |
Repurposing an existing test using the sample JUnit report, it seems like the |
I see that while |
@stackptr thank you for the detailed report. Your observations are correct, the message used in the reports is prioritising the message property in the report, and only if that is missing falling back to the stacktrace - shortened to 2 lines (the body of the failure, if that's not there body of the testcase) The action currently while keeping track of the It would require change sin the https://github.com/mikepenz/action-junit-report/blob/main/src/annotator.ts to report the |
After some experimentation, I found annotations added via |
Released v4.0.4 with your PR. Thank you very much for your contribution! |
It appears only the first few lines of a failure output are used when this action creates an annotation.
The action is configured in a workflow following a step that produces a JUnit report:
An XML file in the
report_paths
looks like1:However, the annotation only contains the first few lines:
Using
gh api
to get the annotations for the commit shows the same truncation, i.e., that there does not seem to be an issue rendering the annotation in the GitHub UI:GitHub API documentation for creating a check run states that there is a 64KB limit for
output.annotations[].message
oroutput.annotations[].raw_details
. Can this action use the entirety of the test failure output when creating the annotation?Footnotes
This file is from the artifact created from
/tmp/junit
by the workflow, with irrelevant test cases removed. ↩The text was updated successfully, but these errors were encountered: