Skip to content

Commit 6d70a51

Browse files
Merge branch 'open-telemetry:main' into grpc-aio-support
2 parents b6753c1 + 18e056b commit 6d70a51

File tree

104 files changed

+2496
-222
lines changed

Some content is hidden

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

104 files changed

+2496
-222
lines changed

.codespellrc

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
[codespell]
2+
# skipping auto generated folders
3+
skip = ./.tox,./.mypy_cache,./docs/_build,./target,*/LICENSE,./venv
4+
ignore-words-list = ot

.github/workflows/test.yml

+5-6
Original file line numberDiff line numberDiff line change
@@ -6,31 +6,30 @@ on:
66
- 'release/*'
77
pull_request:
88
env:
9-
CORE_REPO_SHA: ece57231cde5bb5656775a62f027cab0b1c76fce
9+
CORE_REPO_SHA: b3b0ba3a47dbdd844b524c46db22a60549364071
1010

1111
jobs:
1212
build:
1313
env:
1414
# We use these variables to convert between tox and GHA version literals
15-
py36: 3.6
1615
py37: 3.7
1716
py38: 3.8
1817
py39: 3.9
1918
py310: "3.10"
20-
pypy3: pypy3
19+
pypy3: "pypy3.7"
2120
RUN_MATRIX_COMBINATION: ${{ matrix.python-version }}-${{ matrix.package }}-${{ matrix.os }}
2221
runs-on: ${{ matrix.os }}
2322
strategy:
2423
fail-fast: false # ensures the entire test matrix is run, even if one permutation fails
2524
matrix:
26-
python-version: [ py36, py37, py38, py39, py310, pypy3 ]
25+
python-version: [ py37, py38, py39, py310, pypy3 ]
2726
package: ["instrumentation", "distro", "exporter", "sdkextension", "propagator"]
2827
os: [ ubuntu-20.04 ]
2928
steps:
3029
- name: Checkout Contrib Repo @ SHA - ${{ github.sha }}
3130
uses: actions/checkout@v2
3231
- name: Set up Python ${{ env[matrix.python-version] }}
33-
uses: actions/setup-python@v2
32+
uses: actions/setup-python@v4
3433
with:
3534
python-version: ${{ env[matrix.python-version] }}
3635
- name: Install tox
@@ -96,7 +95,7 @@ jobs:
9695
strategy:
9796
fail-fast: false
9897
matrix:
99-
tox-environment: [ "docker-tests", "lint", "docs", "generate" ]
98+
tox-environment: [ "docker-tests", "spellcheck", "lint", "docs", "generate" ]
10099
name: ${{ matrix.tox-environment }}
101100
runs-on: ubuntu-20.04
102101
steps:

CHANGELOG.md

+4-3
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
1111

