openai/openai-python

Public

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

CodeCommitsIssuesPull requestsActionsInsightsSecurity
2b4bc759b49504580cabc5e90b9cd79be4267207

Branches

Tags

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

Clone

HTTPS

Download ZIP

.github/workflows/ci.yml

78lines · modecode

1name: CI
2on:
3 push:
4 branches:
5 - main
6 pull_request:
7 branches:
8 - main
9
10jobs:
11 lint:
12 name: lint
13 runs-on: ubuntu-latest
14
15 steps:
16 - uses: actions/checkout@v4
17
18 - name: Install Rye
19 run: |
20 curl -sSf https://rye.astral.sh/get | bash
21 echo "$HOME/.rye/shims" >> $GITHUB_PATH
22 env:
23 RYE_VERSION: '0.44.0'
24 RYE_INSTALL_OPTION: '--yes'
25
26 - name: Install dependencies
27 run: rye sync --all-features
28
29 - name: Run lints
30 run: ./scripts/lint
31
32 test:
33 name: test
34 runs-on: ubuntu-latest
35
36 steps:
37 - uses: actions/checkout@v4
38
39 - name: Install Rye
40 run: |
41 curl -sSf https://rye.astral.sh/get | bash
42 echo "$HOME/.rye/shims" >> $GITHUB_PATH
43 env:
44 RYE_VERSION: '0.44.0'
45 RYE_INSTALL_OPTION: '--yes'
46
47 - name: Bootstrap
48 run: ./scripts/bootstrap
49
50 - name: Run tests
51 run: ./scripts/test
52
53 examples:
54 name: examples
55 runs-on: ubuntu-latest
56
57 steps:
58 - uses: actions/checkout@v4
59
60 - name: Install Rye
61 run: |
62 curl -sSf https://rye.astral.sh/get | bash
63 echo "$HOME/.rye/shims" >> $GITHUB_PATH
64 env:
65 RYE_VERSION: '0.44.0'
66 RYE_INSTALL_OPTION: '--yes'
67 - name: Install dependencies
68 run: |
69 rye sync --all-features
70
71 - env:
72 OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
73 run: |
74 rye run python examples/demo.py
75 - env:
76 OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
77 run: |
78 rye run python examples/async_demo.py
79