diff options
| author | Ask Solem <ask@celeryproject.org> | 2011-09-22 17:10:13 +0100 |
|---|---|---|
| committer | Ask Solem <ask@celeryproject.org> | 2011-09-22 17:10:13 +0100 |
| commit | c0383c88f535161d02e528227b8d60b62e1ffe32 (patch) | |
| tree | 12b1d57961739a73580611a442d5d04a0285bbb1 /examples/simple_task_queue/client.py | |
| parent | 20ec760e101ea27fb457e4394ce60db47468c054 (diff) | |
| download | kombu-c0383c88f535161d02e528227b8d60b62e1ffe32.tar.gz | |
PEP8ify + pyflakesv1.4.0
Diffstat (limited to 'examples/simple_task_queue/client.py')
| -rw-r--r-- | examples/simple_task_queue/client.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/examples/simple_task_queue/client.py b/examples/simple_task_queue/client.py index 489aa2e6..edf63f76 100644 --- a/examples/simple_task_queue/client.py +++ b/examples/simple_task_queue/client.py @@ -9,6 +9,7 @@ priority_to_routing_key = {"high": "hipri", "mid": "midpri", "low": "lopri"} + def send_as_task(connection, fun, args, kwargs, priority="mid"): payload = {"fun": fun, "args": args, "kwargs": kwargs} routing_key = priority_to_routing_key[priority] @@ -23,6 +24,6 @@ if __name__ == "__main__": from kombu import BrokerConnection from .tasks import hello_task - conection = BrokerConnection("amqp://guest:guest@localhost:5672//") + connection = BrokerConnection("amqp://guest:guest@localhost:5672//") send_as_task(connection, fun=hello_task, args=("Kombu", ), priority="high") |
