C tracer: lookups fail in "should_trace_cache" · Issue #374 · nedbat/coveragepy (original) (raw)
Navigation Menu
- Explore
- Pricing
Provide feedback
Saved searches
Use saved searches to filter your results more quickly
Appearance settings
Description
Originally reported by sbehnel (Bitbucket: sbehnel, GitHub: Unknown)
The C tracer misuses the "should_trace_cache" to store two different things: Disposition objects and True/False, which makes later lookups fail with an AttributeError because True/False don't have a "trace" attribute. I attached a fix. Not sure if it's the correct one.
One thing I'm unsure about is whether the object returned from the cache lookup ("included") should be used as the new disposition object instead of the current one. But my guess is it shouldn't.
- Bitbucket: https://bitbucket.org/ned/coveragepy/issue/374
- This issue had attachments: tracer.patch. See the original issue for details.