dart-sdk/pkg/analyzer/analysis_options.yaml
Paul Berry 5d7dd58d41 Ignore TODO in pkg/analyzer and pkg/analysis_server.
The analyzer team has decided to adopt the convention of using `TODO`
comments to document long term issues that should persist in the
codebase, and `FIXME` comments to document short term issues that need
immediate attention.  They may even consider adding a presubmit hook
to ensure that `FIXME` comments are only used during local
development.

Accordingly, it makes sense to suppress `TODO` comments from being
surfaced to the IDE "problems" view (since there are hundreds of them,
and they're not immediately actionable).  This makes VSCode's
"problems" view much more usable in "tree" mode.

Change-Id: I11a0c59132fb98c1c86fb4adf22d1fdf3b547c80
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/295662
Commit-Queue: Paul Berry <paulberry@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2023-04-21 19:16:04 +00:00

52 lines
1.8 KiB
YAML

include: package:lints/recommended.yaml
analyzer:
errors:
# Increase the severity of the unused_import hint.
unused_import: warning
# "strict-inference" is enabled, but "unused" parameters named '_' are
# still reported. Re-evaluate after
# https://github.com/dart-lang/language/pull/599 and a functional fix land.
inference_failure_on_untyped_parameter: ignore
# There are about 10k violations in test/ due to missing return types on
# test methods. It would be nice to mark this code as
# "ignored for test/**/*.dart".
inference_failure_on_function_return_type: ignore
# Lints from the recommended set that conflict w/ analyzer style or will
# require some work to reach compliance.
# See: https://github.com/dart-lang/sdk/issues/48784
avoid_renaming_method_parameters: ignore
# We sometimes name test classes with an underscore, and have a consistent
# practice of doing so. We do not have an problems of naming classes with
# snake_case, so we're not missing much by disabling it. Re-enable when we
# can ignore a lint rule for a certain path.
camel_case_types: ignore
constant_identifier_names: ignore
hash_and_equals: ignore
non_constant_identifier_names: ignore
implementation_imports: ignore
library_private_types_in_public_api: ignore
provide_deprecation_message: ignore
todo: ignore
language:
strict-casts: true
strict-inference: true
linter:
rules:
- always_use_package_imports
- avoid_dynamic_calls
- avoid_unused_constructor_parameters
- collection_methods_unrelated_type
- dangling_library_doc_comments
- enable_null_safety
- implicit_call_tearoffs
- library_annotations
- unawaited_futures
- unnecessary_library_directive
- unnecessary_parenthesis
- use_super_parameters