From f9e7c8ac4684b44a1f79bda69faf20068d8ee5fd Mon Sep 17 00:00:00 2001 From: Sam Rawlins Date: Thu, 1 Jul 2021 16:22:37 -0700 Subject: [PATCH] Ignore unnecessary_import in legacy analysis options This mirrors the change to analysis_options.yaml in https://github.com/flutter/plugins/commit/642a4831e65190011f18180432cee1f03967b2cf. This change is needed in order to land the new unnecessary_import Hint. There are many violations of this new Hint. If we do not ignore them, the flutter roll breaks. Related to flutter/flutter#74381 --- analysis_options_legacy.yaml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/analysis_options_legacy.yaml b/analysis_options_legacy.yaml index 2b62a6a9e2b9..793640e22d27 100644 --- a/analysis_options_legacy.yaml +++ b/analysis_options_legacy.yaml @@ -7,6 +7,9 @@ analyzer: - '**/*.mocks.dart' # Mockito @GenerateMocks errors: always_require_non_null_named_parameters: false # not needed with nnbd + # TODO(https://github.com/flutter/flutter/issues/74381): + # Clean up existing unnecessary imports, and remove line to ignore. + unnecessary_import: ignore unnecessary_null_comparison: false # Turned as long as nnbd mix-mode is supported. linter: rules: