Commit Graph

41 Commits

Author SHA1 Message Date
Sam Rawlins 7320da0d19 linter: Add a PRESUBMIT check for example/all.yaml
Work towards https://github.com/dart-lang/sdk/issues/53578

Change-Id: Ia07d999abc2fcf4b8195c9f7688799bc099a1d88
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/341385
Reviewed-by: Phil Quitslund <pquitslund@google.com>
Reviewed-by: Alexander Thomas <athom@google.com>
Reviewed-by: Jonas Termansen <sortie@google.com>
Commit-Queue: Samuel Rawlins <srawlins@google.com>
2023-12-15 04:04:28 +00:00
Sam Rawlins a2151474a5 linter: UBCS: require checking the correct 'mounted' property
Fixes https://github.com/dart-lang/linter/issues/4777

Change-Id: I0c50ab1a04b8f9c704a0cf787fcf414688cd61a6
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/330561
Reviewed-by: Phil Quitslund <pquitslund@google.com>
Commit-Queue: Samuel Rawlins <srawlins@google.com>
2023-12-12 01:34:11 +00:00
Sam Rawlins 030fe115e2 linter: Allow dynamic calls on explicit dynamic- or Function-casts
Fixes https://github.com/dart-lang/linter/issues/4806

Change-Id: I6c900f9aa3d7c2cf8dc3547bfe035eab820e750b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/339101
Auto-Submit: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Phil Quitslund <pquitslund@google.com>
Commit-Queue: Phil Quitslund <pquitslund@google.com>
2023-11-30 22:40:18 +00:00
Sam Rawlins dd6c961bf0 Remove all pre-NNBD support in the linter code
In this CL we "remove" 3 linter rules, and any subsequently unused quick fixes:

* `always_require_non_null_named_parameters`
* `avoid_returning_null`
* `avoid_returning_null_for_future`

We also delete any code that branched on pre-NNBD libraries; these are
no longer supported.

Change-Id: I3bad7a44de3563e5737919c878170213ad506b82
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/336244
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Phil Quitslund <pquitslund@google.com>
Commit-Queue: Samuel Rawlins <srawlins@google.com>
2023-11-21 18:55:01 +00:00
pq 07c77f59a2 Final todo updated format fixes
This should tidy up the last ones. 🤞

Sorry for the noise!

Change-Id: I7104fc33282184acb0c843eae6e73f6fcc77d892
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/336723
Commit-Queue: Phil Quitslund <pquitslund@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2023-11-16 20:18:32 +00:00
pq bec6e82853 migration to driver.getAnalysisOptionsForFile (continued)
Change-Id: Ia22286786febe7e915df0d7e7b18b9657fef2b07
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/335063
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Phil Quitslund <pquitslund@google.com>
2023-11-14 22:41:28 +00:00
Parker Lougheed 11762189a1 [linter] Fix avoid_unstable_final_fields release version
Fixes https://github.com/dart-lang/sdk/issues/53852

Change-Id: I957373bfd9f04014a3e307f54b7e3f8e27b88564
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/331340
Auto-Submit: Parker Lougheed <parlough@gmail.com>
Reviewed-by: Phil Quitslund <pquitslund@google.com>
Reviewed-by: Erik Ernst <eernst@google.com>
Commit-Queue: Phil Quitslund <pquitslund@google.com>
2023-11-12 19:18:03 +00:00
Sam Rawlins f2a001d2fd Reland: Improve file structure of linter files.
There is much code in pkg/analyzer/lib/src/lint which is only used by
_tests_ and _tools_ in the linter package. This CL attempts to tidy up
the separation of linter lib code and non-lib code by moving some
files, and moving some source elements, which are only used in tests,
or in tools.

I originally dug into this because I saw `LinterOptions` has a public late field
(dangerous):

`late file_system.ResourceProvider resourceProvider;`

It turns out this field is only initialized in tests and tools, and
then it's read by multiple methods, and it just so happens those
methods are only called during tests or in tools.

Summary of changes:

* Mark LintDriver and DartLinter classes as only used for linter tools
  and tests.
* Remove CamelCaseString class.
* Mark `DartLinter.lintPubspecSource` as `@visibleForTesting`.
* LinterOptions: mark `enabledLints` and `analysisOptions` final, and remove
  `resourceProvider`.
* Remove SourceLinter; it was only used in a few `engine_test.dart` tests in
  linter, but all uses could be replaced with DartLinter.
* Remove linter's `bin/linter.dart`; it is not meant to be used as any sort of
  user entrypoint. The main method is moved to `cli.dart`.
