【问题标题】:pubpspect get failed when adding flutter_html lib in flutter在flutter中添加flutter_html lib时,pubpspect失败
【发布时间】:2022-01-01 00:36:32
【问题描述】:

我已尝试构建应用程序 'flutter_html: ^2.1.5" 但我无法构建并在日志中出现以下错误。

 The current Flutter SDK version is 1.27.0-2.0.pre.1.

Because flutter_app depends on flutter_html >=2.1.0 which requires Flutter SDK version >=2.2.0, version solving failed.
pub get failed (1; Because flutter_app depends on flutter_html >=2.1.0 which requires Flutter SDK version >=2.2.0, version solving failed.)

你能建议解决这个问题的方法吗?


我已经升级了颤振版本并迁移并遇到了不同的问题。

FAILURE: Build failed with an exception.

* What went wrong:
A problem was found with the configuration of task ':app:checkDebugManifest' (type 'CheckManifest').
  - In plugin 'com.android.build.gradle.api.AndroidBasePlugin' type 'com.android.build.gradle.internal.tasks.CheckManifest' property 'manifest' has @Input annotation used on property of type 'File'.

    Reason: A property of type 'File' annotated with @Input cannot determine how to interpret the file.

    Possible solutions:
      1. Annotate with @InputFile for regular files.
      2. Annotate with @InputDirectory for directories.
      3. If you want to track the path, return File.absolutePath as a String and keep @Input.

    Please refer to https://docs.gradle.org/7.2/userguide/validation_problems.html#incorrect_use_of_input_annotation for more details about this problem.

* 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 11s
Exception: Gradle task assembleDebug failed with exit code 1

【问题讨论】:

  • 您可以尝试不使用版本flutter_html:flutter_html: ^1.3.0
  • 您可以在问题中使用颤振医生进行编辑吗?
  • @GHPrakash 我更新了问题

标签: flutter flutter-html


【解决方案1】:

您需要升级您的 Flutter SDK。在终端写flutter upgrade

或者使用旧版本的flutter_html

【讨论】:

  • 你能检查我的问题吗,我已经更新了
  • 这是 gradle 错误。我不太了解。我建议将此标记为已回答并使用 gradle 标签创建一个新问题。
猜你喜欢
  • 2021-07-08
  • 2021-06-16
  • 2020-05-26
  • 2022-10-07
  • 1970-01-01
  • 2020-01-30
  • 1970-01-01
  • 1970-01-01
  • 2020-10-23
相关资源
最近更新 更多