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

bpo-17446: Get line numbers of properties in doctest #3419

Closed
wants to merge 7 commits into from
Closed

bpo-17446: Get line numbers of properties in doctest #3419

wants to merge 7 commits into from

Conversation

mscuthbert
Copy link

@mscuthbert mscuthbert commented Sep 7, 2017

Doctests currently don’t know the line numbers of tests of properties. Fixes error messages on doctest failures for properties.

https://bugs.python.org/issue17446

#61648

@mscuthbert
Copy link
Author

Hoping that someone might be willing to take time out of their busy schedule to review this -- it already had reviews from the prior bugs-python discussion. @serhiy-storchaka you gave me a fantastic review with great comments on the wave-pathlib request, do you have time or know someone who has time to review this? For those of us using @property and PyDev, having line-numbers (which get hyperlinked to the appropriate code) would be a great time-saver.

@serhiy-storchaka serhiy-storchaka self-requested a review December 10, 2017 18:39
@serhiy-storchaka
Copy link
Member

The test is passed if revert changes in Lib/doctest.py. Therefore it doesn't test the changed behavior. Could you provide a test that is passed with the patched code and failed with the unpatched code?

@github-actions
Copy link

This PR is stale because it has been open for 30 days with no activity.

@github-actions github-actions bot added the stale Stale PR or inactive for long period of time. label Feb 21, 2022
@AA-Turner
Copy link
Member

Reopening per #61648 (comment)

A

@AA-Turner AA-Turner reopened this Jun 7, 2022
@github-actions github-actions bot removed the stale Stale PR or inactive for long period of time. label Jul 1, 2022
@github-actions
Copy link

This PR is stale because it has been open for 30 days with no activity.

@github-actions github-actions bot added the stale Stale PR or inactive for long period of time. label Aug 13, 2022
@github-actions github-actions bot removed the stale Stale PR or inactive for long period of time. label Dec 15, 2023
@serhiy-storchaka
Copy link
Member

The test is passed because it tests lineno attributes of Example instances instead of DocTest instances. Also, the code can be much simpler.

I created an alternative PR #113161.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants