achilles.actions – Asynchronous actions

class achilles.actions.Library(namespace=None)

Action library holds a register of all defined actions

Use it to define and register new actions, grouping them under a common namespace:

from achilles import actions

register = actions.Library('myapp')

@register.action
def foo(request, *args, **kwargs):
    # do stuff
    pass
Parameters:namespace – Unique namespace for this register
achilles.actions.get(name)

Retrieve an action function with the given name. Example:

actions.get('myapp:foo')
Parameters:name – Fully namespaced action name

Previous topic

achilles – Modules Reference

Next topic

achilles.blocks – Dynamically loaded blocks

This Page