diff --git a/.github/workflows/binary.yml b/.github/workflows/binary.yml deleted file mode 100644 index 7cae93319f..0000000000 --- a/.github/workflows/binary.yml +++ /dev/null @@ -1,23 +0,0 @@ -name: Build & Test ros2_control with binary install -on: - pull_request: - push: - branches: - - master - schedule: - # Run every morning to detect flakiness and broken dependencies - - cron: '17 8 * * *' - -jobs: - ci_binary: - name: Galactic binary job - runs-on: ubuntu-latest - strategy: - matrix: - env: - - {ROS_DISTRO: galactic, ROS_REPO: main} - - {ROS_DISTRO: galactic, ROS_REPO: testing} - steps: - - uses: actions/checkout@v1 - - uses: ros-industrial/industrial_ci@master - env: ${{matrix.env}} diff --git a/.github/workflows/source.yml b/.github/workflows/ci-coverage-build.yml similarity index 67% rename from .github/workflows/source.yml rename to .github/workflows/ci-coverage-build.yml index 3e7d9ad3d4..6fa6724f64 100644 --- a/.github/workflows/source.yml +++ b/.github/workflows/ci-coverage-build.yml @@ -1,23 +1,26 @@ -name: Build & Test ros2_control with source-based setup +name: Coverage Build on: - push: + pull_request: branches: - master - schedule: - # Run every morning to detect flakiness and broken dependencies - - cron: '17 8 * * *' jobs: - ci_source: - name: Galactic source job + coverage: + name: coverage build runs-on: ubuntu-20.04 strategy: fail-fast: false + env: + ROS_DISTRO: rolling steps: - uses: ros-tooling/setup-ros@v0.2 + with: + required-ros-distributions: ${{ env.ROS_DISTRO }} + - uses: actions/checkout@v3 - uses: ros-tooling/action-ros-ci@v0.2 with: - target-ros2-distro: galactic + target-ros2-distro: ${{ env.ROS_DISTRO }} + import-token: ${{ secrets.GITHUB_TOKEN }} # build all packages listed in the meta package package-name: controller_interface @@ -27,9 +30,9 @@ jobs: ros2controlcli ros2_control ros2_control_test_assets + transmission_interface vcs-repo-file-url: | - https://raw.githubusercontent.com/ros2/ros2/galactic/ros2.repos - https://raw.githubusercontent.com/${{ github.repository }}/${{ github.sha }}/ros2_control/ros2_control.repos + https://raw.githubusercontent.com/${{ github.repository }}/${{ github.sha }}/ros2_control-not-released.${{ env.ROS_DISTRO }}.repos?token=${{ secrets.GITHUB_TOKEN }} colcon-defaults: | { "build": { @@ -37,7 +40,8 @@ jobs: } } colcon-mixin-repository: https://raw.githubusercontent.com/colcon/colcon-mixin-repository/master/index.yaml - - uses: codecov/codecov-action@v1 + skip-tests: true + - uses: codecov/codecov-action@v1.0.14 with: file: ros_ws/lcov/total_coverage.info flags: unittests diff --git a/.github/workflows/format.yml b/.github/workflows/ci-format.yml similarity index 72% rename from .github/workflows/format.yml rename to .github/workflows/ci-format.yml index c6ea8465a8..77c35301d1 100644 --- a/.github/workflows/format.yml +++ b/.github/workflows/ci-format.yml @@ -6,21 +6,18 @@ name: Format on: workflow_dispatch: pull_request: - push: - branches: - - master jobs: pre-commit: name: Format runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v3 - uses: actions/setup-python@v2 with: python-version: 3.9.7 - - name: Install clang-format-10 - run: sudo apt-get install clang-format-10 cppcheck + - name: Install system hooks + run: sudo apt install -qq clang-format-11 cppcheck - uses: pre-commit/action@v2.0.3 with: extra_args: --all-files --hook-stage manual diff --git a/.github/workflows/lint.yml b/.github/workflows/ci-ros-lint.yml similarity index 95% rename from .github/workflows/lint.yml rename to .github/workflows/ci-ros-lint.yml index c35606dfa6..55e1dad0c9 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/ci-ros-lint.yml @@ -11,7 +11,7 @@ jobs: matrix: linter: [copyright, cppcheck, lint_cmake] steps: - - uses: actions/checkout@v1 + - uses: actions/checkout@v3 - uses: ros-tooling/setup-ros@v0.2 - uses: ros-tooling/action-ros-lint@v0.1 with: @@ -33,7 +33,7 @@ jobs: strategy: fail-fast: false steps: - - uses: actions/checkout@v1 + - uses: actions/checkout@v3 - uses: ros-tooling/setup-ros@v0.2 - uses: ros-tooling/action-ros-lint@v0.1 with: diff --git a/.github/workflows/foxy-abi-compatibility.yml b/.github/workflows/foxy-abi-compatibility.yml new file mode 100644 index 0000000000..40b1e1133f --- /dev/null +++ b/.github/workflows/foxy-abi-compatibility.yml @@ -0,0 +1,17 @@ +name: ABI Compatibility Check +on: + pull_request: + branches: + - foxy + +jobs: + abi_check: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - uses: ros-industrial/industrial_ci@master + env: + ROS_DISTRO: foxy + ROS_REPO: main + ABICHECK_URL: github:${{ github.repository }}#${{ github.base_ref }} + NOT_TEST_BUILD: true diff --git a/.github/workflows/foxy-binary-build.yml b/.github/workflows/foxy-binary-build.yml new file mode 100644 index 0000000000..da67426ec5 --- /dev/null +++ b/.github/workflows/foxy-binary-build.yml @@ -0,0 +1,22 @@ +name: Foxy Binary Build +# author: Denis Štogl +# description: 'Build & test all dependencies from released (binary) packages.' + +on: + pull_request: + branches: + - foxy + push: + branches: + - foxy + schedule: + # Run every morning to detect flakiness and broken dependencies + - cron: '03 1 * * *' + +jobs: + binary: + uses: ./.github/workflows/reusable-industrial-ci-with-cache.yml + with: + ros_distro: foxy + upstream_workspace: ros2_control-not-released.foxy.repos + ref_for_scheduled_build: foxy diff --git a/.github/workflows/foxy-semi-binary-build.yml b/.github/workflows/foxy-semi-binary-build.yml new file mode 100644 index 0000000000..93f75616d3 --- /dev/null +++ b/.github/workflows/foxy-semi-binary-build.yml @@ -0,0 +1,21 @@ +name: Foxy Semi-Binary Build +# description: 'Build & test that compiles the main dependencies from source.' + +on: + pull_request: + branches: + - foxy + push: + branches: + - foxy + schedule: + # Run every morning to detect flakiness and broken dependencies + - cron: '33 1 * * *' + +jobs: + semi_binary: + uses: ./.github/workflows/reusable-industrial-ci-with-cache.yml + with: + ros_distro: foxy + upstream_workspace: ros2_control.foxy.repos + ref_for_scheduled_build: foxy diff --git a/.github/workflows/foxy-source-build.yml b/.github/workflows/foxy-source-build.yml new file mode 100644 index 0000000000..94be8d8b57 --- /dev/null +++ b/.github/workflows/foxy-source-build.yml @@ -0,0 +1,15 @@ +name: Foxy Source Build +on: + push: + branches: + - foxy + schedule: + # Run every day to detect flakiness and broken dependencies + - cron: '03 3 * * *' + +jobs: + source: + uses: ./.github/workflows/reusable-ros-tooling-source-build.yml + with: + ros_distro: foxy + ref: foxy diff --git a/.github/workflows/galactic-abi-compatibility.yml b/.github/workflows/galactic-abi-compatibility.yml new file mode 100644 index 0000000000..41c663dd9c --- /dev/null +++ b/.github/workflows/galactic-abi-compatibility.yml @@ -0,0 +1,17 @@ +name: ABI Compatibility Check +on: + pull_request: + branches: + - galactic + +jobs: + abi_check: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - uses: ros-industrial/industrial_ci@master + env: + ROS_DISTRO: galactic + ROS_REPO: main + ABICHECK_URL: github:${{ github.repository }}#${{ github.base_ref }} + NOT_TEST_BUILD: true diff --git a/.github/workflows/galactic-binary-build.yml b/.github/workflows/galactic-binary-build.yml new file mode 100644 index 0000000000..97f8a8f231 --- /dev/null +++ b/.github/workflows/galactic-binary-build.yml @@ -0,0 +1,22 @@ +name: Galactic Binary Build +# author: Denis Štogl +# description: 'Build & test all dependencies from released (binary) packages.' + +on: + pull_request: + branches: + - galactic + push: + branches: + - galactic + schedule: + # Run every morning to detect flakiness and broken dependencies + - cron: '03 1 * * *' + +jobs: + binary: + uses: ./.github/workflows/reusable-industrial-ci-with-cache.yml + with: + ros_distro: galactic + upstream_workspace: ros2_control-not-released.galactic.repos + ref_for_scheduled_build: galactic diff --git a/.github/workflows/galactic-semi-binary-build.yml b/.github/workflows/galactic-semi-binary-build.yml new file mode 100644 index 0000000000..9e7073e263 --- /dev/null +++ b/.github/workflows/galactic-semi-binary-build.yml @@ -0,0 +1,21 @@ +name: Galactic Semi-Binary Build +# description: 'Build & test that compiles the main dependencies from source.' + +on: + pull_request: + branches: + - galactic + push: + branches: + - galactic + schedule: + # Run every morning to detect flakiness and broken dependencies + - cron: '33 1 * * *' + +jobs: + semi_binary: + uses: ./.github/workflows/reusable-industrial-ci-with-cache.yml + with: + ros_distro: galactic + upstream_workspace: ros2_control.galactic.repos + ref_for_scheduled_build: galactic diff --git a/.github/workflows/galactic-source-build.yml b/.github/workflows/galactic-source-build.yml new file mode 100644 index 0000000000..d1c3aa97e8 --- /dev/null +++ b/.github/workflows/galactic-source-build.yml @@ -0,0 +1,15 @@ +name: Galactic Source Build +on: + push: + branches: + - galactic + schedule: + # Run every day to detect flakiness and broken dependencies + - cron: '03 3 * * *' + +jobs: + source: + uses: ./.github/workflows/reusable-ros-tooling-source-build.yml + with: + ros_distro: galactic + ref: galactic diff --git a/.github/workflows/prerelease-check.yml b/.github/workflows/prerelease-check.yml new file mode 100644 index 0000000000..b9460bda47 --- /dev/null +++ b/.github/workflows/prerelease-check.yml @@ -0,0 +1,39 @@ +name: Pre-Release Check + +on: + workflow_dispatch: + inputs: + ros_distro: + description: 'Chose ROS distribution' + required: true + default: 'rolling' + type: choice + options: + - foxy + - galactic + - humble + - rolling + branch: + description: 'Chose branch for distro' + required: true + default: 'master' + type: choice + options: + - foxy + - galactic + - humble + - master + +jobs: + pre_release: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + with: + ref: ${{ github.event.inputs.branch }} + - name: industrial_ci + uses: ros-industrial/industrial_ci@master + env: + ROS_DISTRO: ${{ github.event.inputs.ros_distro }} + PRERELEASE: true + BASEDIR: ${{ github.workspace }}/.work diff --git a/.github/workflows/prerelease.yaml b/.github/workflows/prerelease.yaml deleted file mode 100644 index b4a7b6f585..0000000000 --- a/.github/workflows/prerelease.yaml +++ /dev/null @@ -1,26 +0,0 @@ -# This config uses industrial_ci (https://github.com/ros-industrial/industrial_ci.git). -# For troubleshooting, see readme (https://github.com/ros-industrial/industrial_ci/blob/master/README.rst) - -name: pre-release - -on: - workflow_dispatch: - -jobs: - default: - strategy: - fail-fast: false - matrix: - distro: [galactic, rolling] - - env: - ROS_DISTRO: ${{ matrix.distro }} - PRERELEASE: true - BASEDIR: ${{ github.workspace }}/.work - - name: "${{ matrix.distro }}" - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - - name: industrial_ci - uses: ros-industrial/industrial_ci@master diff --git a/.github/workflows/reusable-industrial-ci-with-cache.yml b/.github/workflows/reusable-industrial-ci-with-cache.yml new file mode 100644 index 0000000000..9d2722099d --- /dev/null +++ b/.github/workflows/reusable-industrial-ci-with-cache.yml @@ -0,0 +1,106 @@ +name: Reusable industrial_ci Workflow with Cache +# Reusable action to simplify dealing with ROS/ROS2 industrial_ci builds with cache +# author: Denis Štogl + +on: + workflow_call: + inputs: + ref_for_scheduled_build: + description: 'Reference on which the repo should be checkout for scheduled build. Usually is this name of a branch or a tag.' + default: '' + required: false + type: string + + upstream_workspace: + description: 'UPSTREAM_WORKSPACE variable for industrial_ci. Usually path to local .repos file.' + required: true + type: string + ros_distro: + description: 'ROS_DISTRO variable for industrial_ci' + required: true + type: string + ros_repo: + description: 'ROS_REPO to run for industrial_ci. Possible values: "all", "main", "testing"' + default: 'all' + required: false + type: string + os_code_name: + description: 'OS_CODE_NAME variable for industrial_ci' + default: '' + required: false + type: string + before_install_upstream_dependencies: + description: 'BEFORE_INSTALL_UPSTREAM_DEPENDENCIES variable for industrial_ci' + default: '' + required: false + type: string + + ccache_dir: + description: 'Local path to store cache (from "github.workspace"). For standard industrial_ci configuration do not have to be changed' + default: '.ccache' + required: false + type: string + basedir: + description: 'Local path to workspace base directory to cache (from "github.workspace"). For standard industrial_ci configuration do not have to be changed' + default: '.work' + required: false + type: string + + +jobs: + reusable_industrial_ci_with_cache: + name: ${{ matrix.ROS_REPO }} ${{ inputs.ros_distro }} ${{ inputs.os_code_name }} + strategy: + fail-fast: false + matrix: + ROS_REPO: [ main, testing ] + runs-on: ubuntu-latest + env: + CCACHE_DIR: ${{ github.workspace }}/${{ inputs.ccache_dir }} + BASEDIR: ${{ github.workspace }}/${{ inputs.basedir }} + CACHE_PREFIX: ${{ inputs.ros_distro }}-${{ inputs.os_code_name }}-${{ matrix.ROS_REPO }}-${{ github.job }} + steps: + - name: Checkout ${{ inputs.ref }} when build is not scheduled + if: ${{ (inputs.ros_repo == 'all' || inputs.ros_repo == matrix.ROS_REPO) && github.event_name != 'schedule' }} + uses: actions/checkout@v3 + - name: Checkout ${{ inputs.ref }} on scheduled build + if: ${{ (inputs.ros_repo == 'all' || inputs.ros_repo == matrix.ROS_REPO) && github.event_name == 'schedule' }} + uses: actions/checkout@v3 + with: + ref: ${{ inputs.ref_for_scheduled_build }} + - name: cache target_ws + if: ${{ ! matrix.env.CCOV && (inputs.ros_repo == 'all' || inputs.ros_repo == matrix.ROS_REPO) }} + uses: pat-s/always-upload-cache@v2.1.5 + with: + path: ${{ env.BASEDIR }}/target_ws + key: target_ws-${{ env.CACHE_PREFIX }}-${{ hashFiles('**/CMakeLists.txt', '**/package.xml') }}-${{ github.run_id }} + restore-keys: | + target_ws-${{ env.CACHE_PREFIX }}-${{ hashFiles('**/CMakeLists.txt', '**/package.xml') }} + - name: cache ccache + if: ${{ inputs.ros_repo == 'all' || inputs.ros_repo == matrix.ROS_REPO }} + uses: pat-s/always-upload-cache@v2.1.5 + with: + path: ${{ env.CCACHE_DIR }} + key: ccache-${{ env.CACHE_PREFIX }}-${{ github.sha }}-${{ github.run_id }} + restore-keys: | + ccache-${{ env.CACHE_PREFIX }}-${{ github.sha }} + ccache-${{ env.CACHE_PREFIX }} + - if: ${{ inputs.ros_repo == 'all' || inputs.ros_repo == matrix.ROS_REPO }} + uses: 'ros-industrial/industrial_ci@master' + env: + UPSTREAM_WORKSPACE: ${{ inputs.upstream_workspace }} + ROS_DISTRO: ${{ inputs.ros_distro }} + ROS_REPO: ${{ matrix.ROS_REPO }} + OS_CODE_NAME: ${{ inputs.os_code_name }} + BEFORE_INSTALL_UPSTREAM_DEPENDENCIES: ${{ inputs.before_install_upstream_dependencies }} + - name: prepare target_ws for cache + if: ${{ always() && ! matrix.env.CCOV && (inputs.ros_repo == 'all' || inputs.ros_repo == matrix.ROS_REPO) }} + run: | + du -sh ${{ env.BASEDIR }}/target_ws + sudo find ${{ env.BASEDIR }}/target_ws -wholename '*/test_results/*' -delete + sudo rm -rf ${{ env.BASEDIR }}/target_ws/src + du -sh ${{ env.BASEDIR }}/target_ws + - name: Is job skipped? + if: ${{ ! (inputs.ros_repo == 'all' || inputs.ros_repo == matrix.ROS_REPO) }} + run: | + echo "This job is skpped!" diff --git a/.github/workflows/reusable-ros-tooling-source-build.yml b/.github/workflows/reusable-ros-tooling-source-build.yml new file mode 100644 index 0000000000..71afebac1e --- /dev/null +++ b/.github/workflows/reusable-ros-tooling-source-build.yml @@ -0,0 +1,50 @@ +name: Reusable industrial_ci Workflow with Cache +# Reusable action to simplify dealing with ROS/ROS2 industrial_ci builds with cache +# author: Denis Štogl + +on: + workflow_call: + inputs: + ros_distro: + description: 'ROS2 distribution name' + required: true + type: string + ref: + description: 'Reference on which the repo should be checkout. Usually is this name of a branch or a tag.' + required: true + type: string + +jobs: + reusable_ros_tooling_source_build: + name: ${{ inputs.ros_distro }} ubuntu-20.04 + runs-on: ubuntu-20.04 + strategy: + fail-fast: false + steps: + - uses: ros-tooling/setup-ros@v0.3 + with: + required-ros-distributions: ${{ inputs.ros_distro }} + - uses: actions/checkout@v3 + with: + ref: ${{ inputs.ref }} + - uses: ros-tooling/action-ros-ci@v0.2 + with: + target-ros2-distro: ${{ inputs.ros_distro }} + # build all packages listed in the meta package + package-name: + controller_interface + controller_manager + controller_manager_msgs + hardware_interface + ros2controlcli + ros2_control + ros2_control_test_assets + transmission_interface + vcs-repo-file-url: | + https://raw.githubusercontent.com/ros2/ros2/${{ inputs.ros_distro }}/ros2.repos + https://raw.githubusercontent.com/${{ github.repository }}/${{ github.sha }}/ros2_control.${{ inputs.ros_distro }}.repos?token=${{ secrets.GITHUB_TOKEN }} + colcon-mixin-repository: https://raw.githubusercontent.com/colcon/colcon-mixin-repository/master/index.yaml + - uses: actions/upload-artifact@v1 + with: + name: colcon-logs-ubuntu-20.04 + path: ros_ws/log diff --git a/.github/workflows/rolling-abi-compatibility-last-focal.yml b/.github/workflows/rolling-abi-compatibility-last-focal.yml new file mode 100644 index 0000000000..80433e2494 --- /dev/null +++ b/.github/workflows/rolling-abi-compatibility-last-focal.yml @@ -0,0 +1,21 @@ +name: ABI Compatibility Check - Last Focal +on: + pull_request: + branches: + - master + +jobs: + abi_check: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - uses: ros-industrial/industrial_ci@master + env: + ROS_DISTRO: rolling + ROS_REPO: main + ABICHECK_URL: github:${{ github.repository }}#${{ github.base_ref }} + NOT_TEST_BUILD: true + OS_CODE_NAME: focal + BEFORE_INSTALL_UPSTREAM_DEPENDENCIES: | + export ROSDISTRO_INDEX_URL=https://raw.githubusercontent.com/ros/rosdistro/rolling/2022-01-28/index-v4.yaml + rosdep update diff --git a/.github/workflows/rolling-abi-compatibility.yml b/.github/workflows/rolling-abi-compatibility.yml new file mode 100644 index 0000000000..dc797d7718 --- /dev/null +++ b/.github/workflows/rolling-abi-compatibility.yml @@ -0,0 +1,18 @@ +name: ABI Compatibility Check +on: + workflow_dispatch: + pull_request: + branches: + - master + +jobs: + abi_check: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + - uses: ros-industrial/industrial_ci@master + env: + ROS_DISTRO: rolling + ROS_REPO: main + ABICHECK_URL: github:${{ github.repository }}#${{ github.base_ref }} + NOT_TEST_BUILD: true diff --git a/.github/workflows/rolling-binary-build-last-focal.yml b/.github/workflows/rolling-binary-build-last-focal.yml new file mode 100644 index 0000000000..d9bfc0e334 --- /dev/null +++ b/.github/workflows/rolling-binary-build-last-focal.yml @@ -0,0 +1,27 @@ +name: Rolling Binary Build - Last Focal +# author: Denis Štogl +# description: 'Build & test all dependencies from released (binary) packages.' + +on: + pull_request: + branches: + - master + push: + branches: + - master + schedule: + # Run every morning to detect flakiness and broken dependencies + - cron: '03 1 * * *' + +jobs: + binary: + uses: ./.github/workflows/reusable-industrial-ci-with-cache.yml + with: + ros_distro: rolling + upstream_workspace: ros2_control-not-released.rolling.repos + ref_for_scheduled_build: master + ros_repo: main + os_code_name: focal + before_install_upstream_dependencies: | + export ROSDISTRO_INDEX_URL=https://raw.githubusercontent.com/ros/rosdistro/rolling/2022-01-28/index-v4.yaml + rosdep update diff --git a/.github/workflows/rolling-binary-build.yml b/.github/workflows/rolling-binary-build.yml new file mode 100644 index 0000000000..419d78e850 --- /dev/null +++ b/.github/workflows/rolling-binary-build.yml @@ -0,0 +1,22 @@ +name: Rolling Binary Build +# author: Denis Štogl +# description: 'Build & test all dependencies from released (binary) packages.' + +on: + pull_request: + branches: + - master + push: + branches: + - master + schedule: + # Run every morning to detect flakiness and broken dependencies + - cron: '03 1 * * *' + +jobs: + binary: + uses: ./.github/workflows/reusable-industrial-ci-with-cache.yml + with: + ros_distro: rolling + upstream_workspace: ros2_control-not-released.rolling.repos + ref_for_scheduled_build: master diff --git a/.github/workflows/rolling-rhel-binary-build.yml b/.github/workflows/rolling-rhel-binary-build.yml new file mode 100644 index 0000000000..c7d1ffc675 --- /dev/null +++ b/.github/workflows/rolling-rhel-binary-build.yml @@ -0,0 +1,30 @@ +name: Rolling RHEL Binary Build +on: + pull_request: + branches: + - master + push: + branches: + - master + schedule: + # Run every day to detect flakiness and broken dependencies + - cron: '03 1 * * *' + + +jobs: + rolling_rhel_binary: + name: Rolling RHEL binary build + runs-on: ubuntu-latest + env: + ROS_DISTRO: rolling + container: jaronl/ros:rolling-alma + steps: + - uses: actions/checkout@v3 + with: + path: src/ros2_control + - run: | + rosdep update + rosdep install -iy --from-path src/ros2_control + source /opt/ros/${{ env.ROS_DISTRO }}/setup.bash + colcon build + colcon test diff --git a/.github/workflows/rolling-semi-binary-build-last-focal.yml b/.github/workflows/rolling-semi-binary-build-last-focal.yml new file mode 100644 index 0000000000..04538e34b8 --- /dev/null +++ b/.github/workflows/rolling-semi-binary-build-last-focal.yml @@ -0,0 +1,26 @@ +name: Rolling Semi-Binary Build - Last Focal +# description: 'Build & test that compiles the main dependencies from source.' + +on: + pull_request: + branches: + - master + push: + branches: + - master + schedule: + # Run every morning to detect flakiness and broken dependencies + - cron: '33 1 * * *' + +jobs: + semi_binary: + uses: ./.github/workflows/reusable-industrial-ci-with-cache.yml + with: + ros_distro: rolling + upstream_workspace: ros2_control.rolling.repos + ref_for_scheduled_build: master + ros_repo: main + os_code_name: focal + before_install_upstream_dependencies: | + export ROSDISTRO_INDEX_URL=https://raw.githubusercontent.com/ros/rosdistro/rolling/2022-01-28/index-v4.yaml + rosdep update diff --git a/.github/workflows/rolling-semi-binary-build.yml b/.github/workflows/rolling-semi-binary-build.yml new file mode 100644 index 0000000000..c6b0535ef9 --- /dev/null +++ b/.github/workflows/rolling-semi-binary-build.yml @@ -0,0 +1,21 @@ +name: Rolling Semi-Binary Build +# description: 'Build & test that compiles the main dependencies from source.' + +on: + pull_request: + branches: + - master + push: + branches: + - master + schedule: + # Run every morning to detect flakiness and broken dependencies + - cron: '33 1 * * *' + +jobs: + semi_binary: + uses: ./.github/workflows/reusable-industrial-ci-with-cache.yml + with: + ros_distro: rolling + upstream_workspace: ros2_control.rolling.repos + ref_for_scheduled_build: master diff --git a/.github/workflows/rolling-source-build.yml b/.github/workflows/rolling-source-build.yml new file mode 100644 index 0000000000..0a0ae8de43 --- /dev/null +++ b/.github/workflows/rolling-source-build.yml @@ -0,0 +1,15 @@ +name: Rolling Source Build +on: + push: + branches: + - master + schedule: + # Run every day to detect flakiness and broken dependencies + - cron: '03 3 * * *' + +jobs: + source: + uses: ./.github/workflows/reusable-ros-tooling-source-build.yml + with: + ros_distro: rolling + ref: master diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index f50ab38d15..8c718c2ed7 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -16,7 +16,7 @@ repos: # Standard hooks - repo: https://github.com/pre-commit/pre-commit-hooks - rev: v3.4.0 + rev: v4.1.0 hooks: - id: check-added-large-files - id: check-ast @@ -36,7 +36,7 @@ repos: # Python hooks - repo: https://github.com/asottile/pyupgrade - rev: v2.12.0 + rev: v2.31.1 hooks: - id: pyupgrade args: [--py36-plus] @@ -49,7 +49,7 @@ repos: args: ["--ignore=D100,D101,D102,D103,D104,D105,D106,D107,D203,D212,D404"] - repo: https://github.com/pycqa/flake8 - rev: 3.9.0 + rev: 4.0.1 hooks: - id: flake8 args: ["--extend-ignore=E501"] @@ -110,14 +110,14 @@ repos: # Docs - RestructuredText hooks - repo: https://github.com/PyCQA/doc8 - rev: 0.9.0a1 + rev: 0.10.1 hooks: - id: doc8 args: ['--max-line-length=100', '--ignore=D001'] exclude: CHANGELOG\.rst$ - repo: https://github.com/pre-commit/pygrep-hooks - rev: v1.8.0 + rev: v1.9.0 hooks: - id: rst-backticks exclude: CHANGELOG\.rst$ @@ -127,7 +127,7 @@ repos: # Spellcheck in comments and docs # skipping of *.svg files is not working... - repo: https://github.com/codespell-project/codespell - rev: v2.0.0 + rev: v2.1.0 hooks: - id: codespell args: ['--write-changes'] diff --git a/README.md b/README.md index 0428e89e37..a4a55c7c87 100644 --- a/README.md +++ b/README.md @@ -2,17 +2,35 @@ [![Licence](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://opensource.org/licenses/Apache-2.0) -| | Foxy | Galactic | Rolling -|:-------:|:-------:|:-------:|:-------:| -| Branch | [`foxy`](https://github.com/ros-controls/ros2_control/tree/foxy) |[`master`](https://github.com/ros-controls/ros2_control/tree/master) | TBD -| CI | TBD| Linux: [![Build Status](https://github.com/ros-controls/ros2_control/workflows/Test%20ros2_control/badge.svg)](https://github.com/ros-controls/ros2_control/actions?query=workflow%3A"Test%20ros2_control")| TBD | -| Linters | TBD| [![Linters Status](https://github.com/ros-controls/ros2_control/workflows/Lint%20ros2_control/badge.svg)](https://github.com/ros-controls/ros2_control/actions?query=workflow%3A"Lint+ros2_control")| TBD | - - -## About This package is a part of the ros2_control framework. For more, please check the [documentation](https://ros-controls.github.io/control.ros.org/). + +## Build status + +ROS2 Distro | Branch | Build status | Documentation | Released packages +:---------: | :----: | :----------: | :-----------: | :---------------: +**Rolling** | [`master`](https://github.com/ros-controls/ros2_control/tree/rolling) | [![Rolling Binary Build](https://github.com/ros-controls/ros2_control/actions/workflows/rolling-binary-build.yml/badge.svg?branch=master)](https://github.com/ros-controls/ros2_control/actions/workflows/rolling-binary-build.yml?branch=master)
[![Rolling Semi-Binary Build](https://github.com/ros-controls/ros2_control/actions/workflows/rolling-semi-binary-build.yml/badge.svg?branch=master)](https://github.com/ros-controls/ros2_control/actions/workflows/rolling-semi-binary-build.yml?branch=master)
[![Rolling Source Build](https://github.com/ros-controls/ros2_control/actions/workflows/rolling-source-build.yml/badge.svg?branch=master)](https://github.com/ros-controls/ros2_control/actions/workflows/rolling-source-build.yml?branch=master) | [Documentation](https://control.ros.org)
[API Reference](https://control.ros.org/rolling/api/) | [ros2_control](https://index.ros.org/p/ros2_control/#rolling) +**Rolling - last Focal** | [`master`](https://github.com/ros-controls/ros2_control/tree/rolling) | [![Rolling Binary Build](https://github.com/ros-controls/ros2_control/actions/workflows/rolling-binary-build-last-focal.yml/badge.svg?branch=master)](https://github.com/ros-controls/ros2_control/actions/workflows/rolling-binary-build-last-focal.yml?branch=master)
[![Rolling Semi-Binary Build](https://github.com/ros-controls/ros2_control/actions/workflows/rolling-semi-binary-build-last-focal.yml/badge.svg?branch=master)](https://github.com/ros-controls/ros2_control/actions/workflows/rolling-semi-binary-build-last-focal.yml?branch=master) | [Documentation](https://control.ros.org)
[API Reference](https://control.ros.org/rolling/api/) | [ros2_control](https://index.ros.org/p/ros2_control/#rolling) +**Galactic** | [`galactic`](https://github.com/ros-controls/ros2_control/tree/galactic) | [![Galactic Binary Build](https://github.com/ros-controls/ros2_control/actions/workflows/galactic-binary-build.yml/badge.svg?branch=galactic)](https://github.com/ros-controls/ros2_control/actions/workflows/galactic-binary-build.yml?branch=galactic)
[![Galactic Semi-Binary Build](https://github.com/ros-controls/ros2_control/actions/workflows/galactic-semi-binary-build.yml/badge.svg?branch=galactic)](https://github.com/ros-controls/ros2_control/actions/workflows/galactic-semi-binary-build.yml?branch=galactic)
[![Galactic Source Build](https://github.com/ros-controls/ros2_control/actions/workflows/galactic-source-build.yml/badge.svg?branch=galactic)](https://github.com/ros-controls/ros2_control/actions/workflows/galactic-source-build.yml?branch=galactic) | [Documentation](https://control.ros.org)
[API Reference](https://control.ros.org/rolling/api/) | [ros2_control](https://index.ros.org/p/ros2_control/#galactic) +**Foxy** | [`foxy`](https://github.com/ros-controls/ros2_control/tree/foxy) | [![Foxy Binary Build](https://github.com/ros-controls/ros2_control/actions/workflows/foxy-binary-build.yml/badge.svg?branch=foxy)](https://github.com/ros-controls/ros2_control/actions/workflows/foxy-binary-build.yml?branch=foxy)
[![Foxy Semi-Binary Build](https://github.com/ros-controls/ros2_control/actions/workflows/foxy-semi-binary-build.yml/badge.svg?branch=foxy)](https://github.com/ros-controls/ros2_control/actions/workflows/foxy-semi-binary-build.yml?branch=foxy)
[![Foxy Source Build](https://github.com/ros-controls/ros2_control/actions/workflows/foxy-source-build.yml/badge.svg?branch=foxy)](https://github.com/ros-controls/ros2_control/actions/workflows/foxy-source-build.yml?branch=foxy) | [Documentation](https://control.ros.org)
[API Reference](https://control.ros.org/rolling/api/) | [ros2_control](https://index.ros.org/p/ros2_control/#foxy) + +### Explanation of different build types + +**NOTE**: There are three build stages checking current and future compatibility of the package. + +1. Binary builds - against released packages (main and testing) in ROS distributions. Shows that direct local build is possible. + + Uses repos file: `src/$NAME$/$NAME$-not-released..repos` + +1. Semi-binary builds - against released core ROS packages (main and testing), but the immediate dependencies are pulled from source. + Shows that local build with dependencies is possible and if fails there we can expect that after the next package sync we will not be able to build. + + Uses repos file: `src/$NAME$/$NAME$.repos` + +1. Source build - also core ROS packages are build from source. It shows potential issues in the mid future. + + ## Docker images There are a few published docker images that come with the latest releases. More information about them can be found in the `.docker` folder. You can pull them under these tags: `ghcr.io/ros-controls/ros2_control_release` or `ghcr.io/ros-controls/ros2_control_source`. diff --git a/ros2_control-not-released.foxy.repos b/ros2_control-not-released.foxy.repos new file mode 100644 index 0000000000..56f46b6f79 --- /dev/null +++ b/ros2_control-not-released.foxy.repos @@ -0,0 +1 @@ +repositories: diff --git a/ros2_control-not-released.galactic.repos b/ros2_control-not-released.galactic.repos new file mode 100644 index 0000000000..56f46b6f79 --- /dev/null +++ b/ros2_control-not-released.galactic.repos @@ -0,0 +1 @@ +repositories: diff --git a/ros2_control-not-released.rolling.repos b/ros2_control-not-released.rolling.repos new file mode 100644 index 0000000000..56f46b6f79 --- /dev/null +++ b/ros2_control-not-released.rolling.repos @@ -0,0 +1 @@ +repositories: diff --git a/ros2_control.foxy.repos b/ros2_control.foxy.repos new file mode 100644 index 0000000000..a52f653b54 --- /dev/null +++ b/ros2_control.foxy.repos @@ -0,0 +1,9 @@ +repositories: + ros-controls/realtime_tools: + type: git + url: https://github.com/ros-controls/realtime_tools.git + version: foxy-devel + ros-controls/control_msgs: + type: git + url: https://github.com/ros-controls/control_msgs.git + version: foxy-devel diff --git a/ros2_control/ros2_control.repos b/ros2_control.galactic.repos similarity index 52% rename from ros2_control/ros2_control.repos rename to ros2_control.galactic.repos index 08f81b4e8b..afb1cbf640 100644 --- a/ros2_control/ros2_control.repos +++ b/ros2_control.galactic.repos @@ -1,12 +1,4 @@ repositories: - ros-controls/ros2_control: - type: git - url: https://github.com/ros-controls/ros2_control.git - version: master - ros-controls/ros2_controllers: - type: git - url: https://github.com/ros-controls/ros2_controllers.git - version: master ros-controls/realtime_tools: type: git url: https://github.com/ros-controls/realtime_tools.git diff --git a/ros2_control.rolling.repos b/ros2_control.rolling.repos new file mode 100644 index 0000000000..afb1cbf640 --- /dev/null +++ b/ros2_control.rolling.repos @@ -0,0 +1,9 @@ +repositories: + ros-controls/realtime_tools: + type: git + url: https://github.com/ros-controls/realtime_tools.git + version: foxy-devel + ros-controls/control_msgs: + type: git + url: https://github.com/ros-controls/control_msgs.git + version: galactic-devel