{ "info": { "author": "Richard Jonees", "author_email": "r1chardj0n3s@gmail.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 5 - Production/Stable", "Intended Audience :: Developers", "License :: OSI Approved :: MIT License", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3", "Topic :: Software Development :: Build Tools" ], "description": "pip-check-reqs\n==============\n\nIt happens: you start using a module in your project and it works and you\ndon't realise that it's only being included in your `virtualenv`_ because\nit's a dependency of a package you're using. pip-missing-reqs finds those\nmodules so you can include them in the `requirements.txt`_ for the project.\n\nAlternatively, you have a long-running project that has some packages in\nrequirements.txt that are no longer actively used in the codebase. The\npip-extra-reqs tool will find those modules so you can remove them.\n\n.. _`virtualenv`: https://virtualenv.pypa.io/en/latest/\n.. _`requirements.txt`: https://pip.pypa.io/en/latest/user_guide.html#requirements-files\n\nAssuming your project follows a layout like the suggested `sample project`_::\n\n setup.py\n setup.cfg\n requirements.txt\n sample/__init__.py\n sample/sample.py\n sample/tests/test_sample.py\n\n.. _`sample project`: https://packaging.python.org/en/latest/tutorial.html#creating-your-own-project\n\nBasic usage, running in your project directory::\n\n \n pip-missing-reqs --ignore-file=sample/tests/* sample\n pip-extra-reqs --ignore-file=sample/tests/* sample\n\nThis will find all imports in the code in \"sample\" and check that the\npackages those modules belong to are in the requirements.txt file.\n\nAdditionally it is possible to check that there are no dependencies in\nrequirements.txt that are then unused in the project::\n\n \n pip-extra-reqs --ignore-file=sample/tests/* sample\n\nThis would find anything that is listed in requirements.txt but that is not\nimported by sample.\n\nSample tox.ini configuration\n----------------------------\n\nTo make your life easier, copy something like this into your tox.ini::\n\n [testenv:pip-check-reqs]\n deps=-rrequirements.txt\n commands=\n pip-missing-reqs --ignore-file=sample/tests/* sample\n pip-extra-reqs --ignore-file=sample/tests/* sample\n\n\nExcluding test files (or others) from this check\n------------------------------------------------\n\nYour test files will sometimes be present in the same directory as your\napplication source (\"sample\" in the above examples). The requirements for\nthose tests generally should not be in the requirements.txt file, and you\ndon't want this tool to generate false hits for those.\n\nYou may exclude those test files from your check using the `--ignore-file`\noption (shorthand is `-f`). Multiple instances of the option are allowed.\n\n\nExcluding modules from the check\n--------------------------------\n\nIf your project has modules which are conditionally imported, or requirements\nwhich are conditionally included, you may exclude certain modules from the\ncheck by name (or glob pattern) using `--ignore-module` (shorthand is `-m`)::\n\n # ignore the module spam\n pip-missing-reqs --ignore-module=spam sample\n # ignore the whole package spam as well\n pip-missing-reqs --ignore-module=spam --ignore-module=spam.* sample\n\n\nWith Thanks To\n--------------\n\nJosh Hesketh -- who refactored code and contributed the pip-extra-reqs tool.\n\nWil Cooley -- who handled the removal of normalize_name and fixed some bugs.\n\nRelease History\n---------------\n\n2.0.1\n\n- handled removal of normalize_name from pip.utils\n- handle packages with no files\n\n2.0 **renamed package to pip_check_reqs**\n\n- added tool pip-extra-reqs to find packages installed but not used\n (contributed by Josh Hesketh)\n\n1.2.1\n\n- relax requirement to 6.0+\n\n1.2.0\n\n- bumped pip requirement to 6.0.8+\n- updated use of pip internals to match that version\n\n1.1.9\n\n- test fixes and cleanup\n- remove hard-coded simplejson debugging behaviour\n\n1.1.8\n\n- use os.path.realpath to avoid symlink craziness on debian/ubuntu\n\n1.1.7\n\n- tweak to debug output\n\n1.1.6\n\n- add debug (very verbose) run output\n\n1.1.5\n\n- add header to output to make it clearer when in a larger test run\n- fix tests and self-test\n\n1.1.4\n\n- add --version\n- remove debug print from released code lol\n\n1.1.3\n\n- fix program to generate exit code useful for testing\n\n1.1.2\n\n- corrected version of vendored search_packages_info() from pip\n- handle relative imports\n\n1.1.1\n\n- fixed handling of import from __future__\n- self-tested and added own requirements.txt\n- cleaned up usage to require a file or directory to scan (rather than\n defaulting to \".\")\n- vendored code from pip 1.6dev which fixes bug in search_packages_info\n until pip 1.6 is released\n\n1.1.0 \n\n- implemented --ignore-module", "description_content_type": "", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/r1chardj0n3s/pip-check-reqs", "keywords": "", "license": "MIT", "maintainer": "", "maintainer_email": "", "name": "pip_check_reqs", "package_url": "https://pypi.org/project/pip_check_reqs/", "platform": "", "project_url": "https://pypi.org/project/pip_check_reqs/", "project_urls": { "Homepage": "https://github.com/r1chardj0n3s/pip-check-reqs" }, "release_url": "https://pypi.org/project/pip_check_reqs/2.0.3/", "requires_dist": null, "requires_python": "", "summary": "Find packages that should or should not be in requirements for a project", "version": "2.0.3" }, "last_serial": 3910714, "releases": { "1.2.1": [ { "comment_text": "", "digests": { "md5": "8897554de572e84a25e04c5b1a110e3b", "sha256": "6ab421d445f9989fa48ecfedd7d4351b2630d16a03e6a383c4b00af4b3f49473" }, "downloads": -1, "filename": "pip_check_reqs-1.2.1.tar.gz", "has_sig": true, "md5_digest": "8897554de572e84a25e04c5b1a110e3b", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7219, "upload_time": "2015-03-10T04:52:35", "url": "https://files.pythonhosted.org/packages/ca/88/724dc0a30f5d6078f1dfaa88c54348ebd3009891ad5b9bf5d9194ff32928/pip_check_reqs-1.2.1.tar.gz" } ], "2.0": [ { "comment_text": "", "digests": { "md5": "27d4f9821d26a38757669b9c9aeb6326", "sha256": "3bff57898665aadc9879521fe37465b64730e84b019e361cf26c0bf1216138c1" }, "downloads": -1, "filename": "pip_check_reqs-2.0-py2.py3-none-any.whl", "has_sig": true, "md5_digest": "27d4f9821d26a38757669b9c9aeb6326", "packagetype": "bdist_wheel", "python_version": "2.7", "requires_python": null, "size": 17179, "upload_time": "2015-03-10T05:00:47", "url": "https://files.pythonhosted.org/packages/b5/d1/deac8b8b9810760b41afccf49006708a2d111c3aaba700669667e8f3fe09/pip_check_reqs-2.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "ef52a78c7d1a5a15b94052e4f570152e", "sha256": "12947956cd2aeaf33711cbde2ce97382bc10c154fedaa87e25766bbae6254a68" }, "downloads": -1, "filename": "pip_check_reqs-2.0.tar.gz", "has_sig": true, "md5_digest": "ef52a78c7d1a5a15b94052e4f570152e", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7429, "upload_time": "2015-03-10T05:00:33", "url": "https://files.pythonhosted.org/packages/2f/96/5cd01dfe2298868048c6c2b02883342db5f46ef33915d04a95995a0aef2b/pip_check_reqs-2.0.tar.gz" } ], "2.0.1": [ { "comment_text": "", "digests": { "md5": "7d7121f4d69c9ede675adba5485ce6c6", "sha256": "044bc489a13a9a62033de31cbcfe483b774577cc7bac8b1ee7453cd260dcce6a" }, "downloads": -1, "filename": "pip_check_reqs-2.0.1-py2.py3-none-any.whl", "has_sig": true, "md5_digest": "7d7121f4d69c9ede675adba5485ce6c6", "packagetype": "bdist_wheel", "python_version": "2.7", "requires_python": null, "size": 11317, "upload_time": "2016-05-05T03:59:42", "url": "https://files.pythonhosted.org/packages/d8/3a/48cac74c3c3eb6bdd92ac1ec99a121f5ee09975f6ab9b15394d5ab0ac7a4/pip_check_reqs-2.0.1-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "9d421a4aab26cab8b264d508f4b8d320", "sha256": "ee4d2e70d2008d703986d25e15be845fdfdb5a38de1257ee564ee55c9ae4204e" }, "downloads": -1, "filename": "pip_check_reqs-2.0.1.tar.gz", "has_sig": true, "md5_digest": "9d421a4aab26cab8b264d508f4b8d320", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7827, "upload_time": "2016-05-05T03:59:24", "url": "https://files.pythonhosted.org/packages/64/ed/f8f6b58209591223e562bdefa62277e3cc0b72ebe29d65ad53a525cc5bbd/pip_check_reqs-2.0.1.tar.gz" } ], "2.0.3": [ { "comment_text": "", "digests": { "md5": "a274ba3360c74dec403341968aac5b9f", "sha256": "3cbaa9122e44ff58f3a274192ad58ff5be42805f04d9b53575f0eea25f5c9ed0" }, "downloads": -1, "filename": "pip_check_reqs-2.0.3.tar.gz", "has_sig": false, "md5_digest": "a274ba3360c74dec403341968aac5b9f", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8196, "upload_time": "2018-05-29T22:08:26", "url": "https://files.pythonhosted.org/packages/dd/5b/90581eb7fde676da9e12e42d6730d9ed4cfbd776d1c967c0ba23e02bafa0/pip_check_reqs-2.0.3.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "a274ba3360c74dec403341968aac5b9f", "sha256": "3cbaa9122e44ff58f3a274192ad58ff5be42805f04d9b53575f0eea25f5c9ed0" }, "downloads": -1, "filename": "pip_check_reqs-2.0.3.tar.gz", "has_sig": false, "md5_digest": "a274ba3360c74dec403341968aac5b9f", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 8196, "upload_time": "2018-05-29T22:08:26", "url": "https://files.pythonhosted.org/packages/dd/5b/90581eb7fde676da9e12e42d6730d9ed4cfbd776d1c967c0ba23e02bafa0/pip_check_reqs-2.0.3.tar.gz" } ] }