Skip to content

Commit

Permalink
tox
Browse files Browse the repository at this point in the history
  • Loading branch information
lzchen committed Apr 23, 2021
1 parent 2bfc78a commit 438678e
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 26 deletions.
48 changes: 24 additions & 24 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,30 +47,30 @@ jobs:
key: tox-cache-${{ env.RUN_MATRIX_COMBINATION }}-${{ hashFiles('tox.ini', 'dev-requirements.txt') }}
- name: run tox
run: tox -f ${{ matrix.python-version }}-${{ matrix.package }}
# - name: Find and merge benchmarks
# # TODO: Add at least one benchmark to every package type to remove this (#249)
# if: matrix.package == 'sdkextension'
# run: >-
# jq -s '.[0].benchmarks = ([.[].benchmarks] | add)
# | if .[0].benchmarks == null then null else .[0] end'
# **/**/tests/*${{ matrix.package }}*-benchmark.json > output.json
# - name: Report on benchmark results
# # TODO: Add at least one benchmark to every package type to remove this (#249)
# if: matrix.package == 'sdkextension'
# uses: rhysd/github-action-benchmark@v1
# with:
# name: OpenTelemetry Python Benchmarks - Python ${{ env[matrix.python-version ]}} - ${{ matrix.package }}
# tool: pytest
# output-file-path: output.json
# github-token: ${{ secrets.GITHUB_TOKEN }}
# max-items-in-chart: 100
# # Alert with a commit comment on possible performance regression
# alert-threshold: 200%
# fail-on-alert: true
# # Make a commit on `gh-pages` with benchmarks from previous step
# auto-push: ${{ github.ref == 'refs/heads/main' }}
# gh-pages-branch: gh-pages
# benchmark-data-dir-path: benchmarks
- name: Find and merge benchmarks
# TODO: Add at least one benchmark to every package type to remove this (#249)
if: matrix.package == 'sdkextension'
run: >-
jq -s '.[0].benchmarks = ([.[].benchmarks] | add)
| if .[0].benchmarks == null then null else .[0] end'
**/**/tests/*${{ matrix.package }}*-benchmark.json > output.json
- name: Report on benchmark results
# TODO: Add at least one benchmark to every package type to remove this (#249)
if: matrix.package == 'sdkextension'
uses: rhysd/github-action-benchmark@v1
with:
name: OpenTelemetry Python Benchmarks - Python ${{ env[matrix.python-version ]}} - ${{ matrix.package }}
tool: pytest
output-file-path: output.json
github-token: ${{ secrets.GITHUB_TOKEN }}
max-items-in-chart: 100
# Alert with a commit comment on possible performance regression
alert-threshold: 200%
fail-on-alert: true
# Make a commit on `gh-pages` with benchmarks from previous step
auto-push: ${{ github.ref == 'refs/heads/main' }}
gh-pages-branch: gh-pages
benchmark-data-dir-path: benchmarks
misc:
strategy:
fail-fast: false
Expand Down
4 changes: 2 additions & 2 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -292,7 +292,7 @@ commands_pre =

sqlalchemy: pip install {toxinidir}/instrumentation/opentelemetry-instrumentation-sqlalchemy

elasticsearch{2,5,6,7}: pip install {toxinidir}/opentelemetry-python-core/opentelemetry-instrumentation {toxinidir}/instrumentation/opentelemetry-instrumentation-elasticsearch[test]
elasticsearch{2,5,6,7}: pip install {toxinidir}/instrumentation/opentelemetry-instrumentation-elasticsearch[test]

aws: pip install requests {toxinidir}/sdk-extension/opentelemetry-sdk-extension-aws

Expand Down Expand Up @@ -385,7 +385,7 @@ commands_pre =
python -m pip install -e {toxinidir}/propagator/opentelemetry-propagator-ot-trace[test]

commands =
python scripts/eachdist.py lint --check-only
python scripts/eachdist.py lint

[testenv:docker-tests]
deps =
Expand Down

0 comments on commit 438678e

Please sign in to comment.