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

Add frontend parsing methods for Node, ExecutableInPackage and FindPackage substitution #23

Merged
merged 32 commits into from Jul 11, 2019

Conversation

ivanpauno
Copy link
Member

@ivanpauno ivanpauno commented May 10, 2019

Add parsing method for Node and ExecutableInPackage.
Add test example of launching a node from xml.

Blocked by ros2/launch#226
Blocked by #33

@ivanpauno ivanpauno requested a review from hidmic May 10, 2019 19:55
@ivanpauno ivanpauno self-assigned this May 10, 2019
@ivanpauno ivanpauno changed the title Ivanpauno/launch frontend Add launch_frontend parsing methods for Node and ExecutableInPackage May 10, 2019
Copy link
Contributor

@hidmic hidmic left a comment

Choose a reason for hiding this comment

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

This looks amazing, great job @ivanpauno !

launch_ros/launch_ros/actions/node.py Outdated Show resolved Hide resolved
test_launch_ros/test/test_launch_ros/xml_frontend/node.xml Outdated Show resolved Hide resolved
@ivanpauno
Copy link
Member Author

Rebased again with master

@ivanpauno
Copy link
Member Author

@hidmic 218d879 and ros2/launch@cd4ff85 handles parameters correctly after #31.
If you're ok with that change, this is ready for be reviewed by someone else.

@ivanpauno
Copy link
Member Author

@hidmic 218d879 and ros2/launch@cd4ff85 handles parameters correctly after #31.
If you're ok with that change, this is ready for be reviewed by someone else.

Reverted both commits after discussing with @hidmic.
See 86bd241 for checking how it looks now.

Copy link
Member

@wjwwood wjwwood left a comment

Choose a reason for hiding this comment

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

This also lgtm!

launch_ros/launch_ros/actions/node.py Outdated Show resolved Hide resolved
@ivanpauno ivanpauno requested a review from hidmic July 2, 2019 20:08
launch_ros/launch_ros/actions/node.py Outdated Show resolved Hide resolved
launch_ros/launch_ros/actions/node.py Outdated Show resolved Hide resolved
launch_ros/launch_ros/actions/node.py Outdated Show resolved Hide resolved
launch_ros/launch_ros/actions/node.py Outdated Show resolved Hide resolved
launch_ros/launch_ros/actions/node.py Outdated Show resolved Hide resolved
import pytest

# Scaping the quote is needed in 'a_string' launch configuration, becuase of how the parser works.
# TODO(ivanpauno): Check if it's possible to avoid that.
Copy link
Contributor

Choose a reason for hiding this comment

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

@ivanpauno is all this quoting for 'a_string' due to substitution grammar parsing? Is that bad for YAML markup?

Copy link
Member Author

Choose a reason for hiding this comment

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

Yeah, the substitution grammar needs the quotes escaped. In YAML markup you have the same problem, but it's not particularly "bad" for it.
The yaml example is in the same file (below the xml example).

Signed-off-by: ivanpauno <ivanpauno@ekumenlabs.com>
Signed-off-by: ivanpauno <ivanpauno@ekumenlabs.com>
Signed-off-by: ivanpauno <ivanpauno@ekumenlabs.com>
Signed-off-by: ivanpauno <ivanpauno@ekumenlabs.com>
Signed-off-by: ivanpauno <ivanpauno@ekumenlabs.com>
Signed-off-by: ivanpauno <ivanpauno@ekumenlabs.com>
Signed-off-by: ivanpauno <ivanpauno@ekumenlabs.com>
Signed-off-by: ivanpauno <ivanpauno@ekumenlabs.com>
Signed-off-by: ivanpauno <ivanpauno@ekumenlabs.com>
…ckage.xml. Move test descriptions in place

Signed-off-by: ivanpauno <ivanpauno@ekumenlabs.com>
Signed-off-by: ivanpauno <ivanpauno@ekumenlabs.com>
This reverts commit 218d879.

Signed-off-by: ivanpauno <ivanpauno@ekumenlabs.com>
Signed-off-by: ivanpauno <ivanpauno@ekumenlabs.com>
ivanpauno and others added 17 commits July 8, 2019 14:54
Signed-off-by: ivanpauno <ivanpauno@ekumenlabs.com>
Signed-off-by: ivanpauno <ivanpauno@ekumenlabs.com>
Signed-off-by: ivanpauno <ivanpauno@ekumenlabs.com>
Signed-off-by: ivanpauno <ivanpauno@ekumenlabs.com>
Signed-off-by: ivanpauno <ivanpauno@ekumenlabs.com>
Signed-off-by: ivanpauno <ivanpauno@ekumenlabs.com>
…ated test.

Signed-off-by: ivanpauno <ivanpauno@ekumenlabs.com>
Signed-off-by: ivan <ivanpauno@gmail.com>
Signed-off-by: ivan <ivanpauno@gmail.com>
Signed-off-by: ivan <ivanpauno@gmail.com>
Signed-off-by: ivanpauno <ivanpauno@ekumenlabs.com>
Signed-off-by: ivanpauno <ivanpauno@ekumenlabs.com>
Signed-off-by: ivanpauno <ivanpauno@ekumenlabs.com>
Signed-off-by: ivanpauno <ivanpauno@ekumenlabs.com>
Signed-off-by: ivanpauno <ivanpauno@ekumenlabs.com>
Signed-off-by: ivanpauno <ivanpauno@ekumenlabs.com>
Signed-off-by: ivanpauno <ivanpauno@ekumenlabs.com>
@ivanpauno
Copy link
Member Author

@hidmic I rebased, because I needed #33.
The new commits since your last review are: a3ca07f, 07f162d, c1c1d6a, 3a95e38.

Copy link
Member

@wjwwood wjwwood left a comment

Choose a reason for hiding this comment

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

New changes lgtm.

Copy link
Contributor

@hidmic hidmic left a comment

Choose a reason for hiding this comment

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

LGTM too!

package = parser.parse_substitution(entity.get_attr('package'))
kwargs['package'] = package
executable = parser.parse_substitution(entity.get_attr('executable'))
kwargs['node_executable'] = executable
Copy link
Contributor

Choose a reason for hiding this comment

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

@ivanpauno just curious, why the two step assignment?

Copy link
Member Author

Choose a reason for hiding this comment

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

Just a bad habit.

Signed-off-by: ivanpauno <ivanpauno@ekumenlabs.com>
@ivanpauno ivanpauno changed the title Add launch_frontend parsing methods for Node and ExecutableInPackage Add frontend parsing methods for Node, ExecutableInPackage. Add FindPackage substitution Jul 11, 2019
@ivanpauno ivanpauno changed the title Add frontend parsing methods for Node, ExecutableInPackage. Add FindPackage substitution Add frontend parsing methods for Node and ExecutableInPackage. Add FindPackage substitution Jul 11, 2019
@ivanpauno ivanpauno changed the title Add frontend parsing methods for Node and ExecutableInPackage. Add FindPackage substitution Add frontend parsing methods for Node, ExecutableInPackage and FindPackage substitution Jul 11, 2019
Copy link
Contributor

@hidmic hidmic left a comment

Choose a reason for hiding this comment

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

LGTM!

@ivanpauno ivanpauno merged commit 5fac112 into master Jul 11, 2019
@delete-merged-branch delete-merged-branch bot deleted the ivanpauno/launch-frontend branch July 11, 2019 16:25
@wjwwood wjwwood mentioned this pull request Jul 23, 2019
34 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants