Skip to content

Commit b29eb1a

Browse files
committed
Merge remote-tracking branch 'upstream/master' into majorgreys/pr440
2 parents f6b551c + a7f0b75 commit b29eb1a

762 files changed

Lines changed: 44141 additions & 5420 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.circleci/config.yml

Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
version: 2.1
2+
3+
executors:
4+
python38:
5+
docker:
6+
- image: circleci/python:3.8
7+
8+
commands:
9+
setup_tox:
10+
description: "Install tox"
11+
steps:
12+
- run: pip install -U tox-factor
13+
14+
restore_tox_cache:
15+
description: "Restore .tox directory from previous runs for faster installs"
16+
steps:
17+
- restore_cache:
18+
# In the cache key:
19+
# - .Environment.CIRCLE_JOB: We do separate tox environments by job name, so caching and restoring is
20+
# much faster.
21+
key: tox-cache-{{ .Environment.CIRCLE_JOB }}-{{ checksum "tox.ini" }}-{{ checksum "dev-requirements.txt" }}
22+
23+
save_tox_cache:
24+
description: "Save .tox directory into cache for faster installs next time"
25+
steps:
26+
- save_cache:
27+
# In the cache key:
28+
# - .Environment.CIRCLE_JOB: We do separate tox environments by job name, so caching and restoring is
29+
# much faster.
30+
key: tox-cache-{{ .Environment.CIRCLE_JOB }}-{{ checksum "tox.ini" }}-{{ checksum "dev-requirements.txt" }}
31+
paths:
32+
- ".tox"
33+
34+
jobs:
35+
docs:
36+
executor: python38
37+
steps:
38+
- checkout
39+
- setup_tox
40+
- restore_tox_cache
41+
- run: tox -e docs
42+
- save_tox_cache
43+
44+
lint:
45+
executor: python38
46+
steps:
47+
- checkout
48+
- setup_tox
49+
- restore_tox_cache
50+
- run: tox -e lint
51+
- save_tox_cache
52+
53+
workflows:
54+
main:
55+
jobs:
56+
- docs
57+
- lint

.flake8

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,8 @@
22
ignore =
33
E501 # line too long, defer to black
44
F401 # unused import, defer to pylint
5-
W503 # allow line breaks after binary ops, not after
5+
W503 # allow line breaks before binary ops
6+
W504 # allow line breaks after binary ops
67
E203 # allow whitespace before ':' (https://github.com/psf/black#slices)
78
exclude =
89
.bzr
@@ -17,3 +18,6 @@ exclude =
1718
__pycache__
1819
ext/opentelemetry-ext-jaeger/src/opentelemetry/ext/jaeger/gen/
1920
ext/opentelemetry-ext-jaeger/build/*
21+
docs/examples/opentelemetry-example-app/src/opentelemetry_example_app/grpc/gen/
22+
docs/examples/opentelemetry-example-app/build/*
23+
opentelemetry-proto/src/opentelemetry/proto/

.github/workflows/publish.yml

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,24 @@ jobs:
1414
python-version: '3.7'
1515
- name: Build wheels
1616
run: ./scripts/build.sh
17+
- name: Install twine
18+
run: |
19+
pip install twine
20+
# The step below publishes to testpypi in order to catch any issues
21+
# with the package configuration that would cause a failure to upload
22+
# to pypi. One example of such a failure is if a classifier is
23+
# rejected by pypi (e.g "3 - Beta"). This would cause a failure during the
24+
# middle of the package upload causing the action to fail, and certain packages
25+
# might have already been updated, this would be bad.
26+
- name: Publish to TestPyPI
27+
env:
28+
TWINE_USERNAME: ${{ secrets.test_pypi_username }}
29+
TWINE_PASSWORD: ${{ secrets.test_pypi_password }}
30+
run: |
31+
twine upload --repository testpypi --skip-existing --verbose dist/*
1732
- name: Publish to PyPI
1833
env:
1934
TWINE_USERNAME: '__token__'
2035
TWINE_PASSWORD: ${{ secrets.pypi_password }}
2136
run: |
22-
pip install twine
2337
twine upload --skip-existing --verbose dist/*

.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,3 +56,7 @@ _build/
5656
# mypy
5757
.mypy_cache/
5858
target
59+
60+
# Django example
61+
62+
docs/examples/django/db.sqlite3

.isort.cfg

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,5 +13,6 @@ line_length=79
1313
; docs: https://github.com/timothycrosley/isort#multi-line-output-modes
1414
multi_line_output=3
1515
skip=target
16-
skip_glob=ext/opentelemetry-ext-jaeger/src/opentelemetry/ext/jaeger/gen/*,.venv*/*,venv*/*
17-
known_first_party=opentelemetry
16+
skip_glob=**/gen/*,.venv*/*,venv*/*,**/proto/*
17+
known_first_party=opentelemetry,opentelemetry_example_app
18+
known_third_party=psutil,pytest,redis,redis_opentracing

.pylintrc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ extension-pkg-whitelist=
77

88
# Add files or directories to the blacklist. They should be base names, not
99
# paths.
10-
ignore=CVS,gen
10+
ignore=CVS,gen,proto
1111

1212
# Add files or directories matching the regex patterns to the blacklist. The
1313
# regex matches against base names, not paths.
@@ -226,7 +226,7 @@ dummy-variables-rgx=_+$|(_[a-zA-Z0-9_]*[a-zA-Z0-9]+?$)|dummy|^ignored_|^unused_
226226

227227
# Argument names that match this expression will be ignored. Default to name
228228
# with leading underscore.
229-
ignored-argument-names=_.*|^ignored_|^unused_
229+
ignored-argument-names=_.*|^ignored_|^unused_|^kwargs|^args
230230

231231
# Tells whether we should check for unused import in __init__ files.
232232
init-import=no

.readthedocs.yml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
# Read the Docs configuration file
2+
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details
3+
version: 2
4+
5+
sphinx:
6+
configuration: docs/conf.py
7+
8+
build:
9+
image: latest
10+
11+
python:
12+
version: 3.8
13+
install:
14+
- requirements: docs-requirements.txt

.travis.yml

Lines changed: 16 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,22 @@ dist: xenial
22

33
language: python
44

5-
python:
6-
- '3.4'
7-
- '3.5'
8-
- '3.6'
9-
- '3.7'
10-
- '3.8'
11-
- 'pypy3'
5+
cache: pip
6+
7+
matrix:
8+
include:
9+
- python: 3.8
10+
env: TOXENV=lint
11+
- python: pypy3
12+
- python: 3.8
13+
- python: 3.4
14+
- python: 3.5
15+
- python: 3.6
16+
- python: 3.7
17+
- python: 3.8
18+
env: TOXENV=docker-tests
19+
- python: 3.8
20+
env: TOXENV=docs
1221

1322
#matrix:
1423
# allow_failures:

CONTRIBUTING.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,16 @@ on how to become a [**Member**](https://github.com/open-telemetry/community/blob
1313
[**Approver**](https://github.com/open-telemetry/community/blob/master/community-membership.md#approver)
1414
and [**Maintainer**](https://github.com/open-telemetry/community/blob/master/community-membership.md#maintainer).
1515

16+
# Find your right repo
17+
18+
This is the main repo for OpenTelemetry Python. Nevertheless, there are other repos that are related to this project.
19+
Please take a look at this list first, your contributions may belong in one of these repos better:
20+
21+
1. [OpenTelemetry Contrib](https://github.com/open-telemetry/opentelemetry-python-contrib): Instrumentations for third-party
22+
libraries and frameworks. There is an ongoing effort to migrate into the Opentelemetry Contrib repo some of the existing
23+
programmatic instrumentations that are now in the `ext` directory in the main OpenTelemetry repo. Please ask in the Gitter
24+
channel (see below) for guidance if you want to contribute with these instrumentations.
25+
1626
## Find a Buddy and get Started Quickly!
1727

1828
If you are looking for someone to help you find a starting point and be a resource for your first contribution, join our

0 commit comments

Comments
 (0)