Enhance the error output in simple_codegen_task.py when unable to generate target(s)

Review Request #2427 - Created June 30, 2015 and submitted

Information
Sara Solano
pants
sarasolano/target_failure
1745
1797d1a...
Reviewers
pants-reviews
gmalmquist, zundel
Enhance the error output in simple_codegen_task.py when unable to generate target(s)

When executing proto step now the there is a more specific error message and turns every error into a TaskError.

Console output with invalid input before change:

12:12:10 00:00     [protoc]
                   Invalidated 3 targets.
12:12:10 00:00       [execute]...org/pantsbuild/example/distance/distances.proto:11:26: Expected field number.

FAILURE: /Users/sarasolano/.cache/pants/bin/protobuf/mac/10.10/2.4.1/protoc ... exited non-zero (1)


12:12:10 00:00   [complete]
               FAILURE
````

Console output with invalid input:

12:08:15 00:04 [protoc]
Invalidated 3 targets.
12:08:15 00:04 [execute]...org/pantsbuild/example/distance/distances.proto:11:26: Expected field number.

                   Failed to generate target: examples/src/protobuf/org/pantsbuild/example/distance:distance

FAILURE: /Users/sarasolano/.cache/pants/bin/protobuf/mac/10.10/2.4.1/protoc ... exited non-zero (1)

12:08:15 00:04 [complete]
FAILURE
```

Issues

  • 0
  • 2
  • 0
  • 2
Description From Last Updated
Eric Ayers
Garrett Malmquist
Sara Solano
Sara Solano
Eric Ayers
Sara Solano
Review request changed

Status: Closed (submitted)

Loading...