Skip to content

chore: grep for failures in CI#6339

Merged
bthomee merged 24 commits intoXRPLF:developfrom
mvadari:better-erroring
Feb 27, 2026
Merged

chore: grep for failures in CI#6339
bthomee merged 24 commits intoXRPLF:developfrom
mvadari:better-erroring

Conversation

@mvadari
Copy link
Collaborator

@mvadari mvadari commented Feb 6, 2026

High Level Overview of Change

This PR adjusts the CI tests to make it easier to spot errors without needing to sift through the thousands of lines of output.

Context of Change

Easier to sort through the test output, especially on mobile where there is no ctrl-f

Type of Change

  • Chore (no impact to binary, e.g. .gitignore, formatting, dropping support for older tooling)

API Impact

N/A

Test Plan

https://github.com/XRPLF/rippled/actions/runs/22004407043/job/63584713622?pr=6339
See "Show test failure summary" section

@mvadari mvadari added the DraftRunCI Normally CI does not run on draft PRs. This opts in. label Feb 6, 2026
@mvadari mvadari added Trivial Simple change with minimal effect, or already tested. Only needs one approval. and removed DraftRunCI Normally CI does not run on draft PRs. This opts in. labels Feb 6, 2026
@mvadari mvadari marked this pull request as ready for review February 6, 2026 19:52
Copilot AI review requested due to automatic review settings February 6, 2026 19:52
@mvadari mvadari changed the title grep for failures chore: grep for failures in CI Feb 6, 2026
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR aims to make CI failures easier to spot by capturing embedded unit test output into a log file and printing a small “failure” summary, alongside a small wording tweak to a parse-error log line in the JTx test environment.

Changes:

  • Update a JTx parse error log line from “parse failed” to “failure to parse”.
  • Pipe embedded unit test output through tee into unittest.log while preserving the original test exit code.
  • Add a post-failure workflow step to grep the unit test log for failure indicators.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
src/test/jtx/impl/Env.cpp Adjusts parse failure log phrasing in Env::autofill.
.github/workflows/reusable-build-test-config.yml Captures embedded unittest output to unittest.log and adds a grep-based failure summary step.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copilot AI review requested due to automatic review settings February 6, 2026 20:11
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

tx[sfAssetsMaximum] = "18446744073709551617e5"; // uint64 max + 1
env(tx, THISLINE);
BEAST_EXPECT(false);
fail("Expected parse_error for mantissa larger than uint64 max");
Copy link

Copilot AI Feb 6, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fail("Expected parse_error...") doesn’t include file/line context in the failure reason (unlike BEAST_EXPECT / BEAST_EXPECTS). Since this is in a negative-test path meant to aid debugging, consider using BEAST_EXPECTS(false, ...) (or the fail(reason, __FILE__, __LINE__) overload) so the output includes the source location when the parse_error is not thrown.

Suggested change
fail("Expected parse_error for mantissa larger than uint64 max");
BEAST_EXPECTS(false, "Expected parse_error for mantissa larger than uint64 max");

Copilot uses AI. Check for mistakes.
@codecov
Copy link

codecov bot commented Feb 6, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 79.8%. Comparing base (2e595b6) to head (404451a).
⚠️ Report is 1 commits behind head on develop.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff            @@
##           develop   #6339     +/-   ##
=========================================
- Coverage     79.8%   79.8%   -0.0%     
=========================================
  Files          848     848             
  Lines        67757   67757             
  Branches      7554    7559      +5     
=========================================
- Hits         54073   54063     -10     
- Misses       13684   13694     +10     

see 4 files with indirect coverage changes

Impacted file tree graph

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@mvadari mvadari requested a review from bthomee February 9, 2026 18:21
Comment on lines +232 to +233
./xrpld --unittest --unittest-jobs "${BUILD_NPROC}" 2>&1 | tee unittest.log
exit ${PIPESTATUS[0]}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My understanding was that an exit command will prevent the rest of the commands to run, even if the exit code is 0.

The reason it works here is because there are no non-failure() steps that follow this, but if we ever need to add another step then this might lead to unexpected behavior (until the developer notices the exit statement which, since it's unusual to see them outside of if-statements, is easy to overlook).

Would the following work?

Suggested change
./xrpld --unittest --unittest-jobs "${BUILD_NPROC}" 2>&1 | tee unittest.log
exit ${PIPESTATUS[0]}
./xrpld --unittest --unittest-jobs "${BUILD_NPROC}" 2>&1 | tee unittest.log || exit ${PIPESTATUS[0]}

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Augment was concerned that PIPESTATUS might be overwritten in this case, so I changed it to something related.

Copilot AI review requested due to automatic review settings February 12, 2026 21:59
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 2 out of 2 changed files in this pull request and generated no new comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copilot AI review requested due to automatic review settings February 12, 2026 22:08
Copilot AI review requested due to automatic review settings February 13, 2026 22:03
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 3 out of 3 changed files in this pull request and generated no new comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@mvadari mvadari requested a review from bthomee February 18, 2026 21:38
Copilot AI review requested due to automatic review settings February 24, 2026 20:17
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 2 out of 2 changed files in this pull request and generated no new comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copilot AI review requested due to automatic review settings February 24, 2026 22:09
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 2 out of 2 changed files in this pull request and generated no new comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copilot AI review requested due to automatic review settings February 26, 2026 18:48
@mvadari mvadari added the Ready to merge *PR author* thinks it's ready to merge. Has passed code review. Perf sign-off may still be required. label Feb 26, 2026
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings February 26, 2026 18:56
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 2 out of 2 changed files in this pull request and generated no new comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@bthomee bthomee enabled auto-merge (squash) February 26, 2026 19:56
@bthomee bthomee merged commit 404f35d into XRPLF:develop Feb 27, 2026
52 of 54 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Ready to merge *PR author* thinks it's ready to merge. Has passed code review. Perf sign-off may still be required. Trivial Simple change with minimal effect, or already tested. Only needs one approval.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants