coveragepy icon indicating copy to clipboard operation
coveragepy copied to clipboard

Incorrect missed-branch message with return/finally/if

Open nedbat opened this issue 9 months ago • 0 comments

Describe the bug In the scriv coverage results, I see this:

image

The message says the return on 165 wasn't executed, but it is clearly marked as executed. The message should say, "Line 167 didn't return because the condition on 167 was always true."

To Reproduce

  1. Check out the scriv repo: https://github.com/nedbat/scriv
  2. Install the requirements: make requirements
  3. Run tox: tox
  4. Open the HTML report in htmlcov/index.html, navigate to the end of src/scriv/format_rst.py

nedbat avatar May 05 '24 12:05 nedbat