Skip to content
This repository was archived by the owner on May 31, 2025. It is now read-only.
This repository was archived by the owner on May 31, 2025. It is now read-only.

rosnode.rosnode_ping fails when node restarted #221

@130s

Description

@130s

As you see below,

  • when rosnode_ping run on python shell, node with old port number (? I'm not really sure what these number stand for) stays the same, which I assume triggers the error.
  • Commandline $ rosnode ping seems to work fine.

Same thing happens when run in python code as you can imagine.


Reproduction and result:

1 Run a node. Say by $ rosrun turtlesim turtlesim_node
2 In a new terminal (term-commandline):

$ rosnode ping /turtlesim
rosnode: node is [/turtlesim]
pinging /turtlesim with a timeout of 3.0s
xmlrpc reply from http://130s-serval:42526/ time=0.695944ms

3 In another terminal (term-pythonshell):

$ python
>>> from rosnode import rosnode_ping
>>> rosnode_ping('/turtlesim', 1)
True

4 Stop a node.
5 On term-commandline:

$ rosnode ping /turtlesim
rosnode: node is [/turtlesim]
pinging /turtlesim with a timeout of 3.0s
ERROR: connection refused to [http://130s-serval:42526/]

6 On term-pythonshell:

>>> rosnode_ping('/turtlesim', 2)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "<string>", line 370, in rosnode_ping
ERROR: connection refused to [http://130s-serval:42526/]

7 Run a node again.
8 On term-commandline:

$ rosnode ping /turtlesim
rosnode: node is [/turtlesim]
pinging /turtlesim with a timeout of 3.0s
xmlrpc reply from http://130s-serval:34981/ time=0.690937ms

9 On term-pythonshell:

>>> rosnode_ping('/turtlesim', 2)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "<string>", line 370, in rosnode_ping
ERROR: connection refused to [http://130s-serval:42526/]

ros-groovy-rosnode 1.9.44-0quantal-20130326-0855-+0000

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions