<> = Migration guide = For ROS Noetic Ninjemys these packages have been changed and provide some form of migration notes or tutorials for users which depend on these packages. == Python 3 == ROS Noetic will target Python 3 exclusively. See [[UsingPython3|this guide]] for instructions transitioning your ROS packages from Python 2 to Python 3. == Increase required CMake version to avoid author warning == CMake will issue an author warning about [[https://cmake.org/cmake/help/v3.0/policy/CMP0048.html|CMP0048]] in Debian Buster and Ubuntu Focal. To avoid this warning, increase the minimum CMake version to at least `3.10.2`. See [[https://github.com/RethinkRobotics-opensource/gennodejs/pull/24|RethinkRobotics-opensource/gennodejs#24]] for an example of how to update your package. In your `CMakeLists.txt` make sure the first line requires at least version 3.10.2. If you need to support Debian Stretch, use version 3.7.2 instead. All other systems provide at least 3.10.2. {{{#!highlight cmake cmake_minimum_required(VERSION 3.10.2) }}} == Setuptools instead of Distutils == Catkin prefers to use `setuptools` instead of `distutils` since [[https://github.com/ros/catkin/pull/1048|ros/catkin#1048]]. See [[https://github.com/ros/genlisp/pull/17|ros/genlisp#17]] for an example of how to update your package. In your `setup.py` import `setup` from `setuptools` instead of `distutils-core`. {{{#!highlight python ## Replace this line in your setup.py # from distutils.core import setup ## With this one from setuptools import setup }}} If your repository uses the same branch to release to multiple ROS distros (Melodic, Noetic, etc), then use add conditional build tool dependencies on `python-setuptools` and `python3-setuptools` to your `package.xml` using format 3. {{{#!highlight xml python-setuptools python3-setuptools }}} == Use Orocos KDL and BFL rosdep keys == If your package depends on any Orocos KDL or BFL ROS packages, then starting in ROS Noetic you must change those dependencies to rosdep keys in your `package.xml`. ||'''Old ROS Package''' ||'''Replacement rosdep keys''' || ||orocos_kdl ||liborocos-kdl-dev<
>liborocos-kdl || ||python_orocos_kdl ||python3-pykdl || ||orocos_kinematics_dynamics ||liborocos-kdl-dev<
>liborocos-kdl<
>python3-pykdl || ||bfl ||liborocos-bfl-dev<
>liborocos-bfl || Examples: [[https://github.com/ros/geometry2/pull/447|ros/geometry2#447]], [[https://github.com/ros-planning/robot_pose_ekf/pull/6|ros-planning/robot_pose_ekf#6]] == Use fcl rosdep key instead of libfcl-dev == ROS Noetic provides FCL 0.6, which is ABI and API-incompatible to FCL 0.5. The system-installed `libfcl-dev` might be version 0.5 or 0.6, depending on the particular OS (e.g. Ubuntu Focal has 0.5). To avoid any conflicts in downstream packages, when linking package libraries that are in turn linked against different FCL versions, we suggest to upgrade to FCL 0.6 and use the new rosdep key `fcl` instead of `libfcl-dev` (the `fcl` key corresponds to system package `ros-noetic-fcl`). [[https://github.com/peci1/robot_body_filter/commit/db08750759d5dd93822451a7c2981368c6bd187b#diff-37a67ff78eb7260214b323353263b9af40a2fa98719a1e81937fae0159df87a3|Example of the needed package.xml change]]. Keep in mind that except changing the package.xml keys, you also might need to edit `CMakeLists.txt` to search for version 0.6, and then edit all files that directly use FCL to be compatible with the 0.6 API. == Remove unnecessary package_dir option from setup.py == If your ROS package has a `setup.py` includes `package_dir={'': ''}` and you are seeing the following build error, then remove the `package_dir` argument. [[https://github.com/ros/kdl_parser/pull/36/commits/f8f6d8f9984b4666ea7ef33a757a6aa25e5a004c|Example commit doing this]]. {{{ running install_egg_info error: error in 'egg_base' option: '' does not exist or is not a directory CMake Error at catkin_generated/safe_execute_install.cmake:4 (message): execute_process(/tmp/ws/build_isolated/kdl_parser_py/catkin_generated/python_distutils_install.sh) returned error code Call Stack (most recent call first): cmake_install.cmake:147 (include) }}} This option tells Python where to look for Python packages relative to the setup.py. The argument `package_dir={'': ''}` says the Python packages are in the same directory as the `setup.py`, but in this case it can be removed because [[https://docs.python.org/3.8/distutils/setupscript.html#listing-whole-packages|that is the default behavior]]. '''DO NOT REMOVE if your packages are in another folder next to your `setup.py`, such as `src/my_python_pkg/__init__.py`''' == Joint State Publisher GUI == In previous versions of ROS, the [[joint_state_publisher]] package had a parameter called `use_gui` that would launch a GUI when joint_state_publisher was started. In early 2020 this package was split into a joint_state_publisher and joint_state_publisher_gui package. In Noetic, the `use_gui` parameter has been removed completely, and instead users should explicitly invoke `joint_state_publisher_gui` when they wish to use the GUI. == RViz Python API import == The module to import the RViz python bindings have changed. Change any imports that currently look like this: {{{ import rviz }}} to this {{{ from rviz import bindings as rviz }}} == Use xacro instead of xacro.py == The deprecated `xacro.py` executable has been removed from [[xacro]]. Use `xacro` instead. Here's an example [[https://github.com/ros/urdf_sim_tutorial/pull/8|ros/urdf_sim_tutorial#8]].