feat(arcor2_ur): trajectory speed, payload mass #81
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# cache from master branch can be shared with PR workflows | |
# see https://stackoverflow.com/a/71061281/3142796 and https://stackoverflow.com/a/66632107/3142796 | |
name: Pants-update-cache | |
on: | |
push: | |
branches: | |
- master | |
jobs: | |
build: | |
env: | |
PANTS_CONFIG_FILES: pants.ci.toml | |
runs-on: ubuntu-22.04 | |
strategy: | |
matrix: | |
python-version: ['3.11'] | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
lfs: true | |
- name: Get Pants version | |
id: pants_version | |
run: | | |
# Capture the "pants_version = " line from config. | |
PANTS_VERSION=$(grep -E '^pants_version\s*=' pants.toml) | |
echo "::set-output name=pants_version::$PANTS_VERSION" | |
- name: Checkout LFS objects | |
run: git lfs checkout | |
- uses: pat-s/always-upload-cache@v3 # default actions/cache is not saving cache on failure (e.g. when ./pants lint :: fails) | |
id: cache_pants_setup | |
with: | |
path: | | |
~/.cache/pants/setup | |
key: pants-setup-${{ steps.pants_version.outputs.pants_version }} | |
- uses: pat-s/always-upload-cache@v3 | |
id: cached_named_caches | |
with: | |
path: | | |
~/.cache/pants/named_caches | |
# The Python backend uses named_caches for Pip/PEX state, | |
# so it is appropriate to invalidate on requirements.txt changes. | |
key: pants-named-caches-${{ runner.os }}-${{ hashFiles('pants.toml') }}-${{ hashFiles('requirements.txt') }} | |
# Note that falling back to a restore key may give a useful partial result that will save time | |
# over completely clean state, but will cause the cache entry to grow without bound over time. | |
# See https://pants.readme.io/docs/using-pants-in-ci for tips on how to periodically clean it up. | |
# Alternatively you may want to avoid using restore keys. | |
restore-keys: | | |
pants-named-caches-${{ runner.os }}-${{ hashFiles('pants.toml') }}-${{ hashFiles('requirements.txt') }} | |
pants-named-caches-${{ runner.os }}-${{ hashFiles('pants.toml') }}- | |
pants-named-caches-${{ runner.os }}- | |
# If you're not using a fine-grained remote caching service (see https://www.pantsbuild.org/docs/remote-caching), | |
# then you may also want to preserve the local Pants cache (lmdb_store). However this must invalidate for | |
# changes to any file that can affect the build, so may not be practical in larger repos. | |
# A remote cache service integrates with Pants's fine-grained invalidation and avoids these problems. | |
- uses: pat-s/always-upload-cache@v3 | |
id: cache_lmdb_store | |
with: | |
path: | | |
~/.cache/pants/lmdb_store | |
key: pants-lmdb-store-${{ runner.os }}-${{ hashFiles('**/*') }} | |
# Same caveat as above regarding the issues with restore keys. | |
restore-keys: pants-lmdb-store-${{ runner.os }}- | |
- name: Prune pants cache | |
run: | | |
./build-support/nuke-cache.sh | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: bootstrap | |
run: | | |
pants --version | |
- name: install system dependencies | |
run: | | |
sudo ./build-support/install_kinect_prerequisites.sh | |
sudo apt install jq cargo | |
- name: Get dependencies | |
run: | | |
pants export | |
- name: Upload pants log | |
uses: actions/upload-artifact@v4 | |
with: | |
name: pants-log | |
path: .pants.d/pants.log | |
if: always() # We want the log even on failures. |