'Returns the first index of the given entry point name in the pipeline.
Raises ValueError if the given module is not in the pipeline.'

def index(self, entry_point_name):

    for (i, ctx) in enumerate(self.context.filter_contexts):
        if (ctx.entry_point_name == entry_point_name):
            return i
    raise ValueError(('%s    is    not    in    pipeline' % (entry_point_name,)))
