Skip to content

Commit bf0c681

Browse files
owaisaabmass
andcommitted
Update opentelemetry-instrumentation/src/opentelemetry/instrumentation/propagators.py
Co-authored-by: Aaron Abbott <aaronabbott@google.com>
1 parent 77bce6f commit bf0c681

File tree

4 files changed

+8
-25
lines changed

4 files changed

+8
-25
lines changed

opentelemetry-instrumentation/setup.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,4 @@
2424
with open(VERSION_FILENAME) as f:
2525
exec(f.read(), PACKAGE_INFO)
2626

27-
setuptools.setup(
28-
version=PACKAGE_INFO["__version__"],
29-
)
27+
setuptools.setup(version=PACKAGE_INFO["__version__"],)

opentelemetry-instrumentation/src/opentelemetry/instrumentation/propagators.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@
1313
# limitations under the License.
1414

1515
"""
16-
This module implements experimental propagators to inject trace response context
17-
into HTTP responses. This is useful for server side frameworks that start traces
16+
This module implements experimental propagators to inject trace context
17+
into response carriers. This is useful for server side frameworks that start traces
1818
when server requests and want to share the trace context with the client so the
1919
client can add it's spans to the same trace.
2020

opentelemetry-instrumentation/tests/test_bootstrap.py

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,7 @@
2323

2424

2525
def sample_packages(packages, rate):
26-
sampled = sample(
27-
list(packages),
28-
int(len(packages) * rate),
29-
)
26+
sampled = sample(list(packages), int(len(packages) * rate),)
3027
return {k: v for k, v in packages.items() if k in sampled}
3128

3229

opentelemetry-instrumentation/tests/test_utils.py

Lines changed: 4 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -31,24 +31,12 @@ def test_http_status_to_status_code(self):
3131
(HTTPStatus.UNAUTHORIZED, StatusCode.ERROR),
3232
(HTTPStatus.FORBIDDEN, StatusCode.ERROR),
3333
(HTTPStatus.NOT_FOUND, StatusCode.ERROR),
34-
(
35-
HTTPStatus.UNPROCESSABLE_ENTITY,
36-
StatusCode.ERROR,
37-
),
38-
(
39-
HTTPStatus.TOO_MANY_REQUESTS,
40-
StatusCode.ERROR,
41-
),
34+
(HTTPStatus.UNPROCESSABLE_ENTITY, StatusCode.ERROR,),
35+
(HTTPStatus.TOO_MANY_REQUESTS, StatusCode.ERROR,),
4236
(HTTPStatus.NOT_IMPLEMENTED, StatusCode.ERROR),
4337
(HTTPStatus.SERVICE_UNAVAILABLE, StatusCode.ERROR),
44-
(
45-
HTTPStatus.GATEWAY_TIMEOUT,
46-
StatusCode.ERROR,
47-
),
48-
(
49-
HTTPStatus.HTTP_VERSION_NOT_SUPPORTED,
50-
StatusCode.ERROR,
51-
),
38+
(HTTPStatus.GATEWAY_TIMEOUT, StatusCode.ERROR,),
39+
(HTTPStatus.HTTP_VERSION_NOT_SUPPORTED, StatusCode.ERROR,),
5240
(600, StatusCode.ERROR),
5341
(99, StatusCode.ERROR),
5442
):

0 commit comments

Comments
 (0)