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

Recursion depth checker doesn't work in tracer.c #9

Closed
nedbat opened this issue Jun 22, 2009 · 2 comments
Closed

Recursion depth checker doesn't work in tracer.c #9

nedbat opened this issue Jun 22, 2009 · 2 comments
Labels
bug Something isn't working

Comments

@nedbat
Copy link
Owner

nedbat commented Jun 22, 2009

From a comment on the coverage page:

It seems that the recursion limit statement does not work when executed in coverage 3.0, like in this sample code:

#!python

import sys
sys.setrecursionlimit(2500)
def add1(number = 0):
    number = number + 1
    if(number < 2000):add1(number) 
if __name__ == '__main__': 
    add1()

Thanks.


@nedbat
Copy link
Owner Author

nedbat commented Jun 22, 2009

The problem isn't setrecusionlimit, it's the depth checker in tracer.c: it's off by one (or two).

@nedbat
Copy link
Owner Author

nedbat commented Jun 24, 2009

Fixed in <<changeset 2c62966facd1 (bb)>>

@nedbat nedbat closed this as completed Jun 24, 2009
@nedbat nedbat added major bug Something isn't working labels Jun 23, 2018
agronholm added a commit to agronholm/coveragepy that referenced this issue Aug 16, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant