google / clusterfuzz

Scalable fuzzing infrastructure.
https://google.github.io/clusterfuzz
Apache License 2.0
5.29k stars 554 forks source link

Fix wrong-import-order false positive #4138

Open jonathanmetzman opened 2 months ago

jonathanmetzman commented 2 months ago

This breaks appengine imports

| src/clusterfuzz/_internal/tests/appengine/handlers/testcase_detail/mark_unconfirmed_test.py:23:0: C0411: third party import "from handlers.testcase_detail import mark_unconfirmed" should be placed before "from clusterfuzz._internal.datastore import data_types" (wrong-import-order)
| src/clusterfuzz/_internal/tests/appengine/handlers/testcase_detail/mark_unconfirmed_test.py:24:0: C0411: third party import "from libs import form" should be placed before "from clusterfuzz._internal.datastore import data_types" (wrong-import-order)
| ************* Module src.clusterfuzz._internal.tests.appengine.handlers.testcase_detail.delete_test
| src/clusterfuzz/_internal/tests/appengine/handlers/testcase_detail/delete_test.py:23:0: C0411: third party import "from handlers.testcase_detail import delete" should be placed before "from clusterfuzz._internal.datastore import data_types" (wrong-import-order)
| src/clusterfuzz/_internal/tests/appengine/handlers/testcase_detail/delete_test.py:24:0: C0411: third party import "from libs import form" should be placed before "from clusterfuzz._internal.datastore import data_types" (wrong-import-order)
| ************* Module src.clusterfuzz._internal.tests.appengine.handlers.testcase_detail.mark_security_test
| src/clusterfuzz/_internal/tests/appengine/handlers/testcase_detail/mark_security_test.py:23:0: C0411: third party import "from handlers.testcase_detail import mark_security" should be placed before "from clusterfuzz._internal.datastore import data_types" (wrong-import-order)
| src/clusterfuzz/_internal/tests/appengine/handlers/testcase_detail/mark_security_test.py:24:0: C0411: third party import "from libs import form" should be placed before "from clusterfuzz._internal.datastore import data_types" (wrong-import-order)
| ************* Module src.clusterfuzz._internal.tests.appengine.handlers.testcase_detail.download_testcase_test
| src/clusterfuzz/_internal/tests/appengine/handlers/testcase_detail/download_testcase_test.py:24:0: C0411: third party import "from handlers.testcase_detail import download_testcase" should be placed before "from clusterfuzz._internal.datastore import data_types" (wrong-import-order)
| src/clusterfuzz/_internal/tests/appengine/handlers/testcase_detail/download_testcase_test.py:25:0: C0411: third party import "from libs import helpers" should be placed before "from clusterfuzz._internal.datastore import data_types" (wrong-import-order)
| ************* Module src.clusterfuzz._internal.tests.appengine.handlers.testcase_detail.show_test
| src/clusterfuzz/_internal/tests/appengine/handlers/testcase_detail/show_test.py:24:0: C0411: third party import "from handlers.testcase_detail import show" should be placed before "from clusterfuzz._internal.datastore import data_types" (wrong-import-order)
| src/clusterfuzz/_internal/tests/appengine/handlers/testcase_detail/show_test.py:25:0: C0411: third party import "from libs import helpers" should be placed before "from clusterfuzz._internal.datastore import data_types" (wrong-import-order)
| ************* Module src.clusterfuzz._internal.tests.appengine.handlers.testcase_detail.mark_fixed_test
| src/clusterfuzz/_internal/tests/appengine/handlers/testcase_detail/mark_fixed_test.py:23:0: C0411: third party import "from handlers.testcase_detail import mark_fixed" should be placed before "from clusterfuzz._internal.datastore import data_types" (wrong-import-order)
| src/clusterfuzz/_internal/tests/appengine/handlers/testcase_detail/mark_fixed_test.py:24:0: C0411: third party import "from libs import form" should be placed before "from clusterfuzz._internal.datastore import data_types" (wrong-import-order)
| ************* Module src.clusterfuzz._internal.tests.appengine.handlers.testcase_detail.create_issue_test
| src/clusterfuzz/_internal/tests/appengine/handlers/testcase_detail/create_issue_test.py:24:0: C0411: third party import "from handlers.testcase_detail import create_issue" should be placed before "from clusterfuzz._internal.datastore import data_types" (wrong-import-order)
| src/clusterfuzz/_internal/tests/appengine/handlers/testcase_detail/create_issue_test.py:25:0: C0411: third party import "from libs import form" should be placed before "from clusterfuzz._internal.datastore import data_types" (wrong-import-order)
| ************* Module src.clusterfuzz._internal.tests.appengine.handlers.testcase_detail.update_from_trunk_test
| src/clusterfuzz/_internal/tests/appengine/handlers/testcase_detail/update_from_trunk_test.py:23:0: C0411: third party import "from handlers.testcase_detail import update_from_trunk" should be placed before "from clusterfuzz._internal.datastore import data_types" (wrong-import-order)
| src/clusterfuzz/_internal/tests/appengine/handlers/testcase_detail/update_from_trunk_test.py:24:0: C0411: third party import "from libs import form" should be placed before "from clusterfuzz._internal.datastore import data_types" (wrong-import-order)
| ************* Module src.clusterfuzz._internal.tests.appengine.handlers.testcase_detail.remove_group_test
| src/clusterfuzz/_internal/tests/appengine/handlers/testcase_detail/remove_group_test.py:23:0: C0411: third party import "from handlers.testcase_detail import remove_group" should be placed before "from clusterfuzz._internal.datastore import data_types" (wrong-import-order)
| src/clusterfuzz/_internal/tests/appengine/handlers/testcase_detail/remove_group_test.py:24:0: C0411: third party import "from libs import form" should be placed before "from clusterfuzz._internal.datastore import data_types" (wrong-import-order)
| Return code is non-zero (16).
Running: yapf -p -d src/clusterfuzz/_internal/bot/tasks/setup.py src/clusterfuzz/_internal/bot/tasks/utasks/__init__.py src/clusterfuzz/_internal/bot/tasks/utasks/fuzz_task.py src/clusterfuzz/_internal/google_cloud_utils/storage.py src/clusterfuzz/stacktraces/__init__.py src/clusterfuzz/_internal/tests/core/bot/tasks/utasks/fuzz_task_test.py src/clusterfuzz/_internal/tests/core/bot/tasks/utasks/uworker_io_test.py src/clusterfuzz/_internal/tests/core/metrics/fuzzer_stats_test.py
Running: isort --dont-order-by-type --force-single-line-imports --force-sort-within-sections --line-length=80 -p handlers -p libs -p clusterfuzz  -c src/clusterfuzz/_internal/bot/tasks/setup.py src/clusterfuzz/_internal/bot/tasks/utasks/__init__.py src/clusterfuzz/_internal/bot/tasks/utasks/fuzz_task.py src/clusterfuzz/_internal/google_cloud_utils/storage.py src/clusterfuzz/stacktraces/__init__.py src/clusterfuzz/_internal/tests/core/bot/tasks/utasks/fuzz_task_test.py src/clusterfuzz/_internal/tests/core/bot/tasks/utasks/uworker_io_test.py src/clusterfuzz/_internal/tests/core/metrics/fuzzer_stats_test.py