Skip to content

Commit aec86be

Browse files
[MegaLinter] Apply linters fixes
1 parent 63e5bdb commit aec86be

File tree

12 files changed

+22
-27
lines changed

12 files changed

+22
-27
lines changed

newrelic/core/infinite_tracing_pb2.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,8 @@
2121

2222
# Import appropriate generated pb2 file for protobuf version
2323
if PROTOBUF_VERSION >= (5,):
24-
from newrelic.core.infinite_tracing_v5_pb2 import AttributeValue, RecordStatus, Span, SpanBatch # noqa: F401
24+
from newrelic.core.infinite_tracing_v5_pb2 import AttributeValue, RecordStatus, Span, SpanBatch
2525
elif PROTOBUF_VERSION >= (4,):
26-
from newrelic.core.infinite_tracing_v4_pb2 import AttributeValue, RecordStatus, Span, SpanBatch # noqa: F401
26+
from newrelic.core.infinite_tracing_v4_pb2 import AttributeValue, RecordStatus, Span, SpanBatch
2727
else:
2828
from newrelic.core.infinite_tracing_v3_pb2 import AttributeValue, RecordStatus, Span, SpanBatch # noqa: F401

tests/agent_features/_test_code_level_metrics.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,5 +72,5 @@ def __call__(self):
7272
TYPE_CONSTRUCTOR_CLASS_INSTANCE = ExerciseTypeConstructor()
7373
TYPE_CONSTRUCTOR_CALLABLE_CLASS_INSTANCE = ExerciseTypeConstructorCallable()
7474

75-
exercise_lambda = lambda: None # noqa: E731
75+
exercise_lambda = lambda: None
7676
exercise_partial = functools.partial(exercise_function)

tests/datastore_aredis/test_trace_node.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -80,26 +80,26 @@ async def _exercise_db():
8080
@override_application_settings(_enable_instance_settings)
8181
@validate_tt_collector_json(datastore_params=_enabled_required, datastore_forgone_params=_enabled_forgone)
8282
@background_task()
83-
def test_trace_node_datastore_params_enable_instance(loop): # noqa: F811
83+
def test_trace_node_datastore_params_enable_instance(loop):
8484
loop.run_until_complete(_exercise_db())
8585

8686

8787
@override_application_settings(_disable_instance_settings)
8888
@validate_tt_collector_json(datastore_params=_disabled_required, datastore_forgone_params=_disabled_forgone)
8989
@background_task()
90-
def test_trace_node_datastore_params_disable_instance(loop): # noqa: F811
90+
def test_trace_node_datastore_params_disable_instance(loop):
9191
loop.run_until_complete(_exercise_db())
9292

9393

9494
@override_application_settings(_instance_only_settings)
9595
@validate_tt_collector_json(datastore_params=_instance_only_required, datastore_forgone_params=_instance_only_forgone)
9696
@background_task()
97-
def test_trace_node_datastore_params_instance_only(loop): # noqa: F811
97+
def test_trace_node_datastore_params_instance_only(loop):
9898
loop.run_until_complete(_exercise_db())
9999

100100

101101
@override_application_settings(_database_only_settings)
102102
@validate_tt_collector_json(datastore_params=_database_only_required, datastore_forgone_params=_database_only_forgone)
103103
@background_task()
104-
def test_trace_node_datastore_params_database_only(loop): # noqa: F811
104+
def test_trace_node_datastore_params_database_only(loop):
105105
loop.run_until_complete(_exercise_db())

tests/datastore_elasticsearch/test_async_mget.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
import pytest
1616
from conftest import ES_MULTIPLE_SETTINGS, ES_VERSION
1717
from elasticsearch import AsyncElasticsearch
18-
from testing_support.fixture.event_loop import event_loop as loop # noqa: F401
18+
from testing_support.fixture.event_loop import event_loop as loop
1919
from testing_support.fixtures import override_application_settings
2020
from testing_support.util import instance_hostname
2121
from testing_support.validators.validate_transaction_metrics import validate_transaction_metrics

tests/datastore_elasticsearch/test_async_trace_node.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
# limitations under the License.
1414

1515
from conftest import ES_SETTINGS, ES_VERSION
16-
from testing_support.fixture.event_loop import event_loop as loop # noqa: F401
16+
from testing_support.fixture.event_loop import event_loop as loop
1717
from testing_support.fixtures import override_application_settings, validate_tt_parenting
1818
from testing_support.util import instance_hostname
1919
from testing_support.validators.validate_tt_collector_json import validate_tt_collector_json

tests/external_aiobotocore/test_bedrock_chat_completion.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
chat_completion_streaming_expected_events,
3434
)
3535
from testing_support.fixtures import override_llm_token_callback_settings, reset_core_stats_engine, validate_attributes
36-
from testing_support.ml_testing_utils import ( # noqa: F401
36+
from testing_support.ml_testing_utils import (
3737
add_token_count_to_events,
3838
disabled_ai_monitoring_record_content_settings,
3939
disabled_ai_monitoring_settings,

tests/external_aiobotocore/test_bedrock_embeddings.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
embedding_payload_templates,
2727
)
2828
from testing_support.fixtures import override_llm_token_callback_settings, reset_core_stats_engine, validate_attributes
29-
from testing_support.ml_testing_utils import ( # noqa: F401
29+
from testing_support.ml_testing_utils import (
3030
add_token_count_to_events,
3131
disabled_ai_monitoring_record_content_settings,
3232
disabled_ai_monitoring_settings,

tests/framework_aiohttp/_target_application.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ async def index(request):
2929

3030
async def hang(request):
3131
while True: # noqa: ASYNC110
32-
await asyncio.sleep(0) # noqa: ASYNC110
32+
await asyncio.sleep(0)
3333

3434

3535
async def error(request):

tests/messagebroker_kombu/conftest.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
from amqp.exceptions import NotFound
2222
from kombu import messaging, serialization
2323
from testing_support.db_settings import rabbitmq_settings
24-
from testing_support.fixtures import collector_agent_registration_fixture, collector_available_fixture # noqa: F401
24+
from testing_support.fixtures import collector_agent_registration_fixture, collector_available_fixture
2525
from testing_support.validators.validate_distributed_trace_accepted import validate_distributed_trace_accepted
2626

2727
from newrelic.api.transaction import current_transaction

tests/mlmodel_gemini/conftest.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@
5353

5454

5555
@pytest.fixture(scope="session")
56-
def gemini_clients(MockExternalGeminiServer): # noqa: F811
56+
def gemini_clients(MockExternalGeminiServer):
5757
"""
5858
This configures the Gemini client and returns it
5959
"""
@@ -104,7 +104,7 @@ def gemini_server(gemini_clients, wrap_httpx_client_send):
104104

105105

106106
@pytest.fixture(scope="session")
107-
def wrap_httpx_client_send(extract_shortened_prompt): # noqa: F811
107+
def wrap_httpx_client_send(extract_shortened_prompt):
108108
def _wrap_httpx_client_send(wrapped, instance, args, kwargs):
109109
bound_args = bind_args(wrapped, args, kwargs)
110110
request = bound_args["request"]

0 commit comments

Comments
 (0)