{ "info": { "author": "Ilya Lebedev", "author_email": "melevir@gmail.com", "bugtrack_url": null, "classifiers": [], "description": "# flake8-adjustable-complexity\n\n[![Build Status](https://travis-ci.org/best-doctor/flake8-adjustable-complexity.svg?branch=master)](https://travis-ci.org/best-doctor/flake8-adjustable-complexity)\n[![Maintainability](https://api.codeclimate.com/v1/badges/544649e16b4cf6645ad3/maintainability)](https://codeclimate.com/github/best-doctor/flake8-adjustable-complexity/maintainability)\n[![Test Coverage](https://api.codeclimate.com/v1/badges/544649e16b4cf6645ad3/test_coverage)](https://codeclimate.com/github/best-doctor/flake8-adjustable-complexity/test_coverage)\n\nAn extension for flake8 to report on too complex functions with bad variables names.\n\nSometimes you want to use too generic variable name inside some function.\nIt this case you want to be sure that the function is more simple that\nothers, so a reader doesn't have to remember meaning of a variable\ntogether with other logic for a long time.\n\nThis plugin calculates max allowed cyclomatic complexity for each function\nseparately. Default is 7 and it is decreased by 2 for each variable from\nblacklist inside the function. If actual complexity overcomes max calculated\ncomplexity, the plugin reports an error.\n\n## Installation\n\n pip install flake8-adjustable-complexity\n\n\n## Example\n\nSample file:\n\n```python\n# test.py\n\ndef foo():\n for vars in range(5):\n for info in range(5):\n for obj in range(5):\n pass\n```\n\nUsage:\n\n```terminal\n$ flake8 test.py\ntest.py:1:1: CCE001 is too complex (4 > 1)\n```\n\nTested on Python 3.7.2 and flake8 3.5.0.\n\n\n## Contributing\n\nWe would love you to contribute to our project. It's simple:\n\n1. Create an issue with bug you found or proposal you have. Wait for approve from maintainer.\n2. Create a pull request. Make sure all checks are green.\n3. Fix review comments if any.\n4. Be awesome.\n\nHere are useful tips:\n\n- You can run all checks and tests with `make check`. Please do it before TravisCI does.\n- We use [BestDoctor python styleguide](https://github.com/best-doctor/guides/blob/master/guides/python_styleguide.md). Sorry, styleguide is available only in Russian for now.\n- We respect [Django CoC](https://www.djangoproject.com/conduct/). Make soft, not bullshit.", "description_content_type": "", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/best-doctor/flake8-adjustable-complexity", "keywords": "flake8 annotations", "license": "MIT", "maintainer": "", "maintainer_email": "", "name": "flake8-adjustable-complexity", "package_url": "https://pypi.org/project/flake8-adjustable-complexity/", "platform": "", "project_url": "https://pypi.org/project/flake8-adjustable-complexity/", "project_urls": { "Homepage": "https://github.com/best-doctor/flake8-adjustable-complexity" }, "release_url": "https://pypi.org/project/flake8-adjustable-complexity/0.0.1/", "requires_dist": null, "requires_python": "", "summary": "A flake8 extension that checks cyclomatic complexity and calculates max complexity limit in runtime", "version": "0.0.1" }, "last_serial": 5169303, "releases": { "0.0.1": [ { "comment_text": "", "digests": { "md5": "23e2d9c69c43b2a3dfd2c6cc50829244", "sha256": "9cb550c8f5ad84d63752bcb587134047e725efcad739ff9eeb6ee0b99649d4cc" }, "downloads": -1, "filename": "flake8_adjustable_complexity-0.0.1.tar.gz", "has_sig": false, "md5_digest": "23e2d9c69c43b2a3dfd2c6cc50829244", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4385, "upload_time": "2019-04-21T08:14:58", "url": "https://files.pythonhosted.org/packages/d4/8c/bc1ff8d6ab7a3e636cb024a5692fac51c063cb53c1e1538a29cbbab345b7/flake8_adjustable_complexity-0.0.1.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "23e2d9c69c43b2a3dfd2c6cc50829244", "sha256": "9cb550c8f5ad84d63752bcb587134047e725efcad739ff9eeb6ee0b99649d4cc" }, "downloads": -1, "filename": "flake8_adjustable_complexity-0.0.1.tar.gz", "has_sig": false, "md5_digest": "23e2d9c69c43b2a3dfd2c6cc50829244", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4385, "upload_time": "2019-04-21T08:14:58", "url": "https://files.pythonhosted.org/packages/d4/8c/bc1ff8d6ab7a3e636cb024a5692fac51c063cb53c1e1538a29cbbab345b7/flake8_adjustable_complexity-0.0.1.tar.gz" } ] }