Skip to content

Commit

Permalink
pw_presubmit: Drop extra lines from bazel summary
Browse files Browse the repository at this point in the history
Drop unnecessary lines from the bazel failure summary.

Bug: b/262262623
Change-Id: I9e345389bf0eb12bde75dcb03a6b735df89c3678
Reviewed-on: https://pigweed-review.googlesource.com/c/pigweed/pigweed/+/125651
Reviewed-by: Alexei Frolov <[email protected]>
Pigweed-Auto-Submit: Rob Mohr <[email protected]>
Commit-Queue: Auto-Submit <[email protected]>
  • Loading branch information
mohrr authored and CQ Bot Account committed Dec 29, 2022
1 parent 377722d commit 2c65b6c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
2 changes: 0 additions & 2 deletions pw_presubmit/py/bazel_parser_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,10 +64,8 @@

_REAL_TEST_SUMMARY = """
ERROR: /usr/local/google/home/mohrr/pigweed/pigweed/pw_kvs/BUILD.bazel:25:14: Compiling pw_kvs/entry.cc failed: (Exit 1): gcc failed: error executing command
# Configuration: 752863e407a197a5b9da05cfc572e7013efd6958e856cee61d2fa474ed...
# Execution platform: @local_config_platform//:host
Use --sandbox_debug to see verbose messages from the sandbox and retain the sandbox build root for debugging
pw_kvs/entry.cc:49:20: error: no member named 'Dat' in 'pw::Status'
return Status::Dat aLoss();
~~~~~~~~^
Expand Down
6 changes: 6 additions & 0 deletions pw_presubmit/py/pw_presubmit/bazel_parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,12 @@ def parse_bazel_stdout(bazel_stdout: Path) -> str:
if line.strip().startswith(('(cd /', 'exec env')):
continue

if line.strip().startswith('Use --sandbox_debug to see'):
continue

if line.strip().startswith('# Configuration'):
continue

# An "<ALLCAPS>:" line usually means compiler output is done
# and useful compiler errors are complete.
if re.match(r'^(?!ERROR)[A-Z]+:', line):
Expand Down

0 comments on commit 2c65b6c

Please sign in to comment.