Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Checkout action #2021

Closed
wants to merge 37 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions .github/workflows/analysis_workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,15 @@ jobs:
ARCTIC_CMAKE_PRESET: linux-debug
ACTIONS_ALLOW_USE_UNSECURE_NODE_VERSION: true
steps:
- name: Setup Node 16
run: |
apt update && apt -y install wget
touch "$HOME/.bashrc"
wget -qO- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.1/install.sh | bash
export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && . "$NVM_DIR/nvm.sh"
nvm install 16

- uses: actions/[email protected]
with:
submodules: recursive
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ jobs:
mongodb:
image: "mongo:4.4"
container:
image: ${{needs.cibw_docker_image.outputs.tag}}
image: quay.io/pypa/manylinux_2_28_x86_64
volumes:
- /:/mnt
windows_matrix:
Expand Down
27 changes: 21 additions & 6 deletions .github/workflows/build_steps.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ jobs:
python_impl_name: ${{inputs.python3 > 0 && format('cp3{0}', inputs.python3) || 'default'}}
CIBW_BUILD: ${{format('cp3{0}-{1}', inputs.python3, matrix.cibw_build_suffix)}}
ACTIONS_ALLOW_USE_UNSECURE_NODE_VERSION: true
USE_UNSHALLOW: ${{(matrix.os == 'linux' && inputs.job_type != 'build-python-wheels') && '0' || '1'}}
defaults:
run: {shell: bash}
steps:
Expand Down Expand Up @@ -118,12 +119,22 @@ jobs:
if: matrix.os == 'windows'
run: rm $(which ccache) || true

- name: Install deps
if: matrix.os == 'linux' && inputs.job_type != 'build-python-wheels'
run: |
yum update -y
yum install -y zip flex bison krb5-devel cyrus-sasl-devel openssl-devel \
unzip tar epel-release jq wget libcurl-devel python3 \
python3-devel python3-pip perl-IPC-Cmd

yum install -y mono-complete

- name: Prepare C++ compilation env
if: inputs.job_type != 'build-python-wheels'
run: . build_tooling/prep_cpp_build.sh # Also applies to Windows

- name: CMake compile
if: inputs.job_type != 'build-python-wheels'
if: matrix.os == 'windows' && inputs.job_type != 'build-python-wheels'
# We are pinning the version to 10.6 because >= 10.7, use node20 which is not supported in the container
uses: lukka/[email protected]
with:
Expand All @@ -132,6 +143,10 @@ jobs:
configurePresetAdditionalArgs: "['-DVCPKG_INSTALL_OPTIONS=--clean-after-build']"
buildPreset: ${{env.ARCTIC_CMAKE_PRESET}}

- name: CMake compile without Node
if: matrix.os == 'linux' && inputs.job_type != 'build-python-wheels'
run: cmake -DTEST=ON --preset $ARCTIC_CMAKE_PRESET cpp

- name: Compile C++ tests
if: inputs.job_type == 'cpp-tests'
run: cd cpp; cmake --build --preset $ARCTIC_CMAKE_PRESET --target install
Expand Down Expand Up @@ -255,7 +270,7 @@ jobs:
${{fromJSON(inputs.matrix)}}
name: ${{matrix.type}}${{matrix.python_deps_id}}
runs-on: ${{matrix.distro}}
container: ${{matrix.os == 'linux' && needs.compile.outputs.manylinux_image || null}}
# container: ${{matrix.os == 'linux' && needs.compile.outputs.manylinux_image || null}}
defaults:
run: {shell: bash}
services: ${{matrix.test_services}}
Expand All @@ -273,12 +288,12 @@ jobs:
name: wheel-${{needs.compile.outputs.cibw_build}}
path: ${{runner.temp}}

- name: Select Python (Linux)
if: matrix.os == 'linux'
run: echo /opt/python/${{env.python_impl_name}}*/bin >> $GITHUB_PATH
# - name: Select Python (Linux)
# if: matrix.os == 'linux'
# run: echo /opt/python/${{env.python_impl_name}}*/bin >> $GITHUB_PATH

- name: Select Python (Windows)
if: matrix.os == 'windows'
# if: matrix.os == 'windows'
uses: actions/[email protected]
with:
python-version: "3.${{inputs.python3}}"
Expand Down
8 changes: 8 additions & 0 deletions .github/workflows/build_with_conda.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,14 @@ jobs:
mongodb:
image: mongo:4.4
steps:
- name: Setup Node 16
run: |
apt update && apt -y install wget
touch "$HOME/.bashrc"
wget -qO- https://raw.githubusercontent.com/nvm-sh/nvm/v0.40.1/install.sh | bash
export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && . "$NVM_DIR/nvm.sh"
nvm install 16
- uses: actions/[email protected]
# DONT use recursive submodules checkout to simulate conda feedstock build
# with:
Expand Down
12 changes: 9 additions & 3 deletions build_tooling/prep_cpp_build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,18 @@

pushd $(realpath $(dirname $BASH_SOURCE))/../cpp/vcpkg

if [[ "$USE_UNSHALLOW" == "1" ]]; then
UNSHALLOW_OPTION="--unshallow"
else
UNSHALLOW_OPTION=""
fi

if [[ -e "$VCPKG_INSTALLATION_ROOT" ]] ; then
git fetch --unshallow file://$VCPKG_INSTALLATION_ROOT
git fetch $UNSHALLOW_OPTION file://$VCPKG_INSTALLATION_ROOT
elif [[ -n "$VCPKG_INSTALLATION_ROOT" && -e "/host$VCPKG_INSTALLATION_ROOT" ]] ; then
git fetch --unshallow file:///host$VCPKG_INSTALLATION_ROOT
git fetch $UNSHALLOW_OPTION file:///host$VCPKG_INSTALLATION_ROOT
else
git fetch --unshallow origin master
git fetch $UNSHALLOW_OPTION origin master
fi

cd ..
Expand Down
1 change: 1 addition & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ test-extras = "Testing"
before-all = """
[[ -e /etc/arcticdb_deps_installed ]] || { yum update -y && yum install -y zip \
openssl-devel cyrus-sasl-devel devtoolset-10-libatomic-devel libcurl-devel ; }
export USE_UNSHALLOW=1
{project}/build_tooling/prep_cpp_build.sh
{project}/build_tooling/vcpkg_caching.sh
"""
Expand Down
Loading