Skip to content

Commit 7e35498

Browse files
committed
run ruff for real in entire codebase - all files changed by ruff are in this commit
Signed-off-by: emdneto <[email protected]>
1 parent aa025a2 commit 7e35498

File tree

133 files changed

+302
-559
lines changed

Some content is hidden

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

133 files changed

+302
-559
lines changed

.github/workflows/generate_workflows.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
from pathlib import Path
22

33
from generate_workflows_lib import (
4-
generate_test_workflow,
5-
generate_lint_workflow,
64
generate_contrib_workflow,
7-
generate_misc_workflow
5+
generate_lint_workflow,
6+
generate_misc_workflow,
7+
generate_test_workflow,
88
)
99

1010
tox_ini_path = Path(__file__).parent.parent.parent.joinpath("tox.ini")

docs/conf.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -204,9 +204,7 @@
204204
.. |SCM_WEB| replace:: {s}
205205
.. |SCM_RAW_WEB| replace:: {sr}
206206
.. |SCM_BRANCH| replace:: {b}
207-
""".format(
208-
s=scm_web, sr=scm_raw_web, b=branch
209-
)
207+
""".format(s=scm_web, sr=scm_raw_web, b=branch)
210208

211209
# used to have links to repo files
212210
extlinks = {

docs/examples/auto-instrumentation/client.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,6 @@
3535
assert len(argv) == 2
3636

3737
with tracer.start_as_current_span("client"):
38-
3938
with tracer.start_as_current_span("client-server"):
4039
headers = {}
4140
inject(headers)

docs/examples/django/client.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,6 @@
3333

3434

3535
with tracer.start_as_current_span("client"):
36-
3736
with tracer.start_as_current_span("client-server"):
3837
headers = {}
3938
inject(headers)

docs/examples/django/instrumentation_example/urls.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@
2626
1. Import the include() function: from django.urls import include, path
2727
2. Add a URL to urlpatterns: path("blog/", include("blog.urls"))
2828
"""
29+
2930
from django.contrib import admin
3031
from django.urls import include, path
3132

docs/examples/django/manage.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
# limitations under the License.
1515

1616
"""Django"s command-line utility for administrative tasks."""
17+
1718
import os
1819
import sys
1920

docs/examples/error_handler/error_handler_0/src/error_handler_0/__init__.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,5 +21,4 @@
2121

2222
class ErrorHandler0(ErrorHandler, ZeroDivisionError):
2323
def _handle(self, error: Exception, *args, **kwargs):
24-
2524
logger.exception("ErrorHandler0 handling a ZeroDivisionError")

docs/examples/error_handler/error_handler_1/src/error_handler_1/__init__.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@
2222
# pylint: disable=too-many-ancestors
2323
class ErrorHandler1(ErrorHandler, IndexError, KeyError):
2424
def _handle(self, error: Exception, *args, **kwargs):
25-
2625
if isinstance(error, IndexError):
2726
logger.exception("ErrorHandler1 handling an IndexError")
2827

docs/examples/opentracing/rediscache.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@ def __call__(self, func):
3030
@wraps(func)
3131
def inner(*args, **kwargs):
3232
with self.tracer.start_active_span("Caching decorator") as scope1:
33-
3433
# Pickle the call args to get a canonical key. Don't do this in
3534
# prod!
3635
key = pickle.dumps((func.__qualname__, args, kwargs))

exporter/opentelemetry-exporter-opencensus/src/opentelemetry/exporter/opencensus/trace_exporter/__init__.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,6 @@ def translate_to_collector(spans: Sequence[ReadableSpan]):
144144

145145
if span.events:
146146
for event in span.events:
147-
148147
collector_annotation = trace_pb2.Span.TimeEvent.Annotation(
149148
description=trace_pb2.TruncatableString(value=event.name)
150149
)

0 commit comments

Comments
 (0)