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

Flutter should document exactly pinning framework dependencies #104181

Open
mgenware opened this issue May 19, 2022 · 4 comments
Open

Flutter should document exactly pinning framework dependencies #104181

mgenware opened this issue May 19, 2022 · 4 comments
Labels
d: api docs Issues with https://api.flutter.dev/ P2 Important issues not at the top of the work list team-tool Owned by Flutter Tool team triaged-tool Triaged by Flutter Tool team

Comments

@mgenware
Copy link

Steps to Reproduce

Have both path 1.8.2 and flutter_test in deps.

dependencies:
  flutter:
    sdk: flutter
  flutter_localizations:
    sdk: flutter
  path: ^1.8.2

dev_dependencies:
  flutter_test:
    sdk: flutter

flutter pub get prints:

Because every version of flutter_test from sdk depends on path 1.8.1 and <app> depends on path >=1.8.2, flutter_test from sdk is forbidden
Logs
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, 3.0.0, on macOS 12.3.1 21E258 darwin-arm, locale
    en-CN)
[✗] 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/docs/get-started/install/macos#android-setup
      for detailed instructions).
      If the Android SDK has been installed to a custom location, please use
      `flutter config --android-sdk` to update to that location.

[✓] Xcode - develop for iOS and macOS (Xcode 13.3.1)
[✓] Chrome - develop for the web
[!] Android Studio (not installed)
[✓] VS Code (version 1.67.1)
[✓] Connected device (2 available)
[✓] HTTP Host Availability
@maheshmnj maheshmnj added the in triage Presently being triaged by the triage team label May 19, 2022
@maheshmnj
Copy link
Member

maheshmnj commented May 19, 2022

Hi @mgenware, Thanks for filing the issue. I am able to reproduce the issue on stable and master channel. Path and flutter_test do not play well together

[newapp] flutter pub get
Running "flutter pub get" in newapp...                          
Because every version of flutter_test from sdk depends on path 1.8.1 and newapp depends on path ^1.8.2, flutter_test from sdk is forbidden.
So, because newapp depends on flutter_test from sdk, version solving failed.
pub get failed (1; So, because newapp depends on flutter_test from sdk, version solving failed.)
exit code 1

To fix this issue Path must be upgraded to 1.8.2 in flutter_test

flutter doctor -v (mac)
[✓] Flutter (Channel stable, 3.0.0, on macOS 12.3 21E230 darwin-arm, locale en-IN)
    • Flutter version 3.0.0 at /Users/mahesh/Documents/flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision ee4e09cce0 (6 days ago), 2022-05-09 16:45:18 -0700
    • Engine revision d1b9a6938a
    • Dart version 2.17.0
    • DevTools version 2.12.2

[✓] Android toolchain - develop for Android devices (Android SDK version 31.0.0)
    • Android SDK at /Users/mahesh/Library/Android/sdk
    • Platform android-32, build-tools 31.0.0
    • ANDROID_HOME = /Users/mahesh/Library/Android/sdk
    • Java binary at: /Applications/Android Studio.app/Contents/jre/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 11.0.11+0-b60-7772763)
    • All Android licenses accepted.

[!] Xcode - develop for iOS and macOS (Xcode 13.2.1)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    ! CocoaPods 1.10.2 out of date (1.11.0 is recommended).
        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 upgrade see https://guides.cocoapods.org/using/getting-started.html#installation for instructions.

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 2021.1)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 11.0.11+0-b60-7772763)

[✓] IntelliJ IDEA Community Edition (version 2021.2.1)
    • IntelliJ at /Applications/IntelliJ IDEA CE.app
    • Flutter plugin version 61.2.4
    • Dart plugin version 212.5080.8

[✓] VS Code (version 1.66.2)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.40.0

[✓] Connected device (2 available)
    • macOS (desktop) • macos  • darwin-arm64   • macOS 12.3 21E230 darwin-arm
    • Chrome (web)    • chrome • web-javascript • Google Chrome 101.0.4951.64

[✓] HTTP Host Availability
    • All required HTTP hosts are available

