codacy-coverage


Namecodacy-coverage JSON
Version 1.3.11 PyPI version JSON
download
home_pagehttps://github.com/codacy/python-codacy-coverage
SummaryCodacy coverage reporter for Python
upload_time2018-03-24 15:16:51
maintainer
docs_urlNone
authorCodacy
requires_python
licenseMIT
keywords development coverage
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            python-codacy-coverage
======================

Credits to Ryan for creating this! Python coverage reporter for Codacy https://www.codacy.com

.. image:: https://api.codacy.com/project/badge/grade/3a8cf06a9db94d0ab3d55e0357bc8f9d
   :target: https://www.codacy.com/app/Codacy/python-codacy-coverage
   :alt: Codacy Badge
.. image:: https://api.codacy.com/project/badge/coverage/3a8cf06a9db94d0ab3d55e0357bc8f9d
   :target: https://www.codacy.com/app/Codacy/python-codacy-coverage
   :alt: Codacy Badge
.. image:: https://circleci.com/gh/codacy/python-codacy-coverage.png?style=shield&circle-token=:circle-token
   :target: https://circleci.com/gh/codacy/python-codacy-coverage
   :alt: Build Status
.. image:: https://badge.fury.io/py/codacy-coverage.svg
   :target: https://badge.fury.io/py/codacy-coverage
   :alt: PyPI version
   
Setup
-----

Codacy assumes that coverage is previously configured for your project.

To generate the required coverage XML file, calculate coverage for your project as normal, by running:

``coverage xml``

Install codacy-coverage
~~~~~~~~~~~~~~~~~~~~~~~

You can install the coverage reporter by running:

``pip install codacy-coverage``

Updating Codacy
---------------

To update Codacy, you will need your project API token. You can create the token in `Project -> Settings -> Integrations -> Add Integration -> Project API`

Then set it in your terminal, replacing %Project_Token% with your own token:

``export CODACY_PROJECT_TOKEN=%Project_Token%``

