Skip to content

Bump golang.org/x/net #19

Bump golang.org/x/net

Bump golang.org/x/net #19

Workflow file for this run

name: build
on:
push:
paths:
- "*.py"
- "**/*.py"
- .github/workflows/build.yaml
- "**/*.go"
env:
PYTHON_VERSION: "3.11"
POETRY_VERSION: "1.4.2"
jobs:
build-go:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up Go
uses: actions/setup-go@v3
with:
go-version: 1.19
- name: Build everything
run: cd go/src/github.com/broadinstitute/kubequeconsume && go build -v ./...
- name: build executable
run: bash scripts/build-static-exe.sh
- name: print md5sum
run: md5sum cli/sparklespray/bin/kubequeconsume && ls -s cli/sparklespray/bin/kubequeconsume
- name: Upload executable
uses: actions/upload-artifact@v3
with:
name: kubequeconsume-exe-${{ github.run_number }}
path: cli/sparklespray/bin/kubequeconsume
retention-days: 5
# - name: Test
# run: cd go/src/github.com/broadinstitute/kubequeconsume && go test -v ./...
test-python:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ env.PYTHON_VERSION }}
uses: actions/setup-python@v4
with:
python-version: ${{ env.PYTHON_VERSION }}
# the following logic for caching taken from https://gist.github.com/gh640/233a6daf68e9e937115371c0ecd39c61
# Poetry cache depends on OS, Python version and Poetry version.
- name: Cache Poetry cache
uses: actions/cache@v3
with:
path: ~/.cache/pypoetry
key: poetry-cache-${{ runner.os }}-${{ steps.setup_python.outputs.python-version }}-${{ env.POETRY_VERSION }}
# virtualenv cache should depends on OS, Python version and `poetry.lock` (and optionally workflow files).
- name: Cache Packages
uses: actions/cache@v3
with:
path: ~/.local
key: poetry-local-${{ runner.os }}-${{ steps.setup_python.outputs.python-version }}-${{ hashFiles('**/poetry.lock') }}-${{ hashFiles('.github/workflows/*.yml') }}
- name: Set up poetry
uses: abatilo/actions-poetry@v2
with:
poetry-version: ${{ env.POETRY_VERSION }}
- name: Install dependencies
run: poetry install
working-directory: cli
- name: Run pyratchet
working-directory: cli
run: poetry run pyright-ratchet run pyright
- name: Run tests
run: poetry run pytest
working-directory: cli
build-package:
needs: [test-python, build-go]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ env.PYTHON_VERSION }}
uses: actions/setup-python@v4
with:
python-version: ${{ env.PYTHON_VERSION }}
# the following logic for caching taken from https://gist.github.com/gh640/233a6daf68e9e937115371c0ecd39c61
# Poetry cache depends on OS, Python version and Poetry version.
- name: Cache Poetry cache
uses: actions/cache@v3
with:
path: ~/.cache/pypoetry
key: poetry-cache-${{ runner.os }}-${{ steps.setup_python.outputs.python-version }}-${{ env.POETRY_VERSION }}
# virtualenv cache should depends on OS, Python version and `poetry.lock` (and optionally workflow files).
- name: Cache Packages
uses: actions/cache@v3
with:
path: ~/.local
key: poetry-local-${{ runner.os }}-${{ steps.setup_python.outputs.python-version }}-${{ hashFiles('**/poetry.lock') }}-${{ hashFiles('.github/workflows/*.yml') }}
- name: Set up poetry
uses: abatilo/actions-poetry@v2
with:
poetry-version: ${{ env.POETRY_VERSION }}
- name: Download executable
uses: actions/download-artifact@v3
with:
name: kubequeconsume-exe-${{ github.run_number }}
path: cli/sparklespray/bin
- name: print md5sum
run: md5sum cli/sparklespray/bin/kubequeconsume && ls -s cli/sparklespray/bin/kubequeconsume
- name: get package version
run: (echo -n 'package_version=' && poetry version -s) >> "$GITHUB_ENV"
working-directory: cli
- name: Build package
run: poetry build
working-directory: cli
# - name: debug info
# run: find . -print && ls -l dist && ls -l sparkles/bin
# working-directory: cli
- name: Upload sparklespray-${{ env.package_version }}.tar.gz package
uses: actions/upload-artifact@v3
with:
name: sparklespray-${{ env.package_version }}
path: cli/dist/sparklespray-*.tar.gz
retention-days: 5