Skip to content

Commit 5716d39

Browse files
author
Benjamin Délèze
authored
Merge branch 'master' into sync-released-b4731d905
2 parents b4731d9 + faddc20 commit 5716d39

File tree

2,984 files changed

+12275
-21189
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

2,984 files changed

+12275
-21189
lines changed

.github/workflows/discord_updater.yml

Lines changed: 0 additions & 46 deletions
This file was deleted.

.github/workflows/test_suite_linux.yml

Lines changed: 15 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -68,18 +68,11 @@ jobs:
6868
export LIBGL_ALWAYS_SOFTWARE=true
6969
export ROS_DISTRO=${{ matrix.ROS_DISTRO }}
7070
xvfb-run --auto-servernum make distrib -j4
71-
- name: Prepare Webots Controller Deployment
72-
if: ${{ (github.event_name == 'schedule' || contains(github.event.pull_request.labels.*.name, 'deploy libcontroller')) && matrix.os == 'ubuntu-20.04' }}
73-
uses: webfactory/[email protected]
74-
with:
75-
ssh-private-key: ${{ secrets.WEBOTS_CONTROLLER_DEPLOY_KEY }}
76-
- name: Deploy Webots Controller
77-
if: ${{ (github.event_name == 'schedule' || contains(github.event.pull_request.labels.*.name, 'deploy libcontroller')) && matrix.os == 'ubuntu-20.04' }}
78-
run: scripts/packaging/sync_controller_lib.sh
7971
- name: Create/Update GitHub release
8072
if: ${{ matrix.os == 'ubuntu-20.04' && (github.event_name == 'push' || github.event_name == 'schedule') }}
8173
run: |
8274
sudo python -m pip install requests PyGithub
75+
pip install pyopenssl --upgrade
8376
scripts/packaging/publish_release.py --key=${{ secrets.GITHUB_TOKEN }} --repo=${{ github.repository }} --branch=${{ github.ref }} --commit=$(git log -1 --format='%H') --tag=${{ github.ref }}
8477
- uses: actions/upload-artifact@v2
8578
if: ${{ contains(github.event.pull_request.labels.*.name, 'test suite') || contains(github.event.pull_request.labels.*.name, 'test ros') || contains(github.event.pull_request.labels.*.name, 'test worlds') }}
@@ -128,6 +121,12 @@ jobs:
128121
export TESTS_HOME=$PWD # required by cache group in the test suite
129122
export BRANCH_HASH=$(git log -1 --format='%H')
130123
xvfb-run --auto-servernum python tests/test_suite.py
124+
- uses: actions/upload-artifact@v2
125+
if: failure()
126+
with:
127+
name: test-results-${{ matrix.os }}
128+
path: |
129+
tests/
131130
test-ros:
132131
needs: build
133132
if: ${{ contains(github.event.pull_request.labels.*.name, 'test ros') || github.event_name == 'schedule' }}
@@ -171,44 +170,33 @@ jobs:
171170
if: ${{ contains(github.event.pull_request.labels.*.name, 'test worlds') || github.event_name == 'schedule' }}
172171
runs-on: ubuntu-20.04
173172
steps:
174-
- uses: actions/checkout@v3
175173
- name: Download Artifacts
176174
uses: actions/download-artifact@v2
177175
with:
178176
name: build-ubuntu-20.04
179177
path: artifact
178+
- name: Get branch name
179+
id: branch-name
180+
uses: tj-actions/[email protected]
180181
- name: Extract Webots and Cache
181182
run: |
182183
tar xjf artifact/webots-*-x86-64*.tar.bz2 -C artifact
184+
cp -R artifact/ untouched-artifact/
183185
mkdir -p ~/.cache/Cyberbotics/Webots/
184186
unzip -q artifact/assets-*.zip -d ~/.cache/Cyberbotics/Webots/assets
185-
- name: Install Webots Dependencies
186-
run: sudo scripts/install/linux_runtime_dependencies.sh
187187
- name: Set up Python 3.9
188188
uses: actions/setup-python@v2
189189
with:
190190
python-version: 3.9
191191
- name: Update World, Check Warnings and Validate Cache
192192
run: |
193-
git config --global user.name ${GITHUB_ACTOR}
194-
git config --global user.email ${GITHUB_ACTOR}@github.com
193+
wget https://raw.githubusercontent.com/cyberbotics/webots/${{ steps.branch-name.outputs.current_branch }}/scripts/install/linux_runtime_dependencies.sh && sudo bash linux_runtime_dependencies.sh
195194
export LIBGL_ALWAYS_SOFTWARE=true
196195
export WEBOTS_DISABLE_SAVE_SCREEN_PERSPECTIVE_ON_CLOSE=true
197-
xvfb-run --auto-servernum python scripts/packaging/update_urls.py $(git log -1 --format='%H')
198-
echo "Updated urls with commit $(git log -1 --format='%H')"
199-
git add -u && git commit -m "Fake-commit the updated urls so that no diff exists prior to running the test"
200196
export WEBOTS_HOME=$PWD/artifact/webots
201-
if [[ -d ~/.cache/Cyberbotics/Webots/assets/ ]]; then cached_files_before=$(ls ~/.cache/Cyberbotics/Webots/assets/ | wc -l); else cached_files_before=0; fi
202-
xvfb-run --auto-servernum python tests/test_worlds.py
203-
if [[ "$(git diff --name-only *.wbt *.wbproj | wc -l)" -ne "0" ]]; then echo Some world and/or wbproj files are not up to date: "$(git diff *.wbt *.wbproj)"; exit -1; fi
204-
if [[ -d ~/.cache/Cyberbotics/Webots/assets/ ]]; then cached_files_after=$(ls ~/.cache/Cyberbotics/Webots/assets/ | wc -l); else cached_files_after=0; fi
205-
# Note: need an offset of 22 because world 'url.wbt' uses non-cached assets on purpose
206-
if [ "$cached_files_after" -ne "$((cached_files_before + 22))" ]; then
207-
echo "Some assets are not included in the cache (before $cached_files_before, after $cached_files_after)";
208-
echo "Asset log content is:"
209-
cat ~/.cache/Cyberbotics/Webots/assets/log.txt
210-
exit 1
211-
fi
197+
wget https://raw.githubusercontent.com/cyberbotics/webots/${{ steps.branch-name.outputs.current_branch }}/tests/test_worlds.py
198+
xvfb-run --auto-servernum python3 test_worlds.py
199+
if [[ "$(diff -qr artifact/ untouched-artifact/ | wc -l)" -ne "0" ]]; then echo Some world and/or wbproj files are not up to date: "$(diff -qr artifact/ untouched-artifact/)"; exit 1; fi
212200
delete-artifacts:
213201
needs: [build, test-suite, test-ros, test-worlds]
214202
if: ${{ always() && !contains(github.event.pull_request.labels.*.name, 'test distribution') && !contains(github.event.pull_request.labels.*.name, 'test webots build') }}

