openai/openai-python

Public

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

CodeCommitsIssuesPull requestsActionsInsightsSecurity
fb69e674f3caaf451ad55ad92d430d0a50e7c0a4

Branches

Tags

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

Clone

HTTPS

Download ZIP

.github/workflows/ci.yml

79lines · modecode

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