Skip to content
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

Better exception handling in tests #322

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

rotu
Copy link
Contributor

@rotu rotu commented Mar 14, 2020

  1. Don't continue with testing if an extension crashes
  2. Use logger.exception to format current traceback in an error

@codecov
Copy link

codecov bot commented Mar 14, 2020

Codecov Report

Merging #322 into master will increase coverage by 0.03%.
The diff coverage is 0.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #322      +/-   ##
==========================================
+ Coverage   79.61%   79.65%   +0.03%     
==========================================
  Files          55       55              
  Lines        3209     3209              
  Branches      534      534              
==========================================
+ Hits         2555     2556       +1     
+ Misses        607      606       -1     
  Partials       47       47              
Impacted Files Coverage Δ
colcon_core/task/python/test/__init__.py 26.59% <0.00%> (+0.27%) ⬆️
colcon_core/command.py 86.91% <0.00%> (+0.06%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update af7fa08...f2b3a34. Read the comment docs.

@dirk-thomas
Copy link
Member

Don't continue with testing if an extension crashes
Use logger.exception to format current traceback in an error

(As mentioned a few times to you already) Please consider creating separate pull requests for orthogonal changes - simply because each can be reviewed and iterated on independently.

Regarding the functional change: a very important design choice / feature of colcon is that a single extension (which can be provided by any package) does rarely result in a fatal error of the tool. In as many cases as possible colcon tries to be resilient, logs the error, but continue to perform the requested operation. Therefore I don't think patch is the right approach to resolve #321.

@dirk-thomas dirk-thomas added the in progress Actively being worked on (Kanban column) label Mar 27, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in progress Actively being worked on (Kanban column)
Development

Successfully merging this pull request may close these issues.

None yet

2 participants