**Enterprise only** (Skip this step if you are using https://www.codacy.com)

To send coverage in the enterprise version you should:

``export CODACY_API_BASE_URL=<Codacy_instance_URL>:16006``

**Upload Coverage**

Next, simply run the Codacy reporter. It will find the current commit and send all details to your project dashboard:

``python-codacy-coverage -r coverage.xml``

Note: You should keep your API token well **protected**, as it grants owner permissions to your projects.

Troubleshoot
---------------

If you are using any CI that does not have .git information, you can specify the commit with -c and the clone directory with -d. For example if you are using AppVeyor you can:

``python-codacy-coverage -c $APPVEYOR_REPO_COMMIT -d $APPVEYOR_BUILD_FOLDER -r coverage.xml``

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/codacy/python-codacy-coverage",
    "name": "codacy-coverage",
    "maintainer": "",
    "docs_url": null,
    "requires_python": "",
    "maintainer_email": "",
    "keywords": "development coverage",
    "author": "Codacy",
    "author_email": "team@codacy.com",
    "download_url": "https://files.pythonhosted.org/packages/c3/29/e3181fed33f4274727060feb6f08bc65b5242ade01c0b84e359232d8a83f/codacy-coverage-1.3.11.tar.gz",
    "platform": "",
    "description": "python-codacy-coverage\n======================\n\nCredits to Ryan for creating this! Python coverage reporter for Codacy https://www.codacy.com\n\n.. image:: https://api.codacy.com/project/badge/grade/3a8cf06a9db94d0ab3d55e0357bc8f9d\n   :target: https://www.codacy.com/app/Codacy/python-codacy-coverage\n   :alt: Codacy Badge\n.. image:: https://api.codacy.com/project/badge/coverage/3a8cf06a9db94d0ab3d55e0357bc8f9d\n   :target: https://www.codacy.com/app/Codacy/python-codacy-coverage\n   :alt: Codacy Badge\n.. image:: https://circleci.com/gh/codacy/python-codacy-coverage.png?style=shield&circle-token=:circle-token\n   :target: https://circleci.com/gh/codacy/python-codacy-coverage\n   :alt: Build Status\n.. image:: https://badge.fury.io/py/codacy-coverage.svg\n   :target: https://badge.fury.io/py/codacy-coverage\n   :alt: PyPI version\n   \nSetup\n-----\n\nCodacy assumes that coverage is previously configured for your project.\n\nTo generate the required coverage XML file, calculate coverage for your project as normal, by running:\n\n``coverage xml``\n\nInstall codacy-coverage\n~~~~~~~~~~~~~~~~~~~~~~~\n\nYou can install the coverage reporter by running:\n\n``pip install codacy-coverage``\n\nUpdating Codacy\n---------------\n\nTo update Codacy, you will need your project API token. You can create the token in `Project -> Settings -> Integrations -> Add Integration -> Project API`\n\nThen set it in your terminal, replacing %Project_Token% with your own token:\n\n``export CODACY_PROJECT_TOKEN=%Project_Token%``\n\n**Enterprise only** (Skip this step if you are using https://www.codacy.com)\n\nTo send coverage in the enterprise version you should:\n\n``export CODACY_API_BASE_URL=<Codacy_instance_URL>:16006``\n\n**Upload Coverage**\n\nNext, simply run the Codacy reporter. It will find the current commit and send all details to your project dashboard:\n\n``python-codacy-coverage -r coverage.xml``\n\nNote: You should keep your API token well **protected**, as it grants owner permissions to your projects.\n\nTroubleshoot\n---------------\n\nIf you are using any CI that does not have .git information, you can specify the commit with -c and the clone directory with -d. For example if you are using AppVeyor you can:\n\n``python-codacy-coverage -c $APPVEYOR_REPO_COMMIT -d $APPVEYOR_BUILD_FOLDER -r coverage.xml``\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Codacy coverage reporter for Python",
    "version": "1.3.11",
    "split_keywords": [
        "development",
        "coverage"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "md5": "878c90cce8d5cebe26f9e5d82485ab0a",
                "sha256": "d8a1ce56b0dd156d6b1de14fa6217d32ec86097902f08a17ff2f95ba27264474"
            },
            "downloads": -1,
            "filename": "codacy_coverage-1.3.11-py2.py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "878c90cce8d5cebe26f9e5d82485ab0a",
            "packagetype": "bdist_wheel",
            "python_version": "2.7",
            "requires_python": null,
            "size": 7519,
            "upload_time": "2018-03-24T15:16:52",
            "upload_time_iso_8601": "2018-03-24T15:16:52.306174Z",
            "url": "https://files.pythonhosted.org/packages/58/2c/5542d0ad47fafca9cc19315dbacfec389afaad9c383aed3ea138a263d777/codacy_coverage-1.3.11-py2.py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "md5": "1440914c5c7c37f37b082ebba863c506",
                "sha256": "b94651934745c638a980ad8d67494077e60f71e19e29aad1c275b66e0a070cbc"
            },
            "downloads": -1,
            "filename": "codacy-coverage-1.3.11.tar.gz",
            "has_sig": false,
            "md5_digest": "1440914c5c7c37f37b082ebba863c506",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 5180,
            "upload_time": "2018-03-24T15:16:51",
            "upload_time_iso_8601": "2018-03-24T15:16:51.065062Z",
            "url": "https://files.pythonhosted.org/packages/c3/29/e3181fed33f4274727060feb6f08bc65b5242ade01c0b84e359232d8a83f/codacy-coverage-1.3.11.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2018-03-24 15:16:51",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "github_user": "codacy",
    "github_project": "python-codacy-coverage",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "circle": true,
    "tox": true,
    "lcname": "codacy-coverage"
}
        
Elapsed time: 0.02416s