summaryrefslogtreecommitdiff
path: root/examples/hello_publisher.py
diff options
context:
space:
mode:
authorOmer Katz <omer.drow@gmail.com>2020-07-13 16:58:06 +0300
committerOmer Katz <omer.drow@gmail.com>2020-07-13 16:58:06 +0300
commit7a6e7cc45b9afe799770313a66c4211d1986ff30 (patch)
tree189c7fa2e7ca9835e14975093c12b7e5d3d8213b /examples/hello_publisher.py
parent016f4accb634ebc3eb8fc66741f23552e5966ea7 (diff)
downloadkombu-7a6e7cc45b9afe799770313a66c4211d1986ff30.tar.gz
pyupgrade
Diffstat (limited to 'examples/hello_publisher.py')
-rw-r--r--examples/hello_publisher.py6
1 files changed, 2 insertions, 4 deletions
diff --git a/examples/hello_publisher.py b/examples/hello_publisher.py
index e6b07361..d6a49048 100644
--- a/examples/hello_publisher.py
+++ b/examples/hello_publisher.py
@@ -1,5 +1,3 @@
-from __future__ import absolute_import, unicode_literals
-
import datetime
from kombu import Connection
@@ -7,7 +5,7 @@ from kombu import Connection
with Connection('amqp://guest:guest@localhost:5672//') as conn:
simple_queue = conn.SimpleQueue('simple_queue')
- message = 'helloworld, sent at {0}'.format(datetime.datetime.today())
+ message = f'helloworld, sent at {datetime.datetime.today()}'
simple_queue.put(message)
- print('Sent: {0}'.format(message))
+ print(f'Sent: {message}')
simple_queue.close()