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

Project with path ':flipper-no-op' could not be found in project ':flutter_flipperkit'. #4

Closed
TshineZheng opened this issue Mar 31, 2019 · 3 comments

Comments

@TshineZheng
Copy link
Contributor

TshineZheng commented Mar 31, 2019

.
.
.
FAILURE: Build failed with an exception.

* Where:
Build file '/*/flutter/.pub-cache/git/flutter_flipperkit-e4a5fa46a5374dfea85b6321c915841f3dac183b/android/build.gradle' line: 35

* What went wrong:
A problem occurred evaluating project ':flutter_flipperkit'.
> Project with path ':flipper-no-op' could not be found in project ':flutter_flipperkit'.

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

* Get more help at https://help.gradle.org

BUILD FAILED in 0s
,

昨天更新了下 flutter idea 插件,之后就一直运行不了。
试过删除 build、flutter clean、git 引用、更新此库版本,都是这个错误。
删除此库引用正常。

@lijy91
Copy link
Member

lijy91 commented Mar 31, 2019

更新 flutter_flipperkit 到 0.0.9 后需要在你项目的 android/settings.gradle 增加几行代码(这次变更是为了为了支持 flipper 可以在 release mode 下能正常编译)

android/settings.gradle:

...

plugins.each { name, path ->
    def pluginDirectory = flutterProjectRoot.resolve(path).resolve('android').toFile()
    include ":$name"
    project(":$name").projectDir = pluginDirectory

+    if (name == 'flutter_flipperkit') {
+        include ':flipper-no-op'
+        project(':flipper-no-op').projectDir = new File(pluginDirectory, 'flipper-no-op')
+    }
}

...

给你造成的不便实在抱歉了,后续可以通过 Telegram Group 直接联系我。

@TshineZheng
Copy link
Contributor Author

Wow,试了下可以了,感谢这么快速回复。
另外,这个错误好像是 0.0.8 就出现了,我是出现错误后升到 0.0.9 的。

@lijy91
Copy link
Member

lijy91 commented Mar 31, 2019

可以了解一下语义化版本 https://www.dartlang.org/tools/pub/versioning#semantic-versions,我们实际定义的是 ^0.0.8 ,但当 0.0.9 发布后,你再次 package get 后会下载 0.0.9 版本。这是 ^ 符号的作用。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants