coderadar


Namecoderadar JSON
Version 0.5.8 PyPI version JSON
download
home_pageNone
SummaryIdentifying the highest threats to your code quality by analyzing code metrics of your project using pytest and pylint.
upload_time2024-03-29 18:06:10
maintainerNone
docs_urlNone
authorCarsten König
requires_python>=2.7
licenseGNU GPLv3 License
keywords metrics code quality ci/cd lint
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # CodeRadar

Identifying the highest threats to your code quality by analyzing code metrics of your project using pytest and pylint.

**Status:**  Beta (runs, but certainly has bugs)\
**Authors:** Carsten König

## Purpose

In order to quickly see where an existing project needs refactoring, an overview of the worst code smells is needed. This package therefore summarizes these in a very brief report, that should guide you directly to the places in your software where an improvement would have the highest impact when you want to improve code quality.

CodeRadar investigates the results from Pytest and Pylint and summarizes the most important findings in a report with actionable hints that are prioritized for the best return on investment regarding your time: fixing the locations pointed out by CodeRadar will improve your code quality the most. If you fix one after the other, you will be able to improve your code step by step, with the highest impact fixes first. In order to give you feeling of progress, changes of the code quality are also indicated in the code quality report.

When run under Python 2.7 (yes, there is still legacy code out there that needs to be ported to Python 3), CodeRadar also points out Python 2/3 compatibility issues (but here in no specific order, as all of them need to be addressed). 

The code quality report is available in HTML and TXT format - the latter is printed on the console when you run CodeRadar. Here is an example of the console output for a previous version of CodeRadar:

```
Code Quality Report
coderadar
--------------------------------------------------
Pytest:
  Number of tests: 31 (+24)
           errors: 0 (+0)
  Test coverage: 42% (+26%)

--------------------------------------------------
Pylint Score:   4.20/10 (+0.36)
  Missing docstrings:             21 (+21)

  Needs Refactoring:
    Too complex:                  0 (+0) (max cyclomatic complexity=0 (+0))
                                    :  (line )
    Function too long (LoC/func): 1 (+1) (max LoC/func=60 (+60))
                                    report.py: Report._fillTemplate (line 194)
    Duplicate code:               0 block(s) (+0)
                                    0 lines in 0 modules:
                                    

  Obsolete code:
    Unused imports:             0 (+0)
                                  
                                  0 imports: 
    Unused variables:           0 (+0)
                                  
                                  0 variables: 
    Unused arguments:           1 (+0)
                                  report.py
                                  1 arguments: 'Report.getReportTemplate(coverage)' (l:105)
    Unreachable code:           0 (+0)
                                  
                                  0 block(s): 

--------------------------------------------------
```

