ros-infrastructure / catkin_pkg

Standalone Python library for the catkin build system.
https://github.com/ros/catkin
Other
47 stars 91 forks source link

Topological sort AssertionError #220

Closed paulbovbel closed 6 years ago

paulbovbel commented 6 years ago

catkin_pkg.topological_sort doesn't seem to be working as expected with group memberships and ROS2 packages.. Hopefully I'm not abusing someething, but I would expect this to work instead of giving an assertion error:

$ wget https://raw.githubusercontent.com/ros2/ros2/master/ros2.repos
$ vcs import . --input ros2.repos
$ python3 -c 'from catkin_pkg.topological_order import topological_order; topological_order(".")'
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/usr/local/lib/python3.5/dist-packages/catkin_pkg/topological_order.py", line 142, in topological_order
    return topological_order_packages(packages, whitelisted=whitelisted, blacklisted=blacklisted, underlay_packages=dict(underlay_packages.values()))
  File "/usr/local/lib/python3.5/dist-packages/catkin_pkg/topological_order.py", line 195, in topological_order_packages
    group_depend.extract_group_members(pkgs)
  File "/usr/local/lib/python3.5/dist-packages/catkin_pkg/group_dependency.py", line 60, in extract_group_members
    assert g.evaluated_condition is not None
AssertionError
dirk-thomas commented 6 years ago

Thank you for reporting this. Please try #221 which should address this problem.