openai/openai-python

Public

mirrored from https://github.com/openai/openai-pythonAvailable

CodeCommitsIssuesPull requestsActionsInsightsSecurity
a7ac118ffcfcb8c396dda9aae23d16cadd7bec2c

Branches

Tags

  • No tags available.
0Branches0Tags
Go to file
Add file
Code

Clone

HTTPS

Download ZIP

.github/workflows/detect-breaking-changes.yml

88lines · modecode

1name: CI
2on:
3 pull_request:
4 branches:
5 - main
6 - next
7
8jobs:
9 detect_breaking_changes:
10 runs-on: 'ubuntu-latest'
11 name: detect-breaking-changes
12 if: github.repository == 'openai/openai-python'
13 steps:
14 - name: Calculate fetch-depth
15 run: |
16 echo "FETCH_DEPTH=$(expr ${{ github.event.pull_request.commits }} + 1)" >> $GITHUB_ENV
17
18 - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6
19 with:
20 # Ensure we can check out the pull request base in the script below.
21 fetch-depth: ${{ env.FETCH_DEPTH }}
22
23 - name: Set up uv
24 uses: astral-sh/setup-uv@08807647e7069bb48b6ef5acd8ec9567f424441b # setup-uv v8.1.0; uv 0.11.8
25 with:
26 version: "0.11.8"
27 enable-cache: true
28
29 - name: Set up Python
30 run: uv python install
31
32 - name: Install dependencies
33 run: uv sync --locked --all-extras --group dev
34 - name: Detect removed symbols
35 run: uv run python scripts/detect-breaking-changes.py "${{ github.event.pull_request.base.sha }}"
36
37 - name: Detect breaking changes
38 run: |
39 test -f ./scripts/detect-breaking-changes || { echo "Missing scripts/detect-breaking-changes"; exit 1; }
40 ./scripts/detect-breaking-changes ${{ github.event.pull_request.base.sha }}
41
42 agents_sdk:
43 runs-on: 'ubuntu-latest'
44 name: Detect Agents SDK regressions
45 if: github.repository == 'openai/openai-python'
46 steps:
47 # Setup this sdk
48 - uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
49 with:
50 path: openai-python
51
52 - name: Set up uv
53 uses: astral-sh/setup-uv@08807647e7069bb48b6ef5acd8ec9567f424441b # setup-uv v8.1.0; uv 0.11.8
54 with:
55 version: "0.11.8"
56 enable-cache: true
57
58 - name: Set up Python
59 working-directory: openai-python
60 run: uv python install
61
62 - name: Install dependencies
63 working-directory: openai-python
64 run: uv sync --locked --all-extras --group dev
65
66 # Setup the agents lib
67 - uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
68 with:
69 repository: openai/openai-agents-python
70 path: openai-agents-python
71
72 - name: Setup uv
73 uses: astral-sh/setup-uv@08807647e7069bb48b6ef5acd8ec9567f424441b # setup-uv v8.1.0; uv 0.11.8
74 with:
75 enable-cache: true
76 version: "0.11.8"
77
78 - name: Link to local SDK
79 working-directory: openai-agents-python
80 run: uv add ../openai-python
81
82 - name: Install dependencies
83 working-directory: openai-agents-python
84 run: make sync
85
86 - name: Run integration type checks
87 working-directory: openai-agents-python
88 run: make mypy
89