* Move linter's `lib/src/cli.dart` to `tool/cli.dart`.
* analyzer's top-level function `lintFiles`, classes ErrorWatchingSink
  and FileGlobFilter are moved to linter's tool/ directory.
* Delete the engine_test.dart tests which only validate basics of
  linter's old entrypoint.

This reverts commit d1bc88de8f.

Change-Id: I1063aa72c640ad8ab62f76bf89f665cb8b9952dc
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/334645
Reviewed-by: Phil Quitslund <pquitslund@google.com>
Reviewed-by: Samuel Rawlins <srawlins@google.com>
Commit-Queue: Samuel Rawlins <srawlins@google.com>
2023-11-10 21:25:11 +00:00
pq 4dcdfc57d6 enable flutter_style_todos
(The bulk of these fixes where auto-applied by `dart fix`)

Change-Id: I5476294ca63ee6584ee07af1ae448db7ba07760e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/335324
Commit-Queue: Phil Quitslund <pquitslund@google.com>
Reviewed-by: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2023-11-09 22:01:47 +00:00
Oleh Prypin d1bc88de8f Revert "Improve file structure of linter files."
This reverts commit 31eab937f6.

Reason for revert: No way to import "tool/formatter.dart" in g3

Original change's description:
> Improve file structure of linter files.
>
> There is much code in pkg/analyzer/lib/src/lint which is only used by
> _tests_ and _tools_ in the linter package. This CL attempts to tidy up
> the separation of linter lib code and non-lib code by moving some
> files, and moving some source elements, which are only used in tests,
> or in tools.
>
> I originally dug into this because I saw `LinterOptions` has a public late field (dangerous):
>
> `late file_system.ResourceProvider resourceProvider;`
>
> It turns out this field is only initialized in tests and tools, and
> then it's read by multiple methods, and it just so happens those
> methods are only called during tests or in tools.
>
> Summary of changes:
>
> * Mark LintDriver and DartLinter classes as only used for linter tools
>   and tests.
> * Remove CamelCaseString class.
> * Mark `DartLinter.lintPubspecSource` as `@visibleForTesting`.
> * LinterOptions: mark `enabledLints` and `analysisOptions` final, and remove `resourceProvider`.
> * Remove SourceLinter; it was only used in a few `engine_test.dart` tests in linter, but all uses could be replaced with DartLinter.
> * Remove linter's `bin/linter.dart`; it is not meant to be used as any sort of user entrypoint. The main method is moved to `cli.dart`.
> * Move linter's `lib/src/cli.dart` to `tool/cli.dart`.
> * analyzer's top-level function `lintFiles`, classes ErrorWatchingSink
>   and FileGlobFilter are moved to linter's tool/ directory.
> * Delete engine_test.dart tests which only validate basics of
>   linter's old entrypoint.
>
> Change-Id: Ifc0e70454ee2ac794bc816ef9c77d5519a93eb0a
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/333128
> Commit-Queue: Samuel Rawlins <srawlins@google.com>
> Reviewed-by: Phil Quitslund <pquitslund@google.com>

Bug: b/309643288
Change-Id: I69a731ff31507f671277d0395f4ebfbb86d8f607
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/334660
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Commit-Queue: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Commit-Queue: Phil Quitslund <pquitslund@google.com>
Reviewed-by: Phil Quitslund <pquitslund@google.com>
Reviewed-by: Samuel Rawlins <srawlins@google.com>
Auto-Submit: Oleh Prypin <oprypin@google.com>
2023-11-07 19:30:53 +00:00
Sam Rawlins 31eab937f6 Improve file structure of linter files.
There is much code in pkg/analyzer/lib/src/lint which is only used by
_tests_ and _tools_ in the linter package. This CL attempts to tidy up
the separation of linter lib code and non-lib code by moving some
files, and moving some source elements, which are only used in tests,
or in tools.

I originally dug into this because I saw `LinterOptions` has a public late field (dangerous):

`late file_system.ResourceProvider resourceProvider;`

It turns out this field is only initialized in tests and tools, and
then it's read by multiple methods, and it just so happens those
methods are only called during tests or in tools.

Summary of changes:

* Mark LintDriver and DartLinter classes as only used for linter tools
  and tests.
* Remove CamelCaseString class.
* Mark `DartLinter.lintPubspecSource` as `@visibleForTesting`.
* LinterOptions: mark `enabledLints` and `analysisOptions` final, and remove `resourceProvider`.
* Remove SourceLinter; it was only used in a few `engine_test.dart` tests in linter, but all uses could be replaced with DartLinter.
* Remove linter's `bin/linter.dart`; it is not meant to be used as any sort of user entrypoint. The main method is moved to `cli.dart`.
* Move linter's `lib/src/cli.dart` to `tool/cli.dart`.
* analyzer's top-level function `lintFiles`, classes ErrorWatchingSink
  and FileGlobFilter are moved to linter's tool/ directory.