.github/workflows/test_suite_linux_develop.yml

Lines changed: 9 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -64,18 +64,11 @@ jobs:
6464
export LIBGL_ALWAYS_SOFTWARE=true
6565
export ROS_DISTRO=${{ matrix.ROS_DISTRO }}
6666
xvfb-run --auto-servernum make distrib -j4
67-
- name: Prepare Webots Controller Deployment
68-
if: ${{ (github.event_name == 'schedule' || contains(github.event.pull_request.labels.*.name, 'deploy libcontroller')) && matrix.os == 'ubuntu-20.04' }}
69-
uses: webfactory/[email protected]
70-
with:
71-
ssh-private-key: ${{ secrets.WEBOTS_CONTROLLER_DEPLOY_KEY }}
72-
- name: Deploy Webots Controller
73-
if: ${{ (github.event_name == 'schedule' || contains(github.event.pull_request.labels.*.name, 'deploy libcontroller')) && matrix.os == 'ubuntu-20.04' }}
74-
run: scripts/packaging/sync_controller_lib.sh
7567
- name: Create/Update GitHub release
7668
if: ${{ matrix.os == 'ubuntu-20.04' && (github.event_name == 'push' || github.event_name == 'schedule') }}
7769
run: |
7870
sudo python -m pip install requests PyGithub
71+
pip install pyopenssl --upgrade
7972
scripts/packaging/publish_release.py --key=${{ secrets.GITHUB_TOKEN }} --repo=${{ github.repository }} --branch=${{ github.ref }} --commit=$(git log -1 --format='%H') --tag=${{ github.ref }}
8073
- uses: actions/upload-artifact@v2
8174
if: ${{ contains(github.event.pull_request.labels.*.name, 'test suite') || contains(github.event.pull_request.labels.*.name, 'test ros') || contains(github.event.pull_request.labels.*.name, 'test worlds') }}
@@ -170,43 +163,33 @@ jobs:
170163
if: ${{ contains(github.event.pull_request.labels.*.name, 'test worlds') || github.event_name == 'schedule' }}
171164
runs-on: ubuntu-20.04
172165
steps:
173-
- uses: actions/checkout@v3
174-
with:
175-
ref: develop
176166
- name: Download Artifacts
177167
uses: actions/download-artifact@v2
178168
with:
179169
name: build-ubuntu-20.04
180170
path: artifact
171+
- name: Get branch name
172+
id: branch-name
173+
uses: tj-actions/[email protected]
181174
- name: Extract Webots and Cache
182175
run: |
183176
tar xjf artifact/webots-*-x86-64*.tar.bz2 -C artifact
177+
cp -R artifact/ untouched-artifact/
184178
mkdir -p ~/.cache/Cyberbotics/Webots/
185179
unzip -q artifact/assets-*.zip -d ~/.cache/Cyberbotics/Webots/assets
186-
- name: Install Webots Dependencies
187-
run: sudo scripts/install/linux_runtime_dependencies.sh
188180
- name: Set up Python 3.9
189181
uses: actions/setup-python@v2
190182
with:
191183
python-version: 3.9
192184
- name: Update World, Check Warnings and Validate Cache
193185
run: |
194-
git config --global user.name ${GITHUB_ACTOR}
195-
git config --global user.email ${GITHUB_ACTOR}@github.com
186+
wget https://raw.githubusercontent.com/cyberbotics/webots/${{ steps.branch-name.outputs.current_branch }}/scripts/install/linux_runtime_dependencies.sh && sudo bash linux_runtime_dependencies.sh
196187
export LIBGL_ALWAYS_SOFTWARE=true
197188
export WEBOTS_DISABLE_SAVE_SCREEN_PERSPECTIVE_ON_CLOSE=true
198-
xvfb-run --auto-servernum python scripts/packaging/update_urls.py $(git log -1 --format='%H')
199-
git add -u && git commit -m "Fake-commit the updated urls so that no diff exists prior to running the test"
200189
export WEBOTS_HOME=$PWD/artifact/webots
201-
if [[ -d ~/.cache/Cyberbotics/Webots/assets/ ]]; then cached_files_before=$(ls ~/.cache/Cyberbotics/Webots/assets/ | wc -l); else cached_files_before=0; fi
202-
xvfb-run --auto-servernum python tests/test_worlds.py
203-
if [[ "$(git diff --name-only *.wbt *.wbproj | wc -l)" -ne "0" ]]; then echo Some world and/or wbproj files are not up to date: "$(git diff *.wbt *.wbproj)"; exit -1; fi
204-
if [[ -d ~/.cache/Cyberbotics/Webots/assets/ ]]; then cached_files_after=$(ls ~/.cache/Cyberbotics/Webots/assets/ | wc -l); else cached_files_after=0; fi
205-
# Note: need an offset of 22 because world 'url.wbt' uses non-cached assets on purpose
206-
if [ "$cached_files_after" -ne "$((cached_files_before + 22))" ]; then
207-
echo "Some assets are not included in the cache (before $cached_files_before, after $cached_files_after)";
208-
exit 1
209-
fi
190+
sudo apt install -y wget && wget https://raw.githubusercontent.com/cyberbotics/webots/${{ steps.branch-name.outputs.current_branch }}/tests/test_worlds.py
191+
xvfb-run --auto-servernum python3 test_worlds.py
192+
if [[ "$(diff -qr artifact/ untouched-artifact/ | wc -l)" -ne "0" ]]; then echo Some world and/or wbproj files are not up to date: "$(diff -qr artifact/ untouched-artifact/)"; exit 1; fi
210193
delete-artifacts:
211194
needs: [build, test-suite, test-ros, test-worlds]
212195
if: ${{ always() && !contains(github.event.pull_request.labels.*.name, 'test distribution') && !contains(github.event.pull_request.labels.*.name, 'test webots build') }}

