|
9 | 9 | CORE_REPO_SHA: 84c0e4f38d4fcdb8c13fd3988469fbb8cda28150
|
10 | 10 |
|
11 | 11 | jobs:
|
12 |
| - build: |
13 |
| - env: |
14 |
| - # We use these variables to convert between tox and GHA version literals |
15 |
| - py37: 3.7 |
16 |
| - py38: 3.8 |
17 |
| - py39: 3.9 |
18 |
| - py310: "3.10" |
19 |
| - py311: "3.11" |
20 |
| - pypy3: pypy-3.7 |
21 |
| - RUN_MATRIX_COMBINATION: ${{ matrix.python-version }}-${{ matrix.package }}-${{ matrix.os }} |
22 |
| - runs-on: ${{ matrix.os }} |
23 |
| - strategy: |
24 |
| - fail-fast: false # ensures the entire test matrix is run, even if one permutation fails |
25 |
| - matrix: |
26 |
| - python-version: [py37, py38, py39, py310, py311, pypy3] |
27 |
| - package: |
28 |
| - - "aiohttp-client" |
29 |
| - - "aiohttp-server" |
30 |
| - - "aiopg" |
31 |
| - - "aio-pika" |
32 |
| - - "asgi" |
33 |
| - - "asyncpg" |
34 |
| - - "aws-lambda" |
35 |
| - - "boto" |
36 |
| - - "boto3sqs" |
37 |
| - - "botocore" |
38 |
| - - "cassandra" |
39 |
| - - "celery" |
40 |
| - - "confluent-kafka" |
41 |
| - - "dbapi" |
42 |
| - - "django" |
43 |
| - - "elasticsearch" |
44 |
| - - "falcon" |
45 |
| - - "fastapi" |
46 |
| - - "flask" |
47 |
| - - "grpc" |
48 |
| - - "httpx" |
49 |
| - - "jinja2" |
50 |
| - - "kafka-python" |
51 |
| - - "logging" |
52 |
| - - "mysql" |
53 |
| - - "mysqlclient" |
54 |
| - - "pika" |
55 |
| - - "psycopg2" |
56 |
| - - "pymemcache" |
57 |
| - - "pymongo" |
58 |
| - - "pymysql" |
59 |
| - - "pyramid" |
60 |
| - - "redis" |
61 |
| - - "remoulade" |
62 |
| - - "requests" |
63 |
| - - "sklearn" |
64 |
| - - "sqlalchemy" |
65 |
| - - "sqlite3" |
66 |
| - - "starlette" |
67 |
| - - "system-metrics" |
68 |
| - - "tornado" |
69 |
| - - "tortoiseorm" |
70 |
| - - "urllib" |
71 |
| - - "urllib3" |
72 |
| - - "wsgi" |
73 |
| - - "distro" |
74 |
| - - "richconsole" |
75 |
| - - "prometheus-remote-write" |
76 |
| - - "sdkextension-aws" |
77 |
| - - "propagator-aws-xray" |
78 |
| - - "propagator-ot-trace" |
79 |
| - - "resource-detector-container" |
80 |
| - os: [ubuntu-20.04] |
81 |
| - steps: |
82 |
| - - name: Checkout Contrib Repo @ SHA - ${{ github.sha }} |
83 |
| - uses: actions/checkout@v2 |
84 |
| - - name: Set up Python ${{ env[matrix.python-version] }} |
85 |
| - uses: actions/setup-python@v4 |
86 |
| - with: |
87 |
| - python-version: ${{ env[matrix.python-version] }} |
88 |
| - - name: Install tox |
89 |
| - run: pip install tox==3.27.1 tox-factor |
90 |
| - - name: Cache tox environment |
91 |
| - # Preserves .tox directory between runs for faster installs |
92 |
| - uses: actions/cache@v1 |
93 |
| - with: |
94 |
| - path: | |
95 |
| - .tox |
96 |
| - ~/.cache/pip |
97 |
| - key: v7-build-tox-cache-${{ env.RUN_MATRIX_COMBINATION }}-${{ hashFiles('tox.ini', 'gen-requirements.txt', 'dev-requirements.txt') }} |
98 |
| - - name: run tox |
99 |
| - run: tox -f ${{ matrix.python-version }}-${{ matrix.package }} -- -ra --benchmark-json=${{ env.RUN_MATRIX_COMBINATION }}-benchmark.json |
100 |
| - # - name: Find and merge ${{ matrix.package }} benchmarks |
101 |
| - # # TODO: Add at least one benchmark to every package type to remove this (#249) |
102 |
| - # if: matrix.package == 'sdkextension' || matrix.package == 'propagator' |
103 |
| - # run: >- |
104 |
| - # mkdir -p benchmarks; |
105 |
| - # jq -s '.[0].benchmarks = ([.[].benchmarks] | add) |
106 |
| - # | if .[0].benchmarks == null then null else .[0] end' |
107 |
| - # **/**/tests/*${{ matrix.package }}*-benchmark.json > benchmarks/output_${{ matrix.package }}.json |
108 |
| - # - name: Upload all benchmarks under same key as an artifact |
109 |
| - # if: ${{ success() }} |
110 |
| - # uses: actions/upload-artifact@v2 |
111 |
| - # with: |
112 |
| - # name: benchmarks |
113 |
| - # path: benchmarks/output_${{ matrix.package }}.json |
114 |
| - # combine-benchmarks: |
115 |
| - # runs-on: ubuntu-latest |
116 |
| - # needs: build |
117 |
| - # if: ${{ always() }} |
118 |
| - # name: Combine benchmarks from previous build job |
119 |
| - # steps: |
120 |
| - # - name: Checkout Contrib Repo @ SHA - ${{ github.sha }} |
121 |
| - # uses: actions/checkout@v2 |
122 |
| - # - name: Download all benchmarks as artifact using key |
123 |
| - # uses: actions/download-artifact@v2 |
124 |
| - # with: |
125 |
| - # name: benchmarks |
126 |
| - # path: benchmarks |
127 |
| - # - name: Find and merge all benchmarks |
128 |
| - # run: >- |
129 |
| - # jq -s '.[0].benchmarks = ([.[].benchmarks] | add) |
130 |
| - # | if .[0].benchmarks == null then null else .[0] end' |
131 |
| - # benchmarks/output_*.json > output.json; |
132 |
| - # - name: Report on benchmark results |
133 |
| - # uses: benchmark-action/github-action-benchmark@v1 |
134 |
| - # with: |
135 |
| - # name: OpenTelemetry Python Benchmarks - Python ${{ env[matrix.python-version ]}} - ${{ matrix.package }} |
136 |
| - # tool: pytest |
137 |
| - # output-file-path: output.json |
138 |
| - # github-token: ${{ secrets.GITHUB_TOKEN }} |
139 |
| - # max-items-in-chart: 100 |
140 |
| - # # Alert with a commit comment on possible performance regression |
141 |
| - # alert-threshold: 200% |
142 |
| - # fail-on-alert: true |
143 |
| - # # Make a commit on `gh-pages` with benchmarks from previous step |
144 |
| - # auto-push: ${{ github.ref == 'refs/heads/main' }} |
145 |
| - # gh-pages-branch: gh-pages |
146 |
| - # benchmark-data-dir-path: benchmarks |
147 | 12 | misc:
|
148 | 13 | strategy:
|
149 | 14 | fail-fast: false
|
|
0 commit comments