* Delete engine_test.dart tests which only validate basics of
  linter's old entrypoint.

Change-Id: Ifc0e70454ee2ac794bc816ef9c77d5519a93eb0a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/333128
Commit-Queue: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Phil Quitslund <pquitslund@google.com>
2023-11-07 16:47:21 +00:00
Sam Rawlins 5f24a631c7 linter: Add first three 'known limitation' texts to docs
Change-Id: Id6f1c95614e7de039866da40659ab7de7928faee
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/333340
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Phil Quitslund <pquitslund@google.com>
Commit-Queue: Samuel Rawlins <srawlins@google.com>
2023-11-02 16:22:01 +00:00
pq d239b906e9 rule generation codegen tweaks
* removes stale generated TODO
* fixes test prefixing in the all tests test for cases where tests include `_test`
* adds a file ignore for test prefixes for the all tests test

Change-Id: Ie400e275300683b8f037bb6dae62aa85a3469cff
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/331201
Commit-Queue: Phil Quitslund <pquitslund@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2023-10-19 16:42:25 +00:00
pq d79fd1a269 remove inTestMode declaration
Change-Id: I7fa08195db75120df4377c7529d52ba47ff3dcbb
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/331090
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Phil Quitslund <pquitslund@google.com>
Reviewed-by: Samuel Rawlins <srawlins@google.com>
2023-10-19 14:48:13 +00:00
pq a6674f7b7c remove stale test mode codegen support
Change-Id: Ie3d103404e64139caa9eb2f15a4688fc94ab8e49
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/331085
Commit-Queue: Phil Quitslund <pquitslund@google.com>
Reviewed-by: Samuel Rawlins <srawlins@google.com>
2023-10-18 17:43:05 +00:00
pq 9266dd12ed add an "internal" rule state
Change-Id: I740d95c179005b820dab01b4cd0cd7b0976f288b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/331080
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Phil Quitslund <pquitslund@google.com>
2023-10-18 16:27:22 +00:00
Sam Rawlins 7341ad214e Document unreachable_from_main for instance members
Change-Id: I37ea317ad0e1fc18d509e706a3cbc355f04005be
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/330380
Auto-Submit: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Phil Quitslund <pquitslund@google.com>
Commit-Queue: Phil Quitslund <pquitslund@google.com>
2023-10-13 03:39:23 +00:00
Erik Ernst cdc16e7d3d Create lint PR 3578 as Gerrit CL
This CL transfers the changes made by
https://github.com/dart-lang/linter/pull/3578
to Gerrit.

Change-Id: Ib1eae56d2112e25bcf9916abf27b05bd3de15735
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/326342
Commit-Queue: Erik Ernst <eernst@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2023-10-12 10:09:10 +00:00
Parker Lougheed fd59a1c33f [linter] Reduce cases where dynamic is inferred
Doesn't enable strict-inference but fixes a few of the more impactful cases.

Change-Id: Ife08f1839036c420108bf603f4bce3ab7bfea5c4
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/330000
Commit-Queue: Phil Quitslund <pquitslund@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Phil Quitslund <pquitslund@google.com>
2023-10-10 18:07:59 +00:00
Brian Wilkerson 41446971a6 Attempt to fix the pkg bots
Change-Id: I95768d444547f2ec3ae97870dfaaa0f441c63a87
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/328660
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Phil Quitslund <pquitslund@google.com>
2023-09-28 19:35:28 +00:00
pq beeda0df80 unregister "check" tests after running
The side effect of these checks persisting in the registry were causing downstream verifications to fail.

See: https://github.com/dart-lang/linter/issues/4754

Change-Id: I3128be284599fc160f14df0c832cace5f6e98d6d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/328101
Reviewed-by: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Phil Quitslund <pquitslund@google.com>
2023-09-28 00:39:49 +00:00
Sam Rawlins c36afc2f52 Update unnecessary_this examples
I found this a little jarring; code is not idiomatic.

* field is implicit `dynamic`.
* parameter is implicit `dynamic`.
* parameter name is snake_case.

Change-Id: I49c42e5c2ea1e18bec280b2b7e04d0b4da737dcc
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/327803
Reviewed-by: Phil Quitslund <pquitslund@google.com>
Commit-Queue: Phil Quitslund <pquitslund@google.com>
Auto-Submit: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Samuel Rawlins <srawlins@google.com>
2023-09-26 15:49:23 +00:00
pq bf26e5985a update w/ latest package:lints lint sets
Fixes failure here: https://dart-ci.appspot.com/log/any/unittest-asserts-release-linux/24229/pkg/linter/test/verify_machine_json_test

