-
Notifications
You must be signed in to change notification settings - Fork 20
52 lines (44 loc) · 1.36 KB
/
ci-build.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
name: CI
on:
# Trigger the workflow on push or pull request,
# but only for the main branch
push:
branches:
- main
pull_request:
branches:
- main
permissions:
contents: read # to fetch code
actions: write # to cancel previous workflows
concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.ref }}
cancel-in-progress: true
jobs:
build:
# ie. presubmit (py 3.11 on ubuntu-latest)
name: "presubmit (py ${{ matrix.docker-python-version }} on ubuntu-latest"
strategy:
matrix:
docker-python-version: ['3.11']
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.11'
- name: Init submodule
run: |
git submodule update --init --recursive
- name: Install dependencies
run: |
python -m pip install --upgrade pip setuptools
python -m pip install build wheel numpy twine auditwheel
- name: Run bazel test
run: |
cat tflite/python/metrics/metrics_nonportable_test.py
export DOCKER_PYTHON_VERSION="${{ matrix.docker-python-version }}"
export EXPERIMENTAL_TARGETS_ONLY="true"
echo "docker python version: ${DOCKER_PYTHON_VERSION}"
# ./ci/run_bazel_test_with_docker.sh