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

Resolve group membership and use in topological ordering #767

Merged
merged 3 commits into from
Mar 14, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions ros_buildfarm/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -511,6 +511,9 @@ def topological_order_packages(packages):
unique_depend_names = set([
d.name for d in all_depends if d.name in decorators_by_name.keys() and
d.evaluated_condition is not False])
unique_depend_names.update([
m for d in decorator.package.group_depends for m in d.members if
d.evaluated_condition is not False])
for name in unique_depend_names:
if name in decorator.depends_for_topological_order:
# avoid function call to improve performance
Expand Down
4 changes: 4 additions & 0 deletions ros_buildfarm/release_job.py
Original file line number Diff line number Diff line change
Expand Up @@ -326,6 +326,10 @@ def _get_and_parse_distribution_cache(index, rosdistro_name, pkg_names):
condition_context = get_package_condition_context(index, rosdistro_name)
for pkg in cached_pkgs.values():
pkg.evaluate_conditions(condition_context)
for pkg in cached_pkgs.values():
for group_depend in pkg.group_depends:
if group_depend.evaluated_condition is not False:
group_depend.extract_group_members(cached_pkgs.values())

# for ROS 2 distributions bloom injects a dependency on ros_workspace
# into almost all packages (except its dependencies)
Expand Down