Skip to main content

Python module import analysis tool

Project description

FindImports

FindImports extracts Python module dependencies by parsing source files. It can report names that are imported but not used, and it can generate module import graphs in ASCII or graphviz formats.

A distinguishing feature of findimports used to be that it could parse doctest code inside docstrings.

Note that not all cases are handled correctly, especially if you use ‘import foo.bar.baz’.

If you need to find unused imports in your codebase, I recommend Pyflakes instead – it’s better maintained and more reliable. For import graphs consider snakefood.

Misc

Home page: https://github.com/mgedmin/findimports

Old project page: https://launchpad.net/findimports

Licence: GPL v2 or later (http://www.gnu.org/copyleft/gpl.html)

buildstatus coverage

Changes

1.4.0 (2015-06-04)

  • Python 3 support (3.3 and newer).

  • Use ast instead of compiler (#1).

1.3.2 (2015-04-13)

  • Fix “cannot find datetime” on Ubuntu 14.04 LTS (#3).

  • 100% test coverage.

1.3.1 (2014-04-16)

  • Added support for relative imports (e.g. from .. import foo).

1.3.0 (2013-04-10)

  • Moved to Github.

  • Drop Python 2.4 and 2.5 support.

  • Handle unicode docstrings with doctests.

1.2.14 (2012-02-12)

1.2.13 (2011-04-18)

  • Suppress “not a zipfile” warnings about *.egg-info files listed in sys.path.

1.2.12 (2011-04-08)

  • Handle zipfile errors when there are plain files that are not zip files on sys.path.

1.2.11 (2011-03-30)

  • Fix ‘could not find cPickle’ errors on Python 2.6 and newer.

1.2.10 (2010-02-05)

  • Ignore ‘from __future__ import …’.

1.2.9 (2009-07-07)

  • Fixed broken and uninstallable source distribution by adding a MANIFEST.in.

1.2.8 (2009-07-07)

  • Is able to find modules inside zip files (e.g. eggs).

  • Fixed deprecation warning on Python 2.6.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

findimports-1.4.0.tar.gz (20.2 kB view details)

Uploaded Source

Built Distribution

findimports-1.4.0-py2.py3-none-any.whl (12.9 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file findimports-1.4.0.tar.gz.

File metadata

  • Download URL: findimports-1.4.0.tar.gz
  • Upload date:
  • Size: 20.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for findimports-1.4.0.tar.gz
Algorithm Hash digest
SHA256 ee2342fe2debac6591b38630fa57099d169c1e3fbb5be09c5fceb413b883f439
MD5 139cfc79e2a6913142b10a8be5e57dc1
BLAKE2b-256 1d6b6ae2cac6342e55d1a82df6037af0c4a54015df48e140799aa4dccf6d378a

See more details on using hashes here.

File details

Details for the file findimports-1.4.0-py2.py3-none-any.whl.

File metadata

File hashes

Hashes for findimports-1.4.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 c656164711b3297985dbcd1ad56adbf97170c6d479bd0300dead68455d4472a9
MD5 c186a1ff9c8db97614b34e5e3efd8a71
BLAKE2b-256 792ae944e6b02a5c9302aa785929983ea5be9d8e87f96ffcc36a5e544dab2f9c

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page