.github/workflows/test_suite_mac.yml

Lines changed: 4 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -42,41 +42,16 @@ jobs:
4242
fetch-depth: 15
4343
- name: Install Webots Compilation Dependencies
4444
run: |
45-
# swig wget cmake [email protected] [email protected] and [email protected] are already installed
46-
if HOMEBREW_NO_INSTALL_CLEANUP=1 brew install [email protected]; then
47-
echo "Installation of Python3.7 successful"
48-
else
49-
echo "Installation of Python3.7 failed"
50-
fi
45+
# swig wget and cmake are already installed
5146
npm install -g appdmg
52-
# install regular Python 3.7
53-
wget -qq https://www.python.org/ftp/python/3.7.9/python-3.7.9-macosx10.9.pkg
54-
sudo installer -pkg python-3.7.9-macosx10.9.pkg -target /
55-
# install regular Python 3.8
56-
wget -qq https://www.python.org/ftp/python/3.8.10/python-3.8.10-macos11.pkg
57-
sudo installer -pkg python-3.8.10-macos11.pkg -target /
58-
# install regular Python 3.9
59-
wget -qq https://www.python.org/ftp/python/3.9.13/python-3.9.13-macos11.pkg
60-
sudo installer -pkg python-3.9.13-macos11.pkg -target /
61-
# install regular Python 3.10
62-
wget -qq https://www.python.org/ftp/python/3.10.5/python-3.10.5-macos11.pkg
63-
sudo installer -pkg python-3.10.5-macos11.pkg -target /
6447
- name: Set Commit SHA in Version
6548
if: ${{ github.event_name == 'schedule' }}
6649
run: python scripts/packaging/set_commit_and_date_in_version.py $(git log -1 --format='%H')
6750
- name: Webots Package Creation
6851
run: |
6952
export JAVA_HOME="$(/usr/libexec/java_home -v 16)"
70-
export PATH=/Library/Frameworks/Python.framework/Versions/3.10/bin:/Library/Frameworks/Python.framework/Versions/3.9/bin:/Library/Frameworks/Python.framework/Versions/3.8/bin:/Library/Frameworks/Python.framework/Versions/3.7/bin:/usr/local/bin/:$PATH
53+
export PATH=/Library/Frameworks/Python.framework/Versions/3.11/bin:/usr/local/bin/:$PATH
7154
make distrib -j4
72-
- name: Prepare Webots Controller Deployment
73-
if: ${{ github.event_name == 'schedule' || contains(github.event.pull_request.labels.*.name, 'deploy libcontroller') }}
74-
uses: webfactory/[email protected]
75-
with:
76-
ssh-private-key: ${{ secrets.WEBOTS_CONTROLLER_DEPLOY_KEY }}
77-
- name: Deploy Webots Controller
78-
if: ${{ github.event_name == 'schedule' || contains(github.event.pull_request.labels.*.name, 'deploy libcontroller') }}
79-
run: scripts/packaging/sync_controller_lib.sh
8055
- name: Create/Update GitHub release
8156
if: ${{ (github.event_name == 'push' || github.event_name == 'schedule') }}
8257
run: |
@@ -107,10 +82,10 @@ jobs:
10782
hdiutil mount artifact/webots-*.dmg
10883
sudo cp -R /Volumes/Webots/Webots.app /Applications
10984
hdiutil unmount /Volumes/Webots
110-
- name: Set up Python 3.9
85+
- name: Set up Python 3.11
11186
uses: actions/setup-python@v2
11287
with:
113-
python-version: 3.9
88+
python-version: 3.11
11489
- name: Test
11590
run:
11691
export WEBOTS_DISABLE_SAVE_SCREEN_PERSPECTIVE_ON_CLOSE=true

.github/workflows/test_suite_mac_develop.yml

Lines changed: 4 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -38,41 +38,16 @@ jobs:
3838
ref: develop
3939
- name: Install Webots Compilation Dependencies
4040
run: |
41-
# swig wget cmake [email protected] [email protected] and [email protected] are already installed
42-
if HOMEBREW_NO_INSTALL_CLEANUP=1 brew install [email protected]; then
43-
echo "Installation of Python3.7 successful"
44-
else
45-
echo "Installation of Python3.7 failed"
46-
fi
41+
# swig wget and cmake are already installed
4742
npm install -g appdmg
48-
# install regular Python 3.7
49-
wget -qq https://www.python.org/ftp/python/3.7.9/python-3.7.9-macosx10.9.pkg
50-
sudo installer -pkg python-3.7.9-macosx10.9.pkg -target /
51-
# install regular Python 3.8
52-
wget -qq https://www.python.org/ftp/python/3.8.10/python-3.8.10-macos11.pkg
53-
sudo installer -pkg python-3.8.10-macos11.pkg -target /
54-
# install regular Python 3.9
55-
wget -qq https://www.python.org/ftp/python/3.9.13/python-3.9.13-macos11.pkg
56-
sudo installer -pkg python-3.9.13-macos11.pkg -target /
57-
# install regular Python 3.10
58-
wget -qq https://www.python.org/ftp/python/3.10.5/python-3.10.5-macos11.pkg
59-
sudo installer -pkg python-3.10.5-macos11.pkg -target /
6043
- name: Set Commit SHA in Version
6144
if: ${{ github.event_name == 'schedule' }}
6245
run: python scripts/packaging/set_commit_and_date_in_version.py $(git log -1 --format='%H')
6346
- name: Webots Package Creation
6447
run: |
6548
export JAVA_HOME="$(/usr/libexec/java_home -v 16)"
66-
export PATH=/Library/Frameworks/Python.framework/Versions/3.10/bin:/Library/Frameworks/Python.framework/Versions/3.9/bin:/Library/Frameworks/Python.framework/Versions/3.8/bin:/Library/Frameworks/Python.framework/Versions/3.7/bin:/usr/local/bin/:$PATH
49+
export PATH=/Library/Frameworks/Python.framework/Versions/3.11/bin:/usr/local/bin/:$PATH
6750
make distrib -j4
68-
- name: Prepare Webots Controller Deployment
69-
if: ${{ github.event_name == 'schedule' || contains(github.event.pull_request.labels.*.name, 'deploy libcontroller') }}
70-
uses: webfactory/[email protected]
71-
with:
72-
ssh-private-key: ${{ secrets.WEBOTS_CONTROLLER_DEPLOY_KEY }}
73-
- name: Deploy Webots Controller
74-
if: ${{ github.event_name == 'schedule' || contains(github.event.pull_request.labels.*.name, 'deploy libcontroller') }}
75-
run: scripts/packaging/sync_controller_lib.sh
7651
- name: Create/Update GitHub release
7752
if: ${{ (github.event_name == 'push' || github.event_name == 'schedule') }}
7853
run: |
@@ -105,10 +80,10 @@ jobs:
10580
hdiutil mount artifact/webots-*.dmg
10681
sudo cp -R /Volumes/Webots/Webots.app /Applications
10782
hdiutil unmount /Volumes/Webots
108-
- name: Set up Python 3.9
83+
- name: Set up Python 3.11
10984
uses: actions/setup-python@v2
11085
with:
111-
python-version: 3.9
86+
python-version: 3.11
11287
- name: Test
11388
run:
11489
export WEBOTS_DISABLE_SAVE_SCREEN_PERSPECTIVE_ON_CLOSE=true

.github/workflows/test_suite_windows.yml

Lines changed: 2 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,6 @@ jobs:
2929
- uses: msys2/setup-msys2@v2
3030
with:
3131
update: false
32-
install: >-
33-
git
3432
- uses: actions/checkout@v3
3533
with:
3634
submodules: true
@@ -54,9 +52,6 @@ jobs:
5452
- uses: msys2/setup-msys2@v2
5553
with:
5654
update: false
57-
install: >-
58-
git
59-
openssh
6055
- uses: actions/checkout@v3
6156
with:
6257
submodules: true
@@ -71,7 +66,8 @@ jobs:
7166
choco install -y visualcpp-build-tools
7267
- name: Install Webots Compilation Dependencies
7368
run: |
74-
export PYTHON_HOME=/C/hostedtoolcache/windows/Python/3.11.`ls $PYTHON_INSTALLATION_FOLDER | grep '^3\.11\.[0-9]\+$' | cut -c6- | sort -n | tail -n1`/x64
69+
export PYTHON_INSTALLATION_FOLDER=/C/hostedtoolcache/windows/Python
70+
export PYTHON_HOME=$PYTHON_INSTALLATION_FOLDER/3.11.`ls $PYTHON_INSTALLATION_FOLDER | grep '^3\.11\.[0-9]\+$' | cut -c6- | sort -n | tail -n1`/x64
7571
echo 'export JAVA_HOME=/C/Program\ Files/OpenJDK/`ls /C/Program\ Files/OpenJDK`' >> ~/.bash_profile
7672
echo 'export PYTHON_HOME='$PYTHON_HOME >> ~/.bash_profile
7773
echo 'export VISUAL_STUDIO_PATH="/C/Program Files (x86)/Microsoft Visual Studio/2017"' >> ~/.bash_profile
@@ -86,19 +82,9 @@ jobs:
8682
run: |
8783
export WEBOTS_HOME=$GITHUB_WORKSPACE
8884
make distrib -j4
89-
- name: Deploy Webots Controller
90-
if: ${{ github.event_name == 'schedule' || contains(github.event.pull_request.labels.*.name, 'deploy libcontroller') }}
91-
run: |
92-
export SSH_AUTH_SOCK=/tmp/ssh_agent.sock
93-
mkdir ~/.ssh
94-
ssh-keyscan -H github.com > ~/.ssh/known_hosts
95-
ssh-agent -a $SSH_AUTH_SOCK > /dev/null
96-
ssh-add - <<< "${{ secrets.WEBOTS_CONTROLLER_DEPLOY_KEY }}"
97-
scripts/packaging/sync_controller_lib.sh
9885
- name: Create/Update GitHub release
9986
if: ${{ (github.event_name == 'push' || github.event_name == 'schedule') }}
10087
run: |
101-
export PATH=/c/hostedtoolcache/windows/Python/3.11.0/x64:$PATH
10288
python -m pip install requests PyGithub
10389
scripts/packaging/publish_release.py --key=${{ secrets.GITHUB_TOKEN }} --repo=${{ github.repository }} --branch=${{ github.ref }} --commit=$(git log -1 --format='%H') --tag=${{ github.ref }}
10490
- uses: actions/upload-artifact@v2

0 commit comments

Comments
 (0)