-
-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
Wrong "Recursion detected" in py.test traceback #70
Comments
Original comment by Ronny Pfannschmidt (BitBucket: RonnyPfannschmidt, GitHub: RonnyPfannschmidt): it seems that FunctionMaker of the decorator package generates code + code objects with properties that end up looking exactly like recursion even if they are not im not sure how to work around that, and if we even should try to work around that |
Original comment by BitBucket: pchambon, GitHub: pchambon: Indeed, but there would be something to do in terms of clarity:
Then people would not believe (as I did) that the recursion has been detected by the python runtime. |
Original comment by Ronny Pfannschmidt (BitBucket: RonnyPfannschmidt, GitHub: RonnyPfannschmidt): fixed in pylib default now |
Original comment by Anonymous: 1000 thanks B-) |
This is necessary for when using e.g. `no_fnmatch_line` after it. Factor it out into `_fail`. (cherry picked from commit aade7ed) Ref: #5914 (comment)
This is necessary for when using e.g. `no_fnmatch_line` after it. Factor it out into `_fail`. (cherry picked from commit aade7ed) Ref: pytest-dev#5914 (comment)
Originally reported by: BitBucket: pchambon, GitHub: pchambon
Hello,
I've just spent a hell of a time trying to debug a "Recursion detected (same locals & position)" that my test suite raised, to eventually see that it was not a python error, but a pytest problem while collecting test results.
Due to the "magic" used in the program (decorator module), pytest thought there was a recursion, whereas several functions were simply using generated wrappers to preserve their signature while decorating.
The main problem is actually that the real exception (a runtime error, in the test sample) got hidden because of that "recursion detected" (see output below), thus deceiving me about the real problem. Having a fix to ignore "" entries, when detecting traceback recursions, would be neat too.
CF attached sample to reproduce the error ("decorator" module must tbe installed).
cheers,
P. Chambon
The text was updated successfully, but these errors were encountered: