-
Notifications
You must be signed in to change notification settings - Fork 29
48 lines (45 loc) · 1.44 KB
/
python-install-and-use-e2e.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
name: Python package install and use E2E
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
jobs:
build:
name: Python ${{ matrix.python-version.version }} SDK E2E Test
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
python-version: [
{version: "3.8", versionName: "py38"},
{version: "3.9", versionName: "py39"},
{version: "3.10", versionName: "py310"},
{version: "3.11", versionName: "py311"},
{version: "3.12", versionName: "py312"}
]
steps:
- uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version.version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version.version }}
- name: Install Dependencies via Poetry
run: |
python -m pip install --upgrade pip
python -m pip install poetry
poetry install --with dev
shell: bash
- name: Lint with Ruff
run: |
pip install ruff
ruff check . --target-version=${{ matrix.python-version.versionName }}
continue-on-error: true
- name: Run simple evaluation E2E
env:
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
TONIC_TEXTUAL_API_KEY: ${{ secrets.TONIC_TEXTUAL_API_KEY }}
TONIC_VALIDATE_DO_NOT_TRACK: 'true'
run: |
poetry run pytest
shell: bash