Change-Id: Ifda4654e1a80a0003bada8b33e9ebd5878173421
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/327023
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Devon Carew <devoncarew@google.com>
Commit-Queue: Phil Quitslund <pquitslund@google.com>
2023-09-20 21:04:07 +00:00
pq 88b07ba64e annotate_redeclares since info
Change-Id: I7bae3816d72b64f3cb3a4520c90491aefa5d6437
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/326901
Commit-Queue: Phil Quitslund <pquitslund@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2023-09-19 21:57:39 +00:00
pq d1b6ea9f4d +annotate_redeclares
Fixes: https://github.com/dart-lang/linter/issues/4747

Change-Id: I7bf3e83dbe279f5b1a03dc5e5806c7c0fe3e3486
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/326263
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Phil Quitslund <pquitslund@google.com>
2023-09-18 02:41:29 +00:00
pq 240ef465e6 fix unsafe cast
Change-Id: If2a2f72c62e8bda14c04de88cb37bf416e5b0c86
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/326181
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Phil Quitslund <pquitslund@google.com>
2023-09-14 19:27:58 +00:00
Sam Rawlins 10da52b016 linter: Move sized_box_shrink_expand tests
Change-Id: I8fccc19af7ed2895b710e00feae3145e6ff8e401
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/325480
Commit-Queue: Samuel Rawlins <srawlins@google.com>
Auto-Submit: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Phil Quitslund <pquitslund@google.com>
Reviewed-by: Samuel Rawlins <srawlins@google.com>
2023-09-12 22:16:59 +00:00
Sam Rawlins 45930e3d62 linter: Mark use_build_context_synchronously stable
Fixes https://github.com/dart-lang/linter/issues/3915



Change-Id: I4909b6440859174852f85084fef4c847f0f46a94
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/325365
Reviewed-by: Phil Quitslund <pquitslund@google.com>
Commit-Queue: Samuel Rawlins <srawlins@google.com>
2023-09-12 19:50:09 +00:00
Parker Lougheed f91a4cf1b0 [linter] Link to docs for more context on enhanced enums
Change-Id: Iacfda3ea97bfe7025f0d415f06ef2b342df37dda
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/325180
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2023-09-11 17:52:07 +00:00
Sam Rawlins 4bddf8a25f Revert "Revert "linter: Refactor prefer_collection_literals to use context type more""
This reverts commit cbdae14d2f.

In addition, Fix prefer_collection_literals for methods with expression bodies

Original description:

linter: Refactor prefer_collection_literals to use context type more

There is a basic premise in this rule which we cannot satisfy exactly:
we need to disallow `LinkedHashSet()` unless the context type requires
the developer to use `LinkedHashSet`. But the context type is long
gone when the lint rule is run.

This CL adds some logic to try to attempt figuring out the context
type in the cases where users have filed bugs, but it will never be
super accurate.

Fixes https://github.com/dart-lang/linter/issues/4736
Fixes https://github.com/dart-lang/linter/issues/3057
Fixes https://github.com/dart-lang/linter/issues/1649
Fixes https://github.com/dart-lang/linter/issues/2795

Change-Id: I958ba69a56866c18523ce6cbf62645ef8e028f6b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/324260
Commit-Queue: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2023-09-05 23:49:49 +00:00
Ilya Yanok cbdae14d2f Revert "linter: Refactor prefer_collection_literals to use context type more"
This reverts commit cd8a3370e7.

Reason for revert: lint starts barking at the wrong tree: b/298917960

Original change's description:
> linter: Refactor prefer_collection_literals to use context type more
>
> There is a basic premise in this rule which we cannot satisfy exactly:
> we need to disallow `LinkedHashSet()` unless the context type requires
> the developer to use `LinkedHashSet`. But the context type is long
> gone when the lint rule is run.
>
> This CL adds some logic to try to attempt figuring out the context
> type in the cases where users have filed bugs, but it will never be
> super accurate.
>
> Fixes https://github.com/dart-lang/linter/issues/4736
> Fixes https://github.com/dart-lang/linter/issues/3057
> Fixes https://github.com/dart-lang/linter/issues/1649
> Fixes https://github.com/dart-lang/linter/issues/2795
>
> Change-Id: I3e6c6de81084dca2825488c89830ab3e7ea63186
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/323680
> Reviewed-by: Phil Quitslund <pquitslund@google.com>
> Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
> Commit-Queue: Samuel Rawlins <srawlins@google.com>