1212
- `opentelemetry-instrumentation-boto3sqs` Make propagation compatible with other SQS instrumentations, add 'messaging.url' span attribute, and fix missing package dependencies.
1313
([#1234](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/1234))
14-
1514
- restoring metrics in django framework
1615
([#1208](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/1208))
16+
- `opentelemetry-instrumentation-aiohttp-client` Fix producing additional spans with each newly created ClientSession
17+
- ([#1246](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/1246))
1718

1819
## [1.12.0-0.33b0](https://github.com/open-telemetry/opentelemetry-python/releases/tag/v1.12.0-0.33b0) - 2022-08-08
1920

@@ -439,7 +440,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
439440
([#567](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/567))
440441
- `opentelemetry-instrumentation-grpc` Respect the suppress instrumentation in gRPC client instrumentor
441442
([#559](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/559))
442-
- `opentelemetry-instrumentation-grpc` Fixed asynchonous unary call traces
443+
- `opentelemetry-instrumentation-grpc` Fixed asynchronous unary call traces
443444
([#536](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/536))
444445
- `opentelemetry-sdk-extension-aws` Update AWS entry points to match spec
445446
([#566](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/566))
@@ -735,7 +736,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
735736
([#182](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/182))
736737
- `opentelemetry-instrumentation-botocore` Botocore SpanKind as CLIENT and modify existing traced attributes
737738
([#150](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/150))
738-
- `opentelemetry-instrumentation-dbapi` Update dbapi and its dependant instrumentations to follow semantic conventions
739+
- `opentelemetry-instrumentation-dbapi` Update dbapi and its dependent instrumentations to follow semantic conventions
739740
([#195](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/195))
740741
- `opentelemetry-instrumentation-dbapi` Stop capturing query parameters by default
741742
([#156](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/156))

CONTRIBUTING.md

+4-3
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ You can run:
4444
- `tox -e py37-test-flask` to e.g. run the Flask tests under a specific
4545
Python version
4646
- `tox -e lint` to run lint checks on all code
47+
- `tox -e spellcheck` to run spell check on the code
4748

4849
See
4950
[`tox.ini`](https://github.com/open-telemetry/opentelemetry-python-contrib/blob/main/tox.ini)
@@ -172,7 +173,7 @@ The continuation integration overrides that environment variable with as per the
172173

173174
* docstrings should adhere to the [Google Python Style
174175
Guide](http://google.github.io/styleguide/pyguide.html#38-comments-and-docstrings)
175-
as specified with the [napolean
176+
as specified with the [napoleon
176177
extension](http://www.sphinx-doc.org/en/master/usage/extensions/napoleon.html#google-vs-numpy)
177178
extension in [Sphinx](http://www.sphinx-doc.org/en/master/index.html).
178179

@@ -194,7 +195,7 @@ Below is a checklist of things to be mindful of when implementing a new instrume
194195
- https://github.com/open-telemetry/opentelemetry-python-contrib/issues/344 for more context
195196
- `exclude_urls` functionality
196197
- ex. https://github.com/open-telemetry/opentelemetry-python-contrib/blob/0fcb60d2ad139f78a52edd85b1cc4e32f2e962d0/instrumentation/opentelemetry-instrumentation-flask/src/opentelemetry/instrumentation/flask/__init__.py#L91
197-
- `url_filter` functonality
198+
- `url_filter` functionality
198199
- ex. https://github.com/open-telemetry/opentelemetry-python-contrib/blob/0fcb60d2ad139f78a52edd85b1cc4e32f2e962d0/instrumentation/opentelemetry-instrumentation-aiohttp-client/src/opentelemetry/instrumentation/aiohttp_client/__init__.py#L235
199200
- `is_recording()` optimization on non-sampled spans
200201
- ex. https://github.com/open-telemetry/opentelemetry-python-contrib/blob/main/instrumentation/opentelemetry-instrumentation-requests/src/opentelemetry/instrumentation/requests/__init__.py#L133
@@ -204,5 +205,5 @@ Below is a checklist of things to be mindful of when implementing a new instrume
204205

205206
## Expectations from contributors
206207

207-
OpenTelemetry is an open source community, and as such, greatly encourages contributions from anyone interested in the project. With that being said, there is a certain level of expectation from contributors even after a pull request is merged, specifically pertaining to instrumentations. The OpenTelemetry Python community expects contributors to maintain a level of support and interest in the instrumentations they contribute. This is to ensure that the instrumentation does not become stale and still functions the way the original contributor intended. Some instrumentations also pertain to libraries that the current memebers of the community are not so familiar with, so it is necessary to rely on the expertise of the original contributing parties.
208+
OpenTelemetry is an open source community, and as such, greatly encourages contributions from anyone interested in the project. With that being said, there is a certain level of expectation from contributors even after a pull request is merged, specifically pertaining to instrumentations. The OpenTelemetry Python community expects contributors to maintain a level of support and interest in the instrumentations they contribute. This is to ensure that the instrumentation does not become stale and still functions the way the original contributor intended. Some instrumentations also pertain to libraries that the current members of the community are not so familiar with, so it is necessary to rely on the expertise of the original contributing parties.
208209

_template/setup.cfg

+1-2
Original file line numberDiff line numberDiff line change
@@ -34,14 +34,13 @@ classifiers =
3434
License :: OSI Approved :: Apache Software License
3535
Programming Language :: Python
3636
Programming Language :: Python :: 3
37-
Programming Language :: Python :: 3.6
3837
Programming Language :: Python :: 3.7
3938
Programming Language :: Python :: 3.8
4039
Programming Language :: Python :: 3.9
4140
Programming Language :: Python :: 3.10
4241

4342
[options]
44-
python_requires = >=3.6
43+
python_requires = >=3.7
4544
package_dir=
4645
=src
4746
packages=find_namespace:

dev-requirements.txt

+1
Original file line numberDiff line numberDiff line change
@@ -15,3 +15,4 @@ grpcio-tools==1.29.0
1515
mypy-protobuf>=1.23
1616
protobuf~=3.13
1717
markupsafe==2.0.1
18+
codespell==2.1.0

exporter/opentelemetry-exporter-datadog/setup.cfg

+1-2
Original file line numberDiff line numberDiff line change
@@ -28,14 +28,13 @@ classifiers =
2828
License :: OSI Approved :: Apache Software License
2929
Programming Language :: Python
3030
Programming Language :: Python :: 3
31-
Programming Language :: Python :: 3.6
3231
Programming Language :: Python :: 3.7
3332
Programming Language :: Python :: 3.8
3433
Programming Language :: Python :: 3.9
3534
Programming Language :: Python :: 3.10
3635

3736
[options]
38-
python_requires = >=3.6
37+
python_requires = >=3.7
3938
package_dir=
4039
=src
4140
packages=find_namespace:

exporter/opentelemetry-exporter-datadog/src/opentelemetry/exporter/datadog/exporter.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@ def _translate_to_datadog(self, spans):
127127

128128
# datadog Span is initialized with a reference to the tracer which is
129129
# used to record the span when it is finished. We can skip ignore this
130-
# because we are not calling the finish method and explictly set the
130+
# because we are not calling the finish method and explicitly set the
131131
# duration.
132132
tracer = None
133133

exporter/opentelemetry-exporter-datadog/src/opentelemetry/exporter/datadog/spanprocessor.py

+4-4
Original file line numberDiff line numberDiff line change
@@ -16,13 +16,13 @@
1616
import logging
1717
import threading
1818
import typing
19+
from time import time_ns
1920

2021
from opentelemetry.context import Context, attach, detach, set_value
2122
from opentelemetry.instrumentation.utils import _SUPPRESS_INSTRUMENTATION_KEY
2223
from opentelemetry.sdk.trace import Span, SpanProcessor
2324
from opentelemetry.sdk.trace.export import SpanExporter
2425
from opentelemetry.trace import INVALID_TRACE_ID
25-
from opentelemetry.util._time import _time_ns
2626

2727
logger = logging.getLogger(__name__)
2828

@@ -127,10 +127,10 @@ def worker(self):
127127
# missing spans will be sent when calling flush
128128
break
129129

130-
# substract the duration of this export call to the next timeout
131-
start = _time_ns()
130+
# subtract the duration of this export call to the next timeout
131+
start = time_ns()
132132
self.export()
133-
end = _time_ns()
133+
end = time_ns()
134134
duration = (end - start) / 1e9
135135
timeout = self.schedule_delay_millis / 1e3 - duration
136136

exporter/opentelemetry-exporter-richconsole/setup.cfg

+1-2
Original file line numberDiff line numberDiff line change
@@ -28,14 +28,13 @@ classifiers =
2828
License :: OSI Approved :: Apache Software License
2929
Programming Language :: Python
3030
Programming Language :: Python :: 3
31-
Programming Language :: Python :: 3.6
3231
Programming Language :: Python :: 3.7
3332
Programming Language :: Python :: 3.8
3433
Programming Language :: Python :: 3.9
3534
Programming Language :: Python :: 3.10
3635

3736
[options]
38-
python_requires = >=3.6
37+
python_requires = >=3.7
3938
package_dir=
4039
=src
4140
packages=find_namespace:

0 commit comments

Comments
 (0)