Did I find the right examples for you? yes no

All Samples(2)  |  Call(1)  |  Derive(0)  |  Import(1)

        def get_history(path, buildout, keys):
    store = shelve.open(path)
    data = {}

    for key in keys:
        action = "removed"
        if " " in key:
            key, action = key.split(" ", 1)
            key, action = key.strip(), action.strip()

        p, k = key.split(":")

        handle = dict(
            removed = handle_list,
            max = handle_max,
            ).get(action, None)

        if not handle:
            raise UserError("'%s' is not a valid tracking mechanism" % action)

        val = None
        if store.has_key(key):
            val = store[key]

        data.setdefault(p, {})
        store[key], data[p][k] = handle(buildout, p, k, val)

    store.close()

    return data
        


src/i/s/isotoma.recipe.postdeploy-0.0.6/isotoma/recipe/postdeploy/recipe.py   isotoma.recipe.postdeploy(Download)
import missingbits
 
from isotoma.recipe.postdeploy.history import get_history
 
class PostDeploy(object):
    def write_removed_yay(self):
        removed = {}
        if "history.track" in self.options:
            removed = get_history(
                self.options['history.db'],