Change-Id: I980053dd51ffd4447721e0ad7436b07ca704b554
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/324021
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Reviewed-by: Alexander Thomas <athom@google.com>
Commit-Queue: Ilya Yanok <yanok@google.com>
2023-09-04 10:43:54 +00:00
Sam Rawlins cd8a3370e7 linter: Refactor prefer_collection_literals to use context type more
There is a basic premise in this rule which we cannot satisfy exactly:
we need to disallow `LinkedHashSet()` unless the context type requires
the developer to use `LinkedHashSet`. But the context type is long
gone when the lint rule is run.

This CL adds some logic to try to attempt figuring out the context
type in the cases where users have filed bugs, but it will never be
super accurate.

Fixes https://github.com/dart-lang/linter/issues/4736
Fixes https://github.com/dart-lang/linter/issues/3057
Fixes https://github.com/dart-lang/linter/issues/1649
Fixes https://github.com/dart-lang/linter/issues/2795

Change-Id: I3e6c6de81084dca2825488c89830ab3e7ea63186
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/323680
Reviewed-by: Phil Quitslund <pquitslund@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Samuel Rawlins <srawlins@google.com>
2023-09-01 19:58:29 +00:00
Sam Rawlins d0273dda5f linter: Move no_runtimeType_toString tests
Also re-order the skip checks, to avoid walking up ancestors on
every method call that isn't named 'toString'.

Change-Id: I69e9b58b1ae26d44498381546d5881c7e66d4935
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/323681
Auto-Submit: Samuel Rawlins <srawlins@google.com>
Commit-Queue: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Phil Quitslund <pquitslund@google.com>
2023-09-01 18:51:18 +00:00
pq 349e6266ff verify linter source sorting
Fixes: https://github.com/dart-lang/linter/issues/2368

Change-Id: I498e271dc32348115a34472b44688be8de2169a3
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/323901
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Phil Quitslund <pquitslund@google.com>
2023-09-01 17:40:07 +00:00
Sam Rawlins 899c88c997 [linter] Remove 'run test' from command
`dart run test` seems to automatically run `pub get`, which totally
breaks linter (uses pub to get a copy of analyzer).

Change-Id: I16c6c1488aacf4b4f52b9f9f97bcc3dad7eb7c24
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/323421
Auto-Submit: Samuel Rawlins <srawlins@google.com>
Reviewed-by: Phil Quitslund <pquitslund@google.com>
Commit-Queue: Phil Quitslund <pquitslund@google.com>
2023-08-30 17:11:19 +00:00
Parker Lougheed d3eb747f45 [linter] Remove duplicate sample in implicit_reopen docs
Fixes https://github.com/dart-lang/site-www/issues/5127

Change-Id: Ibd70155a07169de454e00e0bce8700b1ce08b43f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/322480
Reviewed-by: Phil Quitslund <pquitslund@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2023-08-24 04:50:30 +00:00
pq eeb3101b3a stop fetching analysis server sources
Change-Id: I4d07d347567662af508e4af5c8196e64ba865b9a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/322366
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Samuel Rawlins <srawlins@google.com>
Commit-Queue: Phil Quitslund <pquitslund@google.com>
2023-08-23 21:59:53 +00:00
pq 4e634268c3 remove stale github action/bot hooks
Change-Id: I9d12f2e3a012a12676c9e2d889b7b940cd8117a7
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/322445
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Phil Quitslund <pquitslund@google.com>
2023-08-23 20:52:20 +00:00
Parker Lougheed 9e761d5a10 [linter] Account for new lints in 3.1.0 release
Bug: https://github.com/dart-lang/linter/pull/4678#issuecomment-1685125753
Change-Id: I8fe1bcea8cc0db26b1375cb95ebe6ec51b6b63ec
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/322380
Auto-Submit: Parker Lougheed <parlough@gmail.com>
Reviewed-by: Phil Quitslund <pquitslund@google.com>
Commit-Queue: Phil Quitslund <pquitslund@google.com>
2023-08-23 20:36:05 +00:00
pq 76e4e80ceb fix failing migrated linter unit tests
Fixes: https://github.com/dart-lang/sdk/issues/53323

Change-Id: If826bd3e1a6df04cc851b4629c5c58087d867fea
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/322444
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Phil Quitslund <pquitslund@google.com>
2023-08-23 20:30:28 +00:00
William Hesse 86c86d638a Add linter repository to sdk, preserving its commit history
Added using git-subtree command git subtree add -P pkg/linter linter/main

Bug: https://github.com/dart-lang/linter/issues/4411
2023-08-23 14:05:34 +02:00