! Doctor found issues in 1 category.
    • Flutter version 3.1.0-0.0.pre.419 at /Users/mahesh/Documents/flutter_master
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 2eed8cbf93 (2 weeks ago), 2022-04-28 22:29:06 -0400
    • Engine revision dfdfe0b3b0
    • Dart version 2.18.0 (build 2.18.0-66.0.dev)
    • DevTools version 2.12.2

[✓] Android toolchain - develop for Android devices (Android SDK version 31.0.0)
    • Android SDK at /Users/mahesh/Library/Android/sdk
    • Platform android-32, build-tools 31.0.0
    • ANDROID_HOME = /Users/mahesh/Library/Android/sdk
    • Java binary at: /Applications/Android Studio.app/Contents/jre/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 11.0.11+0-b60-7772763)
    • All Android licenses accepted.

[!] Xcode - develop for iOS and macOS (Xcode 13.2.1)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    ! CocoaPods 1.10.2 out of date (1.11.0 is recommended).
        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 upgrade see https://guides.cocoapods.org/using/getting-started.html#installation for instructions.

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 2021.1)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 11.0.11+0-b60-7772763)

[✓] IntelliJ IDEA Community Edition (version 2021.2.1)
    • IntelliJ at /Applications/IntelliJ IDEA CE.app
    • Flutter plugin version 61.2.4
    • Dart plugin version 212.5080.8

[✓] VS Code (version 1.66.2)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.40.0

[✓] Connected device (2 available)
    • macOS (desktop) • macos  • darwin-arm64   • macOS 12.3 21E230 darwin-arm
    • Chrome (web)    • chrome • web-javascript • Google Chrome 101.0.4951.64

[✓] HTTP Host Availability
    • All required HTTP hosts are available

! Doctor found issues in 1 category.

@maheshmnj maheshmnj added tool Affects the "flutter" command-line tool. See also t: labels. has reproducible steps The issue has been confirmed reproducible and is ready to work on found in release: 3.0 Found to occur in 3.0 found in release: 3.1 Found to occur in 3.1 and removed in triage Presently being triaged by the triage team labels May 19, 2022
@maheshmnj maheshmnj changed the title flutter_test keeps me from installing path 1.8.2 [flutter 3] flutter_test and path 1.8.2 do not play well together May 19, 2022
@maheshmnj maheshmnj changed the title [flutter 3] flutter_test and path 1.8.2 do not play well together [flutter 3] flutter_test and path 1.8.2 version conflict May 19, 2022
@christopherfujino
Copy link
Member

@mgenware so this is working as intended. In the flutter SDK repository, all packages are pinned exactly, so that we can ensure that all customers using a particular version of Flutter use the exact same code that has been tested.

package:flutter_test pins package:path here at 1.8.1.

However, we never document this, so I will leave this issue open to track that.

@christopherfujino christopherfujino changed the title [flutter 3] flutter_test and path 1.8.2 version conflict Flutter should document exactly pinning framework dependencies May 24, 2022
@christopherfujino christopherfujino added documentation P2 Important issues not at the top of the work list and removed tool Affects the "flutter" command-line tool. See also t: labels. has reproducible steps The issue has been confirmed reproducible and is ready to work on found in release: 3.0 Found to occur in 3.0 found in release: 3.1 Found to occur in 3.1 labels May 24, 2022
@flutter-triage-bot flutter-triage-bot bot added the d: api docs Issues with https://api.flutter.dev/ label Jul 5, 2023
@huycozy
Copy link
Member

huycozy commented Sep 19, 2023

I'm not sure if this issue should belong to tool team again or another team

@huycozy huycozy added the will need additional triage This issue or PR needs attention during weekly triage label Sep 19, 2023
@christopherfujino
Copy link
Member

I'm not sure if this issue should belong to tool team again or another team

fair, i'm not sure either, but i'll just put this on team-tool.

@christopherfujino christopherfujino added team-tool Owned by Flutter Tool team triaged-tool Triaged by Flutter Tool team and removed will need additional triage This issue or PR needs attention during weekly triage labels Sep 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
d: api docs Issues with https://api.flutter.dev/ P2 Important issues not at the top of the work list team-tool Owned by Flutter Tool team triaged-tool Triaged by Flutter Tool team
Projects
None yet
Development

No branches or pull requests

5 participants