Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failures on Expose CommentToken as analyzer public API...[analyzer] Prioritize errors in analysis_options/pubspec errors when running "dart analyze" #56059

Closed
aam opened this issue Jun 20, 2024 · 1 comment
Assignees
Labels
area-analyzer Use area-analyzer for Dart analyzer issues, including the analysis server and code completion. gardening

Comments

@aam
Copy link
Contributor

aam commented Jun 20, 2024

There are new test failures on Expose CommentToken as analyzer public API...[analyzer] Prioritize errors in analysis_options/pubspec errors when running "dart analyze".

The tests

pkg/dartdev/test/commands/analyze_test RuntimeError (expected Pass)

are failing on configurations

unittest-asserts-release-win-arm64

For example, https://ci.chromium.org/ui/p/dart/builders/ci.sandbox/pkg-win-release-arm64/1860/overview

00:11 �[32m+35�[0m�[33m ~1�[0m�[31m -1�[0m: analyze display mode default does not prioritize warnings in analysis_options.yaml �[1m�[31m[E]�[0m�[0m

  Expected: 'Analyzing myapp...\n'
              '\n'
              '  error - lib\\main.dart:1:16 - A value of type \'Null\' can\'t be returned from the function \'foo\' because it has a return type of \'int\'. - return_of_invalid_type\n'
              'warning - analysis_options.yaml:1:10 - The include file \'package:lints/recommended.yaml\' in \'c:\\opt\\s\\w\\ir\\x\\t\\dartdev7ceedc5f\\myapp\\analysis_options.yaml\' can\'t be found when analyzing \'c:\\opt\\s\\w\\ir\\x\\t\\dartdev7ceedc5f\\myapp\'. - include_file_not_found\n'
              '\n'
              '2 issues found.'
    Actual: 'Analyzing myapp...\n'
              '\n'
              '  error - lib\\main.dart:1:16 - A value of type \'Null\' can\'t be returned from the function \'foo\' because it has a return type of \'int\'. - return_of_invalid_type\n'
              'warning - analysis_options.yaml:1:10 - The include file \'package:lints/recommended.yaml\' in \'C:\\opt\\s\\w\\ir\\x\\t\\dartdev7ceedc5f\\myapp\\analysis_options.yaml\' can\'t be found when analyzing \'C:\\opt\\s\\w\\ir\\x\\t\\dartdev7ceedc5f\\myapp\'. - include_file_not_found\n'
              '\n'
              '2 issues found.'
     Which: is different.
            Expected: ... yaml' in 'c:\\opt\\s ...
              Actual: ... yaml' in 'C:\\opt\\s ...
                                    ^
             Differ at offset 277
  

  package:matcher/src/expect/expect.dart 149:31      fail
  package:matcher/src/expect/expect.dart 144:3       _expect
  package:matcher/src/expect/expect.dart 56:3        expect
  pkg\dartdev\test\commands\analyze_test.dart 664:9  defineAnalyze.<fn>.<fn>.<fn>
  ===== asynchronous gap ===========================
  package:test_api/src/backend/declarer.dart 215:9   Declarer.test.<fn>.<fn>
  ===== asynchronous gap ===========================
  package:test_api/src/backend/declarer.dart 213:7   Declarer.test.<fn>
  ===== asynchronous gap ===========================
  package:test_api/src/backend/invoker.dart 258:9    Invoker._waitForOutstandingCallbacks.<fn>
  

cc @DanTup

@aam aam added area-vm Use area-vm for VM related issues, including code coverage, and the AOT and JIT backends. gardening labels Jun 20, 2024
@DanTup
Copy link
Collaborator

DanTup commented Jun 20, 2024

Thanks - I noticed this the other day and opened https://dart-review.googlesource.com/c/sdk/+/372300 which should fix it.

@DanTup DanTup self-assigned this Jun 20, 2024
@bwilkerson bwilkerson added area-analyzer Use area-analyzer for Dart analyzer issues, including the analysis server and code completion. and removed area-vm Use area-vm for VM related issues, including code coverage, and the AOT and JIT backends. labels Jun 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-analyzer Use area-analyzer for Dart analyzer issues, including the analysis server and code completion. gardening
Projects
None yet
Development

No branches or pull requests

3 participants