| 1 |
Metadata-Version: 2.1 |
| 2 |
Name: importlab |
| 3 |
Version: 0.8.1 |
| 4 |
Summary: A library to calculate python dependency graphs. |
| 5 |
Home-page: https://github.com/google/importlab |
| 6 |
Maintainer: Google Inc. |
| 7 |
Maintainer-email: [email protected] |
| 8 |
License: Apache 2.0 |
| 9 |
Classifier: Development Status :: 4 - Beta |
| 10 |
Classifier: Intended Audience :: Developers |
| 11 |
Classifier: License :: OSI Approved :: Apache Software License |
| 12 |
Classifier: Programming Language :: Python |
| 13 |
Classifier: Programming Language :: Python :: 3 |
| 14 |
Classifier: Programming Language :: Python :: Implementation :: CPython |
| 15 |
Classifier: Topic :: Software Development |
| 16 |
Requires-Python: >=3.6.0 |
| 17 |
License-File: LICENSE |
| 18 |
|
| 19 |
|
| 20 |
importlab |
| 21 |
--------- |
| 22 |
|
| 23 |
Importlab is a library for Python that automatically infers dependencies |
| 24 |
and calculates a dependency graph. It can perform dependency ordering of |
| 25 |
a set of files, including cycle detection. |
| 26 |
|
| 27 |
Importlab's main use case is to work with static analysis tools that |
| 28 |
process one file at a time, ensuring that a file's dependencies are |
| 29 |
analysed before it is. |
| 30 |
|
| 31 |
(This is not an official Google product.) |
| 32 |
|
| 33 |
License |
| 34 |
------- |
| 35 |
|
| 36 |
Apache 2.0 |
| 37 |
|
| 38 |
Installation |
| 39 |
------------ |
| 40 |
|
| 41 |
Importlab can be installed from pip |
| 42 |
|
| 43 |
:: |
| 44 |
|
| 45 |
pip install importlab |
| 46 |
|
| 47 |
To check out and install the latest source code |
| 48 |
|
| 49 |
:: |
| 50 |
|
| 51 |
git clone https://github.com/google/importlab.git |
| 52 |
cd importlab |
| 53 |
python setup.py install |
| 54 |
|
| 55 |
Usage |
| 56 |
----- |
| 57 |
|
| 58 |
Importlab is primarily intended to be used as a library. It takes one or |
| 59 |
more python files as arguments, and generates an import graph, typically |
| 60 |
used to process files in dependency order. |
| 61 |
|
| 62 |
It is currently integrated into |
| 63 |
`pytype <https://github.com/google/pytype>`__ |
| 64 |
|
| 65 |
Command-line tool |
| 66 |
----------------- |
| 67 |
|
| 68 |
Importlab ships with a small command-line tool, also called |
| 69 |
``importlab``, which can display some information about a project's |
| 70 |
import graph. |
| 71 |
|
| 72 |
:: |
| 73 |
|
| 74 |
usage: importlab [-h] [--tree] [--unresolved] [filename [filename ...]] |
| 75 |
|
| 76 |
positional arguments: |
| 77 |
filename input file(s) |
| 78 |
|
| 79 |
optional arguments: |
| 80 |
-h, --help show this help message and exit |
| 81 |
--tree Display import tree. |
| 82 |
--unresolved Display unresolved dependencies. |
| 83 |
|
| 84 |
Roadmap |
| 85 |
------- |
| 86 |
|
| 87 |
- ``Makefile`` generation, to take advantage of ``make``'s incremental |
| 88 |
update and parallel execution features |
| 89 |
|
| 90 |
- Integration with other static analysis tools |