Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame] | 1 | SUMMARY = "Dependency graphing for Python" |
| 2 | DESCRIPTION = " Generate dependency graphs from Python code. This \ |
| 3 | dependency tracker package has a few distinguishing characteristics \ |
| 4 | \ |
| 5 | * It uses the AST to parse the Python files. This is very reliable, \ |
| 6 | it always runs.\ |
| 7 | * No module is loaded. Loading modules to figure out dependencies is \ |
| 8 | almost always problem, because a lot of codebases run initialization \ |
| 9 | code in the global namespace, which often requires additional setup. \ |
| 10 | Snakefood is guaranteed not to have this problem (it just runs, no \ |
| 11 | matter what).\ |
| 12 | * It works on a set of files, i.e. you do not have to specify a single \ |
| 13 | script, you can select a directory (package or else) or a set of files.\ |
| 14 | It finds all the Python files recursively automatically.\ |
| 15 | * Automatic/no configuration: your PYTHONPATH is automatically adjusted \ |
| 16 | to include the required package roots. It figures out the paths that \ |
| 17 | are required from the files/directories given as input. You should not \ |
| 18 | have to setup ANYTHING.\ |
| 19 | * It does not have to automatically 'follow' dependencies between modules,\ |
| 20 | i.e. by default it only considers the files and directories you specify \ |
| 21 | on the command-line and their immediate dependencies. It also has an \ |
| 22 | option to automatically include only the dependencies within the \ |
| 23 | packages of the files you specify.\ |
| 24 | * It follows the UNIX philosophy of small programs that do one thing well:\ |
| 25 | it consists of a few simple programs whose outputs you combine via \ |
| 26 | pipes. Graphing dependencies always requires the user to filter and \ |
| 27 | cluster the filenames, so this is appropriate. You can combine it with \ |
| 28 | your favourite tools, grep, sed, etc.\ |
| 29 | \ |
| 30 | A problem with dependency trackers that run code is that they are unreliable, \ |
| 31 | due to the dynamic nature of Python (the presence of imports within function \ |
| 32 | calls and __import__ hooks makes it almost impossible to always do the right \ |
| 33 | thing). This script aims at being right 99% of the time, and we think that \ |
| 34 | given the trade-offs, 99% is good enough for 99% of the uses.\ |
| 35 | " |
| 36 | AUTHOR = "Martin Blais <blais@furius.ca>" |
| 37 | HOMEPAGE = "http://furius.ca/snakefood" |
| 38 | LICENSE = "GPL-2.0" |
| 39 | LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f" |
| 40 | |
| 41 | SRC_URI[md5sum] = "56c88667a33d8909b0aabf2ab6903bdf" |
| 42 | SRC_URI[sha256sum] = "295784668032254e7391ca99ba7060edd3ae4eca1a330ac11627b18ab5923b77" |
| 43 | |
| 44 | inherit pypi setuptools |
| 45 | |
| 46 | RDEPENDS_${PN} = " python-logging python-compiler python-shell" |
| 47 | # the above modules do not have a -native counterpart |
| 48 | RDEPENDS_${PN}_class-native = "" |
| 49 | |
| 50 | BBCLASSEXTEND = "native" |
| 51 | |