GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — gh-106368: Improve coverage reports for argument clinic by AlexWaygood · Pull Request #107693 · python/cpython

Conversation

@AlexWaygood

@AlexWaygood AlexWaygood commented Aug 6, 2023 •
edited by bedevere-bot
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member
  • Use ... rather than pass for empty bodies in abstract methods that are never meant to be executed. Exclude lines consisting solely of ... in our .coveragerc file.
  • Use raise AssertionError instead of raise RuntimeError for an exception that's never meant to be executed -- it would indicate a bug in Tools/clinic/ itself, rather than an incorrect usage of argument clinic, if that line was ever executed. Exclude raise AssertionError( lines in our .coveragerc file.
  • A reasonably large block of code in Tools/clinic/cpp.py was being excluded from coverage reports because it was all inside an if __name__ == "__main__" block, and if __name__ == "__main__" blocks are excluded in our .coveragerc file. That was making our coverage for cpp.py look better than it actually was. Move that block inside a _main() function so that it's correctly reported as being uncovered in coverage reports.
  • Issue: Increase Argument Clinic test coverage #106368

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@AlexWaygood
Improve coverage reports for argument clinic
7d7323f
@AlexWaygood AlexWaygood added the skip news label Aug 6, 2023
@AlexWaygood
AlexWaygood requested a review from erlend-aasland as a code owner August 6, 2023 13:47
@bedevere-bot bedevere-bot added the awaiting core review label Aug 6, 2023
@bedevere-bot bedevere-bot mentioned this pull request Aug 6, 2023
Increase Argument Clinic test coverage #106368
Closed
AlexWaygood
AlexWaygood commented Aug 6, 2023
View reviewed changes
Comment thread Tools/clinic/clinic.py Resolved

Uh oh!

There was an error while loading. Please reload this page.

erlend-aasland
erlend-aasland approved these changes Aug 6, 2023
View reviewed changes

@erlend-aasland erlend-aasland left a comment

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

AlexWaygood reacted with rocket emoji
All reactions
  • 🚀 1 reaction
@bedevere-bot bedevere-bot added awaiting merge and removed awaiting core review labels Aug 6, 2023
@AlexWaygood
AlexWaygood merged commit ee3bf45 into python:main Aug 6, 2023
@bedevere-bot bedevere-bot removed the awaiting merge label Aug 6, 2023
@AlexWaygood
AlexWaygood deleted the clinic-coverage branch August 6, 2023 19:40
kostyafarber pushed a commit to kostyafarber/cpython that referenced this pull request Aug 7, 2023
@AlexWaygood @kostyafarber
pythongh-106368: Improve coverage reports for argument clinic (python…
0c14eef
…#107693)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@erlend-aasland erlend-aasland erlend-aasland approved these changes

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

skip news

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

3 participants

@AlexWaygood @erlend-aasland @bedevere-bot
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.