Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Wrong error message when incorrect --listen specified #187

Open
lhellebr opened this issue Mar 19, 2020 · 0 comments
Open

Wrong error message when incorrect --listen specified #187

lhellebr opened this issue Mar 19, 2020 · 0 comments
Labels
bug Something isn't working
Milestone

Comments

@lhellebr
Copy link

When incorrect value of --listen is specified, the following error is shown:

RuntimeError: Invalid Receptor peer specified: <listen>

Printing the actual value of --listen but mentioning peer instead. Example:

# receptor --config ./config.conf --debug --node-id node -d /tmp/node node --peer=localhost:8881 --listen=tcp://0.0.0.0:8882
INFO 2020-03-19 06:41:51,927 node entrypoints Running as Receptor node with ID: node
ERROR 2020-03-19 06:41:51,927 node __main__ main: an error occured while running receptor
Traceback (most recent call last):
  File "/usr/lib/python3.6/site-packages/receptor/__main__.py", line 59, in main
    config.go()
  File "/usr/lib/python3.6/site-packages/receptor/config.py", line 516, in go
    self._parsed_args.func(self)
  File "/usr/lib/python3.6/site-packages/receptor/entrypoints.py", line 49, in run_as_node
    listen_tasks = controller.enable_server(config.node_listen)
  File "/usr/lib/python3.6/site-packages/receptor/controller.py", line 54, in enable_server
    listener = self.connection_manager.get_listener(url)
  File "/usr/lib/python3.6/site-packages/receptor/connection/manager.py", line 35, in get_listener
    service = parse_peer(listen_url, 'server')
  File "/usr/lib/python3.6/site-packages/receptor/connection/manager.py", line 23, in parse_peer
    raise RuntimeError(f"Invalid Receptor peer specified: {peer}")
RuntimeError: Invalid Receptor peer specified: tcp://0.0.0.0:8882

I understand that --listen value can be considered peer, too, but the error message makes me look for the error in different place then where it actually is (tcp:// protocol in this case).

@matburt matburt added this to the 1.0 Release milestone May 13, 2020
@ghjm ghjm added the bug Something isn't working label May 15, 2020
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants