-
-
Notifications
You must be signed in to change notification settings - Fork 472
Description
I was running some unit tests using hypothesis (link) which relies on coverage, and I ran into a crash. Specifically, I received the following error message:
coverage.misc.CoverageException: Couldn't use data file '/Users/me/my_project/.coverage': UNIQUE constraint failed: file.path
I have experienced this issue both on macOS and Linux while running python 3.6, and the issue does not persist with COVERAGE_STORAGE=json.
I have included a gist below which contains files to reproduce the error. Specifically, the error occurs when the hypothesis assume statement in test.py fails more than half the time and when wrap is called.
To reproduce the error, run the build.sh script, which will initialize a virtualenv, install required modules, and run a short example which should throw the error.
Additionally, I am including a vagrantfile which will run build.shin a VM, thus providing a clean slate for testing.
https://gist.github.com/TylerADavis/393ee6382b4f645774100ae0c490c5ba
Please let me know if there is any other information I could provide that would be useful.