openai: update CHANGELOG and bump version to 1.1.1 (#84) #1
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: ci | |
on: | |
pull_request: | |
push: | |
branches: | |
- main | |
permissions: | |
contents: read | |
jobs: | |
pre-commit: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: ./.github/actions/env-install | |
- uses: pre-commit/[email protected] | |
license-header-check: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- run: ./scripts/license_headers_check.sh | |
pip-installable: | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
working-dir: ['instrumentation/elastic-opentelemetry-instrumentation-openai'] | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: ./.github/actions/env-install | |
- run: pip install . | |
working-directory: ${{ matrix.working-dir }} | |
test: | |
runs-on: ubuntu-latest | |
env: | |
py38: "3.8" | |
py39: "3.9" | |
py310: "3.10" | |
py311: "3.11" | |
py312: "3.12" | |
py313: "3.13" | |
# Baseline version of openai client we support | |
baseline: "1.2.0" | |
latest: "" | |
working_dir: "instrumentation/elastic-opentelemetry-instrumentation-openai" | |
strategy: | |
fail-fast: false | |
matrix: | |
python-version: [py38, py39, py310, py311, py312, py313] | |
openai-version: [baseline, latest] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Python ${{ env[matrix.python-version] }} | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ env[matrix.python-version] }} | |
architecture: "x64" | |
- if: ${{ env[matrix.python-version] == '3.8' || env[matrix.python-version] == '3.9' }} | |
run: pip install -r dev-requirements-3.9.txt | |
working-directory: ${{ env.working_dir }} | |
- if: ${{ env[matrix.python-version] != '3.8' && env[matrix.python-version] != '3.9' }} | |
run: pip install -r dev-requirements.txt | |
working-directory: ${{ env.working_dir }} | |
- if: ${{ env[matrix.openai-version] }} | |
name: update openai to required version if not latest | |
run: | |
pip install openai==${{ env[matrix.openai-version] }} | |
working-directory: ${{ env.working_dir }} | |
- run: pytest | |
working-directory: ${{ env.working_dir }} | |
- if: ${{ env[matrix.python-version] == '3.13' && !env[matrix.openai-version] && env.OPENAI_API_KEY != '' }} | |
# Only run on latest python and openai client version because we are calling openai | |
run: pytest --integration-tests | |
working-directory: ${{ env.working_dir }} | |
env: | |
OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }} |