{"id":15031657,"url":"https://github.com/saadmk11/python-third-party-imports","last_synced_at":"2025-04-10T00:23:33.695Z","repository":{"id":65281706,"uuid":"589256664","full_name":"saadmk11/python-third-party-imports","owner":"saadmk11","description":"A Python CLI tool (Written in Rust) that finds all third-party packages imported into your Python project","archived":false,"fork":false,"pushed_at":"2023-01-31T15:24:42.000Z","size":63,"stargazers_count":38,"open_issues_count":1,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2024-04-29T19:06:23.793Z","etag":null,"topics":["cargo","cli","cli-app","import","maturin","package","pip","python","python-rust","python3","rust","rust-lang","rust-python","rustlang"],"latest_commit_sha":null,"homepage":"https://pypi.org/project/third-party-imports/","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/saadmk11.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2023-01-15T15:41:51.000Z","updated_at":"2023-07-26T04:33:22.000Z","dependencies_parsed_at":"2023-02-10T09:45:36.301Z","dependency_job_id":null,"html_url":"https://github.com/saadmk11/python-third-party-imports","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saadmk11%2Fpython-third-party-imports","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saadmk11%2Fpython-third-party-imports/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saadmk11%2Fpython-third-party-imports/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/saadmk11%2Fpython-third-party-imports/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/saadmk11","download_url":"https://codeload.github.com/saadmk11/python-third-party-imports/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248132385,"owners_count":21053028,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cargo","cli","cli-app","import","maturin","package","pip","python","python-rust","python3","rust","rust-lang","rust-python","rustlang"],"created_at":"2024-09-24T20:16:16.333Z","updated_at":"2025-04-10T00:23:33.652Z","avatar_url":"https://github.com/saadmk11.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# python-third-party-imports\n\nThis is a **Python** **CLI** tool built with **Rust** that finds all third-party packages imported into your Python project.\n\n# Install\n\nYou can install this package via pip.\n\n```console\npip install third-party-imports\n```\n\n# Usage\n\n### Run:\n\n**Check a directory:**\n\n```console\nthird-party-imports path/to/project/dir\n```\n\n**Check a directory with extra files:**\n\n```console\nthird-party-imports --extra-file-paths path/to/project/dir/foo.sh path/to/project/dir\n```\n\n**Note:** You can use `--extra-file-paths` option to include files that do not contain `.py` or `.pyi` extension.\n\n\n**Check a file:**\n\n```console\nthird-party-imports --project-root path/to/project/dir/ path/to/project/dir/foo/main.py\n```\n\n**Note:** If the file is not located in the project root directory,\nthen you need to use `--project-root` option to specify where the project root directory is located.\n\n### Help:\n\n```console\nFind all third-party packages imported into your python project.\n\nUsage: third-party-imports [OPTIONS] \u003cPATH\u003e\n\nArguments:\n  \u003cPATH\u003e  Path to a file or directory to check\n\nOptions:\n  -p, --project-root \u003cPROJECT_ROOT\u003e          Path to the project's root directory\n  -e, --extra-file-paths \u003cEXTRA_FILE_PATHS\u003e  Extra file paths to check\n  -h, --help                                 Print help\n  -V, --version                              Print version\n```\n\n# Example\n\n```console\nthird-party-imports examples/\n```\n\n**Output:**\n\n```console\nFound '4' third-party package imports in '5' files. (Took 920.50µs)\n\ncelery\ndjango\npandas\nrequests\n```\n\n# Development\n\n### Run using Cargo\n\n```console\ncargo +nightly run -- path/to/project/dir\n```\n\n### Code Format\n\n```console\ncargo +nightly fmt\n```\n\n### Run Tests\n\n```console\ncargo +nightly test\n```\n\n### Install Package in current `virtualenv`\n\n```console\nmaturin develop\n```\n\n# License\n\nThe code in this project is released under the [MIT License](LICENSE).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsaadmk11%2Fpython-third-party-imports","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsaadmk11%2Fpython-third-party-imports","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsaadmk11%2Fpython-third-party-imports/lists"}