Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

This is a bit of an XY problem situation. You do not need to parse /rosout to get the status of the current goal. You can ask the move base instance what the status of the goal is. Move base API and actionlib python tutorial should get you most of the way to where you want to get.

Of course you you could (but should not) just subscribe to the /rosout topic and filter the messages by the /rosout/name and look for "goal reached" in /rosout/msg. If you do for what ever reason want to proceed with parsing the output use /rosout_agg instead of plain /rosout. /rosout_agg is published by the rosout node, subscribing directly to /rosout would connect your node to all of the nodes that publish to /rosout, which would be basically all of the running nodes.

If having it in "separate Python script" is somehow preventing you from doing this then you would need to elaborate on what you mean by "separate Python script" and why you want to use said script instead of having it in a ros package.