Skip to content

The codegen integration test should not be analyzed #52823

Closed

Description

@srawlins

Steps to Reproduce

  1. Remove the // ignore: uri_does_not_exist directive from dev/integration_tests/codegen/lib/main.dart.
  2. Dart SDK and Flutter CI tries to analyze dev/integration_tests/codegen/lib/main.dart. Manually, you can execute ./bin/flutter analyze dev
  3. The analyzer reports an error.

Logs

$ ./bin/flutter analyze dev
Analyzing 2 directories...                                      

  error • Target of URI doesn't exist: 'message.dart' • dev/integration_tests/codegen/lib/main.dart:7:8 • uri_does_not_exist
$ ./bin/flutter doctor -v
Downloading android-arm-profile/darwin-x64 tools...                 1.0s
Downloading android-arm-release/darwin-x64 tools...                 0.7s
Downloading android-arm64-profile/darwin-x64 tools...               0.8s
Downloading android-arm64-release/darwin-x64 tools...               1.0s
Downloading android-x64-profile/darwin-x64 tools...                 0.8s
Downloading android-x64-release/darwin-x64 tools...                 0.8s
[✓] Flutter (Channel master, v1.15.23-pre.29, on Mac OS X 10.15.3 19D76, locale en-US)
    • Flutter version 1.15.23-pre.29 at /Users/srawlins/code/flutter
    • Framework revision a811bce4b0 (49 minutes ago), 2020-03-18 08:02:22 -0700
    • Engine revision 3a2cc95533
    • Dart version 2.8.0 (build 2.8.0-dev.15.0 9dfd0127da)

[✗] Android toolchain - develop for Android devices
    ✗ Unable to locate Android SDK.
      Install Android Studio from: https://developer.android.com/studio/index.html
      On first launch it will assist you in installing the Android SDK components.
      (or visit https://flutter.dev/setup/#android-setup for detailed instructions).
      If the Android SDK has been installed to a custom location, set ANDROID_SDK_ROOT to that location.
      You may also want to add it to your PATH environment variable.


[!] Xcode - develop for iOS and macOS (Xcode 10.2.1)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Xcode 10.2.1, Build version 10E1001
    ✗ Flutter requires a minimum Xcode version of 11.0.0.
      Download the latest version or update via the Mac App Store.
    ✗ CocoaPods not installed.
        CocoaPods is used to retrieve the iOS and macOS platform side's plugin code that responds to your plugin usage on the Dart side.
        Without CocoaPods, plugins will not work on iOS or macOS.
        For more info, see https://flutter.dev/platform-plugins
      To install:
        sudo gem install cocoapods

[!] Android Studio (not installed)
    • Android Studio not found; download from https://developer.android.com/studio/index.html
      (or visit https://flutter.dev/setup/#android-setup for detailed instructions).

[!] IntelliJ IDEA Community Edition (version 2019.2.4)
    • IntelliJ at /Applications/IntelliJ IDEA CE.app
    ✗ Flutter plugin not installed; this adds Flutter specific functionality.
    • Dart plugin version 192.7359
    • For information about installing plugins, see
      https://flutter.dev/intellij-setup/#installing-the-plugins

[!] Connected device
    ! No devices available

! Doctor found issues in 5 categories.

Since this file is not functional until code generation has executed, it should be excluded from static analysis, unless there is a better way to prevent the error from affecting Dart SDK CI and Flutter CI.

Activity

  1. jonahwilliams commented on Mar 18, 2020

    @jonahwilliams
    Contributor

    We could just add an ignore section to the analysis options.yaml for that project right @srawlins ?

  2. srawlins commented on Mar 18, 2020

    @srawlins
    ContributorAuthor

    I've got a PR in the works just like that. I hadn't seen the nested analysis options files at first.

  3. lock commented on Apr 2, 2020

    @lock

    This thread has been automatically locked since there has not been any recent activity after it was closed. If you are still experiencing a similar issue, please open a new bug, including the output of flutter doctor -v and a minimal reproduction of the issue.

  4. locked and limited conversation to collaborators on Apr 2, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    c: contributor-productivityTeam-specific productivity, code health, technical debt.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions