Pycharm py.test coverage 'Coverage' object has no attribute 'export'
<p>I'm trying to run a py.test with coverage in pycharm. On my home pc it works like a charm, however on my laptop I'm getting this stacktrace</p>

<pre><code>/home/david/PycharmProjects/pyCardDeck/virtualenv/bin/python /opt/pycharm/helpers/coverage_runner/run_coverage.py run --omit=\"/opt/pycharm/helpers*\" /opt/pycharm/helpers/pycharm/pytestrunner.py -p pytest_teamcity /home/david/PycharmProjects/pyCardDeck tests
Testing started at 13:15 ...
============================= test session starts ==============================
platform linux -- Python 3.5.2, pytest-3.0.1, py-1.4.31, pluggy-0.3.1
rootdir: /home/david/PycharmProjects/pyCardDeck, inifile: 
plugins: cov-2.3.1
collected 35 items

tests/test_card.py ..
tests/test_deck.py ..............................Traceback (most recent call last):
  File "/opt/pycharm/helpers/coverage_runner/run_coverage.py", line 44, in &lt;module&gt;
    main()
  File "/home/david/PycharmProjects/pyCardDeck/virtualenv/lib/python3.5/site-packages/coverage/cmdline.py", line 753, in main
...

========================== 35 passed in 0.89 seconds ===========================
    status = CoverageScript().command_line(argv)
  File "/home/david/PycharmProjects/pyCardDeck/virtualenv/lib/python3.5/site-packages/coverage/cmdline.py", line 480, in command_line
    return self.do_run(options, args)
  File "/home/david/PycharmProjects/pyCardDeck/virtualenv/lib/python3.5/site-packages/coverage/cmdline.py", line 638, in do_run
    self.coverage.export()
AttributeError: 'Coverage' object has no attribute 'export'

Process finished with exit code 1
</code></pre>

<p>Running py.test --cov manually works, so it's something inside of Pycharm magic. My laptop is running with Pycharm 2016.1.4 and coverage 4.2</p>

<p>That line in cmdline.py should read <code>self.coverage.save()</code>. It's never said <code>export</code>. You should reinstall coverage.py.  I have no idea what changed it.</p>

python pycharm py.test coverage.py