And here is an image of the same code quality report in HTML format:
![CodeRadar HTML code quality report](https://gitlab.com/ck2go/coderadar/-/raw/main/docs/code_quality_report_html.png)

## Installation

```bash
pip install coderadar
```

## How to use
In order to analyze your sourcecode, go to your project root folder and run

```bash
coderadar <path-to-source>
```
This will run pytest, pylint and flake8 to get the metrics that will be analyzed.

The following artifacts will be created:

- ``coverage.xml``
- ``coverage.txt``
- ``pylint.json``
- ``pylint.txt``
- ``code_quality_report.html``
- ``code_quality_report.txt``
- 
If you run `coderadar` under Python 2.7, the following artifacts will be created additionally, in order to assess Python 3 compatibility:
- ``pylint_py3.json`` 
- ``pylint_py3.txt``

If you place these artifacts in a folder called `last_run`, located in the directory where you run the command, the results of the last run are automatically compared to the current run.

## How to contribute

No, CodeRadar itself, although developed in a (partially) test-driven manner, and being all about code quality, is also not a perfect piece of code (ironic, isn't it?). Feel free to suggest new features, report bugs or even contribute code. I would be happy to see this project grow and improve with your help. 

## License
[GNU GPLv3 License](https://choosealicense.com/licenses/gpl-3.0/)

## Author
**Carsten König**

- [GitLab](https://gitlab.com/ck2go "Carsten König")
- [GitHub](https://github.com/ck2go "Carsten König")
- [LinkedIn](https://www.linkedin.com/in/ck2go/ "Carsten König")
- [Website](https://www.carsten-koenig.de "Carsten König")

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "coderadar",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=2.7",
    "maintainer_email": null,
    "keywords": "metrics, code quality, CI/CD, lint",
    "author": "Carsten K\u00f6nig",
    "author_email": null,
    "download_url": "https://files.pythonhosted.org/packages/7f/cc/543ed11f20410c37c43d41313dec89e43d62542f60b1bf6f1cb9d25e2cd4/coderadar-0.5.8.tar.gz",
    "platform": null,
    "description": "# CodeRadar\n\nIdentifying the highest threats to your code quality by analyzing code metrics of your project using pytest and pylint.\n\n**Status:**  Beta (runs, but certainly has bugs)\\\n**Authors:** Carsten K\u00f6nig\n\n## Purpose\n\nIn order to quickly see where an existing project needs refactoring, an overview of the worst code smells is needed. This package therefore summarizes these in a very brief report, that should guide you directly to the places in your software where an improvement would have the highest impact when you want to improve code quality.\n\nCodeRadar investigates the results from Pytest and Pylint and summarizes the most important findings in a report with actionable hints that are prioritized for the best return on investment regarding your time: fixing the locations pointed out by CodeRadar will improve your code quality the most. If you fix one after the other, you will be able to improve your code step by step, with the highest impact fixes first. In order to give you feeling of progress, changes of the code quality are also indicated in the code quality report.\n\nWhen run under Python 2.7 (yes, there is still legacy code out there that needs to be ported to Python 3), CodeRadar also points out Python 2/3 compatibility issues (but here in no specific order, as all of them need to be addressed). \n\nThe code quality report is available in HTML and TXT format - the latter is printed on the console when you run CodeRadar. Here is an example of the console output for a previous version of CodeRadar:\n\n```\nCode Quality Report\ncoderadar\n--------------------------------------------------\nPytest:\n  Number of tests: 31 (+24)\n           errors: 0 (+0)\n  Test coverage: 42% (+26%)\n\n--------------------------------------------------\nPylint Score:   4.20/10 (+0.36)\n  Missing docstrings:             21 (+21)\n\n  Needs Refactoring:\n    Too complex:                  0 (+0) (max cyclomatic complexity=0 (+0))\n                                    :  (line )\n    Function too long (LoC/func): 1 (+1) (max LoC/func=60 (+60))\n                                    report.py: Report._fillTemplate (line 194)\n    Duplicate code:               0 block(s) (+0)\n                                    0 lines in 0 modules:\n                                    \n\n  Obsolete code:\n    Unused imports:             0 (+0)\n                                  \n                                  0 imports: \n    Unused variables:           0 (+0)\n                                  \n                                  0 variables: \n    Unused arguments:           1 (+0)\n                                  report.py\n                                  1 arguments: 'Report.getReportTemplate(coverage)' (l:105)\n    Unreachable code:           0 (+0)\n                                  \n                                  0 block(s): \n\n--------------------------------------------------\n```\n\nAnd here is an image of the same code quality report in HTML format:\n![CodeRadar HTML code quality report](https://gitlab.com/ck2go/coderadar/-/raw/main/docs/code_quality_report_html.png)\n\n## Installation\n\n```bash\npip install coderadar\n```\n\n## How to use\nIn order to analyze your sourcecode, go to your project root folder and run\n\n```bash\ncoderadar <path-to-source>\n```\nThis will run pytest, pylint and flake8 to get the metrics that will be analyzed.\n\nThe following artifacts will be created:\n\n- ``coverage.xml``\n- ``coverage.txt``\n- ``pylint.json``\n- ``pylint.txt``\n- ``code_quality_report.html``\n- ``code_quality_report.txt``\n- \nIf you run `coderadar` under Python 2.7, the following artifacts will be created additionally, in order to assess Python 3 compatibility:\n- ``pylint_py3.json`` \n- ``pylint_py3.txt``\n\nIf you place these artifacts in a folder called `last_run`, located in the directory where you run the command, the results of the last run are automatically compared to the current run.\n\n## How to contribute\n\nNo, CodeRadar itself, although developed in a (partially) test-driven manner, and being all about code quality, is also not a perfect piece of code (ironic, isn't it?). Feel free to suggest new features, report bugs or even contribute code. I would be happy to see this project grow and improve with your help. \n\n## License\n[GNU GPLv3 License](https://choosealicense.com/licenses/gpl-3.0/)\n\n## Author\n**Carsten K\u00f6nig**\n\n- [GitLab](https://gitlab.com/ck2go \"Carsten K\u00f6nig\")\n- [GitHub](https://github.com/ck2go \"Carsten K\u00f6nig\")\n- [LinkedIn](https://www.linkedin.com/in/ck2go/ \"Carsten K\u00f6nig\")\n- [Website](https://www.carsten-koenig.de \"Carsten K\u00f6nig\")\n",
    "bugtrack_url": null,
    "license": "GNU GPLv3 License",
    "summary": "Identifying the highest threats to your code quality by analyzing code metrics of your project using pytest and pylint.",
    "version": "0.5.8",
    "project_urls": {
        "Homepage": "https://gitlab.com/ck2go/coderadar"
    },
    "split_keywords": [
        "metrics",
        " code quality",
        " ci/cd",
        " lint"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "b08519ac12e31147f8c83e37cc3efbd6c16e9941b64a481696db713a0b0119a4",
                "md5": "85e8152183efe0b52fecc0f73efe82c3",
                "sha256": "54eb67bbcd37634ea40dd5389c06cfa48e6741567dfd622112d5e131153221a0"
            },
            "downloads": -1,
            "filename": "coderadar-0.5.8-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "85e8152183efe0b52fecc0f73efe82c3",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=2.7",
            "size": 34628,
            "upload_time": "2024-03-29T18:06:06",
            "upload_time_iso_8601": "2024-03-29T18:06:06.531054Z",
            "url": "https://files.pythonhosted.org/packages/b0/85/19ac12e31147f8c83e37cc3efbd6c16e9941b64a481696db713a0b0119a4/coderadar-0.5.8-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "7fcc543ed11f20410c37c43d41313dec89e43d62542f60b1bf6f1cb9d25e2cd4",
                "md5": "6fa3c7c719d58eccbcf81345ef9f0f11",
                "sha256": "bdaf7f5171bfc2638053fc38172804f554902ce207d2e85c657fbe7b66718713"
            },
            "downloads": -1,
            "filename": "coderadar-0.5.8.tar.gz",
            "has_sig": false,
            "md5_digest": "6fa3c7c719d58eccbcf81345ef9f0f11",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=2.7",
            "size": 128313,
            "upload_time": "2024-03-29T18:06:10",
            "upload_time_iso_8601": "2024-03-29T18:06:10.123309Z",
            "url": "https://files.pythonhosted.org/packages/7f/cc/543ed11f20410c37c43d41313dec89e43d62542f60b1bf6f1cb9d25e2cd4/coderadar-0.5.8.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-03-29 18:06:10",
    "github": false,
    "gitlab": true,
    "bitbucket": false,
    "codeberg": false,
    "gitlab_user": "ck2go",
    "gitlab_project": "coderadar",
    "lcname": "coderadar"
}
        
Elapsed time: 0.23842s