Skip to content

Commit

Permalink
Disable linter false positives (#4306)
Browse files Browse the repository at this point in the history
Disable false positives related to no-member in protobuf files.

Related: #4305
  • Loading branch information
jonathanmetzman authored Oct 9, 2024
1 parent 1ea9de5 commit 9e7b8b1
Show file tree
Hide file tree
Showing 6 changed files with 14 additions and 14 deletions.
4 changes: 2 additions & 2 deletions src/clusterfuzz/_internal/bot/tasks/utasks/analyze_task.py
Original file line number Diff line number Diff line change
Expand Up @@ -151,8 +151,8 @@ def setup_testcase_and_build(
# to setup correctly.
if not build_manager.check_app_path():
# Let postprocess handle ANALYZE_BUILD_SETUP and restart tasks if needed.
return None, uworker_msg_pb2.Output(
error_type=uworker_msg_pb2.ErrorType.ANALYZE_BUILD_SETUP)
return None, uworker_msg_pb2.Output( # pylint: disable=no-member
error_type=uworker_msg_pb2.ErrorType.ANALYZE_BUILD_SETUP) # pylint: disable=no-member

update_testcase_after_build_setup(testcase)
testcase.absolute_path = testcase_file_path
Expand Down
4 changes: 2 additions & 2 deletions src/clusterfuzz/_internal/bot/tasks/utasks/minimize_task.py
Original file line number Diff line number Diff line change
Expand Up @@ -430,8 +430,8 @@ def utask_main(uworker_input: uworker_msg_pb2.Input): # pylint: disable=no-memb
# to setup correctly.
if not build_manager.check_app_path():
logs.error('Unable to setup build for minimization.')
return uworker_msg_pb2.Output(
error_type=uworker_msg_pb2.ErrorType.MINIMIZE_SETUP)
return uworker_msg_pb2.Output( # pylint: disable=no-member
error_type=uworker_msg_pb2.ErrorType.MINIMIZE_SETUP) # pylint: disable=no-member

if environment.is_libfuzzer_job():
fuzz_target = testcase_manager.get_fuzz_target_from_input(uworker_input)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -259,9 +259,9 @@ def _check_fixed_for_custom_binary(testcase: data_types.Testcase,
revision = 0

if not build_manager.check_app_path():
return uworker_msg_pb2.Output(
return uworker_msg_pb2.Output( # pylint: disable=no-member
error_message='Build setup failed for custom binary',
error_type=uworker_msg_pb2.ErrorType.PROGRESSION_BUILD_SETUP_ERROR)
error_type=uworker_msg_pb2.ErrorType.PROGRESSION_BUILD_SETUP_ERROR) # pylint: disable=no-member

test_timeout = environment.get_value('TEST_TIMEOUT', 10)
fuzz_target = testcase_manager.get_fuzz_target_from_input(uworker_input)
Expand Down Expand Up @@ -333,10 +333,10 @@ def _testcase_reproduces_in_revision(
if not build_manager.check_app_path():
# Let postprocess handle the failure and reschedule the task if needed.
error_message = f'Build setup failed at r{revision}'
return None, uworker_msg_pb2.Output(
return None, uworker_msg_pb2.Output( # pylint: disable=no-member
error_message=error_message,
progression_task_output=progression_task_output,
error_type=uworker_msg_pb2.ErrorType.PROGRESSION_BUILD_SETUP_ERROR)
error_type=uworker_msg_pb2.ErrorType.PROGRESSION_BUILD_SETUP_ERROR) # pylint: disable=no-member

build_data = testcase_manager.check_for_bad_build(job_type, revision)
progression_task_output.build_data_list.append(build_data)
Expand Down
4 changes: 2 additions & 2 deletions src/clusterfuzz/_internal/bot/tasks/utasks/regression_task.py
Original file line number Diff line number Diff line change
Expand Up @@ -123,10 +123,10 @@ def _testcase_reproduces_in_revision(
build_manager.setup_build(revision, fuzz_target=fuzz_target_binary)
if not build_manager.check_app_path():
error_message = f'Build setup failed r{revision}'
return None, uworker_msg_pb2.Output(
return None, uworker_msg_pb2.Output( # pylint: disable=no-member
regression_task_output=regression_task_output,
error_message=error_message,
error_type=uworker_msg_pb2.ErrorType.REGRESSION_BUILD_SETUP_ERROR)
error_type=uworker_msg_pb2.ErrorType.REGRESSION_BUILD_SETUP_ERROR) # pylint: disable=no-member

build_data = testcase_manager.check_for_bad_build(job_type, revision)
regression_task_output.build_data_list.append(build_data)
Expand Down
4 changes: 2 additions & 2 deletions src/clusterfuzz/_internal/bot/tasks/utasks/symbolize_task.py
Original file line number Diff line number Diff line change
Expand Up @@ -114,9 +114,9 @@ def utask_main(uworker_input):
crash_revision = environment.get_value('APP_REVISION')

if not build_manager.check_app_path():
return uworker_msg_pb2.Output(
return uworker_msg_pb2.Output( # pylint: disable=no-member
error_message='Build setup failed',
error_type=uworker_msg_pb2.ErrorType.SYMBOLIZE_BUILD_SETUP_ERROR)
error_type=uworker_msg_pb2.ErrorType.SYMBOLIZE_BUILD_SETUP_ERROR) # pylint: disable=no-member

# ASAN tool settings (if the tool is used).
# See if we can get better stacks with higher redzone sizes.
Expand Down
4 changes: 2 additions & 2 deletions src/clusterfuzz/_internal/bot/tasks/utasks/variant_task.py
Original file line number Diff line number Diff line change
Expand Up @@ -120,8 +120,8 @@ def utask_main(uworker_input):
# Check if we have an application path. If not, our build failed to setup
# correctly.
if not build_manager.check_app_path():
return uworker_msg_pb2.Output(
error_type=uworker_msg_pb2.ErrorType.VARIANT_BUILD_SETUP)
return uworker_msg_pb2.Output( # pylint: disable=no-member
error_type=uworker_msg_pb2.ErrorType.VARIANT_BUILD_SETUP) # pylint: disable=no-member

# Disable gestures if we're running on a different platform from that of
# the original test case.
Expand Down

0 comments on commit 9e7b8b1

Please sign in to comment.