How to Distribute Commercial Python Applications. Militarizing Your Backyard with Python: Computer Vision and the Squirrel Hordes. Libs and bindings. Inspect – Inspect live objects. The inspect module provides functions for learning about live objects, including modules, classes, instances, functions, and methods.
You can use functions in this module to retrieve the original source code for a function, look at the arguments to a method on the stack, and extract the sort of information useful for producing library documentation for your source code. My own CommandLineApp module uses inspect to determine the valid options to a command line program, as well as any arguments and their names so command line programs are self-documenting and the help text is generated automatically.
Module Information The first kind of introspection supported lets you probe live objects to learn about them. For example, it is possible to discover the classes and functions in a module, the methods of a class, etc. Python Package Manager Index (PyPM) Package Index : PyPI.