Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Refactor Node parse() function. #73

Merged
merged 2 commits into from
Sep 23, 2019

Conversation

hidmic
Copy link
Contributor

@hidmic hidmic commented Sep 19, 2019

Precisely what the title says: ignore cmd from ExecuteProcess and parse args properly.

Make use of ignore support in ExecuteProcess.

Signed-off-by: Michel Hidalgo <michel@ekumenlabs.com>
@ivanpauno
Copy link
Member

Depends on ros2/launch#336

kwargs['arguments'] = super()._parse_cmdline(args, parser)
node_name = entity.get_attr('node_name', optional=True)
if node_name is None and 'name' in kwargs:
node_name = kwargs['name']
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is quite strange. So, if you just pass name you're setting the node_name. But if you pass node_name and name, the first send the node name and the second the executable name.
What if someone wants to set the executable name without remapping the node name?

I originally avoided to expose the executable name, because I didn't like <node ... node_name="..." .../>.
But if we want to add it, I think it should look like: <node ... name="..." exec-name="..." .../>.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeap, that change makes absolutely no sense. Thanks for pointing it out. But I'll simply stop doing creative renaming in the parsing function. It's certainly not where we'd want to be. See a4be9d0.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds good. We should probably revisit naming of attributes in other actions ...

Signed-off-by: Michel Hidalgo <michel@ekumenlabs.com>
@hidmic
Copy link
Contributor Author

hidmic commented Sep 23, 2019

CI is in ros2/launch#336.

@hidmic hidmic merged commit 6a5ba39 into master Sep 23, 2019
@delete-merged-branch delete-merged-branch bot deleted the hidmic/execute-process-parse-extension branch September 23, 2019 17:29
@ivanpauno
Copy link
Member

@hidmic Can you update the tutorial and the design document that specifies the XML format?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants