GraphScope Nightly Build CI #1058
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
name: GraphScope Nightly Build CI | |
# on: [push, pull_request] | |
on: | |
workflow_dispatch: | |
schedule: | |
# The notifications for scheduled workflows are sent to the user who | |
# last modified the cron syntax in the workflow file. | |
# Trigger the workflow at 03:00(CST) every day. | |
- cron: '00 19 * * *' | |
jobs: | |
nightly-test: | |
if: ${{ github.ref == 'refs/heads/main' && github.repository == 'alibaba/GraphScope' }} | |
runs-on: ${{ matrix.os }} | |
defaults: | |
run: | |
shell: bash --noprofile --norc -eo pipefail {0} | |
strategy: | |
matrix: | |
os: [ubuntu-22.04, macos-latest] | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
submodules: true | |
- name: Install Dependencies of GraphScope | |
run: | | |
# Due to an observation of changing hostname in github runners, | |
# append 127.0.0.1 to etc/hosts to avoid DNS lookup. | |
r=`cat /etc/hosts | grep $(hostname) || true` | |
if [ -z "${r}" ];then export hn=$(hostname); sudo -E bash -c 'echo "127.0.0.1 ${hn}" >> /etc/hosts'; fi | |
cat /etc/hosts | |
if [ "$RUNNER_OS" == "macOS" ]; then | |
brew update | |
# pushd $(brew --repo homebrew/core) | |
# # fixed openmpi version 4.1.4 | |
# git checkout d2d8d2251eb3ce044993a79e5ad816ed3356bc36 | |
# popd | |
brew install bash | |
alias bash=$(brew --prefix)/bin/bash | |
fi | |
sudo mkdir /opt/graphscope | |
sudo chown -R $(id -u):$(id -g) /opt/graphscope | |
python3 -m pip install click | |
python3 gsctl.py install-deps dev --v6d-version v0.23.0 | |
- name: Setup tmate session | |
if: false | |
uses: mxschmitt/action-tmate@v3 | |
- name: Build GraphScope | |
run: | | |
. ${HOME}/.graphscope_env | |
# fixes nightly CI | |
export PATH=/Users/runner/Library/Python/3.11/bin:$PATH | |
make install INSTALL_PREFIX=/opt/graphscope | |
- name: Run Python Test | |
if: matrix.os == 'ubuntu-20.04' | |
env: | |
FULL_TEST_SUITE: ON | |
GS_TEST_DIR: ${{ github.workspace }}/gstest | |
run: | | |
# download dataset | |
git clone -b master --single-branch --depth=1 https://github.com/7br/gstest.git ${GS_TEST_DIR} | |
# run test | |
. ${HOME}/.graphscope_env | |
make unittest | |
- name: Upload Coverage | |
uses: codecov/codecov-action@v3 | |
if: matrix.os == 'ubuntu-20.04' | |
continue-on-error: true | |
with: | |
file: ./python/coverage.xml | |
fail_ci_if_error: false |