1 :mod:`modulegraph.find_modules` --- High-level module dependency finding interface
2 ==================================================================================
4 .. module:: modulegraph.find_modules
5 :synopsis: High-level module dependency finding interface
7 This module provides a high-level interface to the functionality of
8 the modulegraph package.
11 .. function:: find_modules([scripts[, includes[, packages[, excludes[, path[, debug]]]]]])
13 High-level interface, takes iterables for: scripts, includes, packages, excludes
15 And returns a :class:`modulegraph.modulegraph.ModuleGraph` instance,
16 python_files, and extensions
18 python_files is a list of pure python dependencies as modulegraph.Module objects,
20 extensions is a list of platform-specific C extension dependencies as modulegraph.Module objects
23 .. function:: parse_mf_results(mf)
25 Return two lists: the first one contains the python files in the graph,
26 the second the C extensions.
28 :param mf: a :class:`modulegraph.modulegraph.ModuleGraph` instance
31 Lower-level functionality
32 -------------------------
34 The functionality in this section is much lower level and should probably
35 not be used. It's mostly documented as a convenience for maintainers.
38 .. function:: get_implies()
40 Return a mapping of implied dependencies. The key is a, possibly dotted,
41 module name and the value a list of dependencies.
43 This contains hardcoded list of hard dependencies, for example for C
44 extensions in the standard libary that perform imports in C code, which
45 the generic dependency finder cannot locate.
47 .. function:: plat_prepare(includes, packages, excludes)
49 Updates the lists of includes, packages and excludes for the current
50 platform. This will add items to these lists based on hardcoded platform
53 .. function:: find_needed_modules([mf[, scripts[, includes[, packages[, warn]]]]])
55 Feeds the given :class:`ModuleGraph <modulegraph.ModuleGraph>` with
56 the *scripts*, *includes* and *packages* and returns the resulting
57 graph. This function will create a new graph when *mf* is not specified