Createcoverage / version conflicts


If you use the createcoverage script ( so Travis can send the coverage data to, be aware it is broken at the moment (since the coveralls python script upgraded its coverage dependency to 3.6).

The consequence is your tests use coverage 3.4 but coveralls uses 4.0, which is not compliant with the 3.4 format, and nothing is uploaded to (you will see this misleading error message in your travis log: "Coverage submitted!
Failure to gather coverage: Couldn't read data from '/home/travis/build/plomino/rapido.core/.coverage': CoverageException: Doesn't seem to be a data file")

So for now, you need to do the following:

  • in your buildout, pin coverage to 3.6:

    recipe = zc.recipe.egg
    eggs = createcoverage

    coverage = 3.6

  • in your .travis.yml, make sure to install the same version for coveralls:

    - bin/test
    - bin/createcoverage
    - pip install coverage==3.6 coveralls
    - coveralls

Note: I have made a PR so createcoverage uses 3.6 which will make the pinning in buildout.cfg useless, but the .travis.yml change will still be necessary (well, until createcoverage upgrades to 4.0).


1 Like

I solved it by doing like so:


  • bin/createcoverage
  • bin/python -m coverage.pickle2json
  • bin/coveralls