ownaginatious / amqp-client-cli Goto Github PK
View Code? Open in Web Editor NEWA simple CLI tool for sending amqp messages to exchanges.
License: MIT License
A simple CLI tool for sending amqp messages to exchanges.
License: MIT License
Any suggestion?
c2@ubuntu:~$ amqpcli config --help
Traceback (most recent call last):
File "/usr/local/bin/amqpcli", line 11, in
load_entry_point('amqp-client-cli==0.4.1', 'console_scripts', 'amqpcli')()
File "/usr/lib/python2.7/dist-packages/pkg_resources/init.py", line 480, in load_entry_point
return get_distribution(dist).load_entry_point(group, name)
File "/usr/lib/python2.7/dist-packages/pkg_resources/init.py", line 2693, in load_entry_point
return ep.load()
File "/usr/lib/python2.7/dist-packages/pkg_resources/init.py", line 2324, in load
return self.resolve()
File "/usr/lib/python2.7/dist-packages/pkg_resources/init.py", line 2330, in resolve
module = import(self.module_name, fromlist=['name'], level=0)
File "/home/c2/.local/lib/python2.7/site-packages/amqp_client_cli/main.py", line 34
user = input(f"{Fore.GREEN}User: {Fore.RESET}")
^
SyntaxError: invalid syntax
Attempting to send a message using amqpcli
yields a TypeError: unexpected kwargs: {'ssl': False}
:
$ amqpcli send localhost 5672 amq.direct queue -u guest -m "Test"
Connecting to queue @ localhost:5672... Traceback (most recent call last):
File "/home/tg/.local/bin/amqpcli", line 33, in <module>
sys.exit(load_entry_point('amqp-client-cli==0.3', 'console_scripts', 'amqpcli')())
File "/home/tg/.local/lib/python3.9/site-packages/amqp_client_cli/main.py", line 179, in main
app.run()
File "/home/tg/.local/lib/python3.9/site-packages/clip.py", line 652, in run
self.invoke(self.parse(tokens))
File "/home/tg/.local/lib/python3.9/site-packages/clip.py", line 634, in invoke
self._main.invoke(parsed)
File "/home/tg/.local/lib/python3.9/site-packages/clip.py", line 523, in invoke
self._subcommands[k].invoke(v)
File "/home/tg/.local/lib/python3.9/site-packages/clip.py", line 519, in invoke
self._callback(**{k: v for k, v in iteritems(parsed) if k not in self._subcommands})
File "/home/tg/.local/lib/python3.9/site-packages/amqp_client_cli/main.py", line 112, in amqp_send
connection = pika.BlockingConnection(pika.ConnectionParameters(
File "/home/tg/.local/lib/python3.9/site-packages/pika/connection.py", line 658, in __init__
raise TypeError('unexpected kwargs: %r' % (kwargs,))
TypeError: unexpected kwargs: {'ssl': False}
$ uname -a
Linux vega 5.9.14-arch1-1 #1 SMP PREEMPT Sat, 12 Dec 2020 14:37:12 +0000 x86_64 GNU/Linux
$ python --version
Python 3.9.1
Thanks,
Thilo
Needs to have Pika upgraded to >= 1.1.0 then it seems to run OK
thanks for this fine repo! I think you might want to stress that during authentication, the username and password must be passed quoted:
User: guest
Password
should really be:
User: "guest"
"Password"
Hi, here is my output with the command line from your example.
amqpcli send 127.0.0.1 5672 exchange_a simple_message -m "Hello there" -v vhost -s
Traceback (most recent call last):
File "/usr/local/bin/amqpcli", line 11, in <module>
load_entry_point('amqp-client-cli==0.2.post3', 'console_scripts', 'amqpcli')()
File "/usr/local/lib/python2.7/dist-packages/pkg_resources/__init__.py", line 560, in load_entry_point
return get_distribution(dist).load_entry_point(group, name)
File "/usr/local/lib/python2.7/dist-packages/pkg_resources/__init__.py", line 2648, in load_entry_point
return ep.load()
File "/usr/local/lib/python2.7/dist-packages/pkg_resources/__init__.py", line 2302, in load
return self.resolve()
File "/usr/local/lib/python2.7/dist-packages/pkg_resources/__init__.py", line 2308, in resolve
module = __import__(self.module_name, fromlist=['__name__'], level=0)
File "/usr/local/lib/python2.7/dist-packages/amqp_client_cli/main.py", line 106
print("Connecting to queue @ %s:%s... " % (host, port), end="")
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.