Open rotu opened 4 years ago
Please provide reproducible steps.
Run this on a windows runner: https://github.com/rotu/colcon-cmake/actions/runs/224539412/workflow
Please provide more minimal steps which only involve the pieces necessary to reproduce the problem locally.
Sure. Just edit a shell hook to have a syntax error and observe that there is no debug info to speak of. The Python stack trace here should be suppressed as well, since the Python code is working as intended.
I may be naive. It seems that batch scripts don’t have “stack traces” as other languages do. The best solution for batch might just be to run the script with echo on and print the output if the script fails.
I expect to see useful failure information (e.g. stdout and stderr of the failed command, or even whether the target script exists) but colcon does not expose this info.
assert not rc, 'Expected {args} to pass'.format_map(locals())
You seem to be using an older version of colcon-core
. The current code already includes the stderr
output (even though that might or might not contain valuable information): https://github.com/colcon/colcon-core/blob/caee5e64608912f52e86f79de1cf53b8c34713df/colcon_core/subprocess.py#L109-L110. This has been added in #353.
The Python stack trace here should be suppressed as well, since the Python code is working as intended.
The Python exception is only visible error that something went wrong. I don't see how you could distinguish a failure caused by some colcon
code vs. package specific content. And for the former case the stack trace is essential in debugging. If you have a specific proposal how to do better please feel free to describe it (or even better contribute a pull request).
Please re-run your use case with an up-to-date colcon-core
package and share the resulting error message to determine if this can be closed.
I expect to see useful failure information (e.g. stdout and stderr of the failed command, or even whether the target script exists) but colcon does not expose this info. It instead shows only the python stack trace which contains no actionable details.
https://github.com/rotu/colcon-cmake/runs/1029201058?check_suite_focus=true#step:17:15262