Module Expr Str Import alias Import alias Import alias Import alias Import alias Assign NameStore ListLoad Assign NameStore Dict Assign NameStore ListLoad FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore Call NameLoad NameLoad Assign NameStore ListComp NameLoad comprehension NameStore NameLoad Call AttributeLoad NameLoad attr Str For NameStore NameLoad body Assign NameStore Call NameLoad NameLoad NameLoad Assign NameStore SubscriptLoad NameLoad Slice Num If Call NameLoad NameLoad body Expr Call AttributeLoad Call AttributeLoad NameLoad attr NameLoad ListLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Return Call AttributeLoad NameLoad attr NameLoad ListLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str If BoolOpOr NameLoad NameLoad body Return Expr Call AttributeLoad NameLoad attr For NameStore NameLoad body If Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad body Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad orelse Raise Call NameLoad BinOpMod Str NameLoad Assign NameStore Call NameLoad NameLoad NameLoad For NameStore NameLoad body TryExcept body Assign NameStore Call NameLoad NameLoad handlers ExceptHandler type TupleLoad NameLoad NameLoad body Raise ExceptHandler body Expr Call AttributeLoad NameLoad attr TupleLoad NameLoad Call AttributeLoad Str attr Call AttributeLoad NameLoad attr Continue For NameStore SubscriptLoad Call AttributeLoad NameLoad attr Str Slice Num body Assign NameStore Call NameLoad NameLoad NameLoad Expr Call NameLoad NameLoad Expr Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str If NameLoad body For NameStore NameLoad body If CompareEq AttributeLoad NameLoad attr NameLoad body Return NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Return SubscriptLoad Call AttributeLoad AttributeLoad NameLoad attr attr SubscriptLoad Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Index Num Index Num decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str If CompareIs NameLoad NameLoad body Assign NameStore ListLoad For NameStore NameLoad body Assign NameStore Call AttributeLoad NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Str Assign NameStore ListComp Call NameLoad NameLoad comprehension NameStore NameLoad Assign NameStore ListComp NameLoad comprehension NameStore NameLoad UnaryOpNot Call AttributeLoad NameLoad attr Str AugAssignAdd NameStore NameLoad Expr Call AttributeLoad NameLoad attr Return NameLoad decorator_list
N/A N/A 
Holds a series of utility functions for cataloguing, retrieving, and
manipulating callback functions and chains.  Refer to the documentation
for which callbacks are available and their behavior.
 N/A os N/A glob N/A sys N/A os.path N/A traceback N/A plugins N/A N/A callbacks N/A N/A bad_plugins N/A catalogue_plugin N/A N/A plugin_module N/A N/A N/A 
    Goes through the plugin's contents and catalogues all the functions
    that start with cb_.  Functions that start with cb_ are callbacks.

    :param plugin_module: the module to catalogue
     N/A listing N/A dir plugin_module N/A listing N/A item N/A item listing N/A N/A item startswith cb_ N/A mem listing N/A N/A func N/A getattr plugin_module mem N/A memadj N/A mem N/A 3 N/A N/A callable func N/A N/A N/A N/A N/A N/A callbacks setdefault memadj N/A append func N/A get_callback_chain N/A N/A chain N/A N/A N/A 
    Returns a list of functions registered with the callback.

    @returns: list of functions registered with the callback (or an
        empty list)
    @rtype: list of functions
     N/A N/A N/A callbacks get chain N/A N/A initialize_plugins N/A N/A plugin_dirs plugin_list N/A N/A N/A 
    Imports and initializes plugins from the directories in the list
    specified by "plugins_dir".  If no such list exists, then we don't
    load any plugins.

    If the user specifies a "load_plugins" list of plugins to load, then
    we explicitly load those plugins in the order they're listed.  If the
    load_plugins key does not exist, then we load all the plugins in the
    plugins directory using an alphanumeric sorting order.

    .. Note::

       If Pyblosxom is part of a long-running process, you must
       restart Pyblosxom in order to pick up any changes to your plugins.

    :param plugin_dirs: the list of directories to add to the sys.path
                        because that's where our plugins are located.

    :param plugin_list: the list of plugins to load, or if None, we'll
                        load all the plugins we find in those dirs.
     N/A N/A plugins bad_plugins N/A N/A N/A N/A N/A callbacks clear N/A mem plugin_dirs N/A N/A N/A N/A N/A os path isdir mem N/A N/A N/A N/A N/A sys path append mem N/A N/A N/A Exception N/A Plugin directory '%s' does not exist.  Please check your config file. mem N/A plugin_list N/A get_plugin_list plugin_list plugin_dirs N/A mem plugin_list N/A N/A N/A N/A _module N/A __import__ mem N/A N/A N/A N/A SystemExit KeyboardInterrupt N/A N/A N/A N/A N/A N/A N/A bad_plugins append N/A mem N/A N/A join N/A N/A traceback format_exc N/A N/A comp N/A N/A N/A mem split . N/A 1 N/A N/A _module N/A getattr _module comp N/A N/A catalogue_plugin _module N/A N/A N/A plugins append _module N/A get_plugin_by_name N/A N/A name N/A N/A N/A 
    This retrieves a plugin instance (it's a Python module instance)
    by name.

    :param name: the name of the plugin to retrieve (ex: "xmlrpc")

    :returns: the Python module instance for the plugin or None
     N/A plugins N/A N/A mem plugins N/A N/A N/A N/A mem __name__ name N/A N/A mem N/A None N/A get_module_name N/A N/A filename N/A N/A N/A 
    Takes a filename and returns the module name from the filename.

    Example: passing in "/blah/blah/blah/module.ext" returns "module"

    :param filename: the filename in question (with a full path)

    :returns: the filename without path or extension
     N/A N/A N/A N/A N/A os path splitext N/A N/A N/A N/A os path split filename N/A 1 N/A 0 N/A get_plugin_list N/A N/A plugin_list plugin_dirs N/A N/A N/A 
    This handles the situation where the user has provided a series of
    plugin dirs, but has not specified which plugins they want to load
    from those dirs.  In this case, we load all possible plugins except
    the ones whose names being with _ .

    :param plugin_list: List of plugins to load

    :param plugin_dirs: A list of directories where plugins can be loaded from

    :return: list of python module names of the plugins to load
     N/A N/A plugin_list None N/A N/A plugin_list N/A N/A mem plugin_dirs N/A N/A file_list N/A N/A glob glob N/A N/A N/A os path join mem *.py N/A file_list N/A N/A get_module_name filename N/A filename file_list N/A file_list N/A plugin N/A plugin file_list N/A N/A N/A plugin startswith _ N/A plugin_list file_list N/A N/A N/A plugin_list sort N/A plugin_list N/A