class fabric.executor.Executor(collection, config=None, core=None)

Executor subclass which understands Fabric concepts.

Designed to work in tandem with Fabric’s @task/Task, and is capable of acting on information stored on the resulting objects – such as default host lists.

This class is written to be backwards compatible with vanilla Invoke-level tasks, which it simply delegates to its superclass.

Please see the parent class’ documentation for details on most public API members and object lifecycle.


Normalize mixed host-strings-or-kwarg-dicts into kwarg dicts only.

Parameters:hosts – Potentially heterogenous list of host connection values, as per the hosts param to task.
Returns:Homogenous list of Connection init kwarg dicts.
parameterize(call, connection_init_kwargs)

Parameterize a Call with its Context set to a per-host Connection.

  • call – The generic Call being parameterized.
  • connection_init_kwargs – The dict of Connection init params/kwargs to attach to the resulting ConnectionCall.