Skip to content

Commit

Permalink
Build changes updates 1.
Browse files Browse the repository at this point in the history
Signed-off-by: Govind Kamat <govkamat@amazon.com>
  • Loading branch information
gkamat committed Sep 8, 2024
1 parent 58dbf93 commit 57aa1de
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 22 deletions.
24 changes: 10 additions & 14 deletions .ci/build.sh
Original file line number Diff line number Diff line change
@@ -1,22 +1,20 @@
#!/usr/bin/env bash

pyenv_init() {
PATH=$HOME/.pyenv/shims:$PATH:$HOME/.pyenv/bin
}

function setup {
export THESPLOG_FILE="${THESPLOG_FILE:-${BENCHMARK_HOME}/.benchmark/logs/actor-system-internal.log}"
# this value is in bytes, the default is 50kB. We increase it to 200kiB.
export THESPLOG_FILE_MAXSIZE=${THESPLOG_FILE_MAXSIZE:-204800}
# adjust the default log level from WARNING
export THESPLOG_THRESHOLD="INFO"
export BENCHMARK_HOME=$GITHUB_WORKSPACE

export THESPLOG_FILE=$BENCHMARK_HOME/.benchmark/logs/actor-system-internal.log
export THESPLOG_FILE_MAXSIZE=204800 # default is 50 KiB
export THESPLOG_THRESHOLD=INFO # default log level is WARNING

pyenv_init
export TERM=dumb
export LC_ALL=en_US.UTF-8

# Init pyenv.
PATH=$HOME/.pyenv/shims:$PATH:$HOME/.pyenv/bin
}

function build {
function build_and_unit_test {
setup

set -e
Expand All @@ -25,11 +23,9 @@ function build {
make test
}

function build_it {
function run_it {
setup

export BENCHMARK_HOME="$GITHUB_WORKSPACE"

docker pull ubuntu/squid:latest

# make it38, it39, etc. so they run as concurrent GHA jobs
Expand Down
4 changes: 1 addition & 3 deletions .github/workflows/integ-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,4 @@ jobs:
- run: echo "JAVA17_HOME=$JAVA_HOME" >> $GITHUB_ENV

- name: Run the CI build script
run: bash .ci/build.sh build_it ${{ matrix.python-version }}
env:
BENCHMARK_HOME: env.GITHUB_WORKSPACE
run: bash .ci/build.sh run_it ${{ matrix.python-version }}
4 changes: 1 addition & 3 deletions .github/workflows/unit-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,4 @@ jobs:
run: git clone https://github.com/pyenv/pyenv.git ~/.pyenv

- name: Run the CI build script
run: bash .ci/build.sh build
env:
BENCHMARK_HOME: env.GITHUB_WORKSPACE
run: bash .ci/build.sh build_and_unit_test
8 changes: 6 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
# under the License.

SHELL = /bin/bash
PYTHON = python3
PIP = pip3
VERSIONS = $(shell jq -r '.python_versions | .[]' .ci/variables.json | sed '$$d')
VERSION38 = $(shell jq -r '.python_versions | .[]' .ci/variables.json | sed '$$d' | grep 3\.8)
Expand Down Expand Up @@ -43,14 +44,17 @@ check-java:
fi

install-deps: pyinst38
# @if test `uname` = Darwin -o `python3 --version | sed 's/.* 3.\([0-9]*\).*/3\1/'` -lt 38; then make pyinst38; fi
$(PIP) install --upgrade pip setuptools wheel

install-user: install-deps
PIP_ONLY_BINARY=h5py $(PIP) install -e .

install-devel: install-deps
PIP_ONLY_BINARY $(PIP) install -e .[develop]
PIP_ONLY_BINARY=h5py $(PIP) install -e .[develop]

build:
$(PIP) install --upgrade build
$(PYTHON) -m build

wheel:
$(PIP) install --upgrade pip setuptools wheel
Expand Down

0 comments on commit 57aa1de

Please sign in to comment.