繁体   English   中英

除了一个之外,无法运行任何其他 flutter 应用程序

[英]Can't run any other flutter app except for one

我从 git 克隆了一个新的 flutter 项目

当我尝试运行时出现以下错误

Error: Could not resolve the package 'application_flutter_todo' in 'package:application_flutter_todo/utils/constants/api.dart'.
../../.pub-cache/git/flutter_maximo_api-35d1fef13c59a0e7fb70a20916adf1f9d26eac02/lib/src/maximo_api.dart:5:8: Error: Not found:
'package:application_flutter_todo/utils/constants/api.dart'
import 'package:application_flutter_todo/utils/constants/api.dart';
       ^
Unhandled exception:
FileSystemException(uri=org-dartlang-untranslatable-uri:package%3Aapplication_flutter_todo%2Futils%2Fconstants%2Fapi.dart; message=StandardFileSystem only supports file:* and data:*
URIs)
#0      StandardFileSystem.entityForUri (package:front_end/src/api_prototype/standard_file_system.dart:33:7)
#1      asFileUri (package:vm/kernel_front_end.dart:604:37)
<asynchronous suspension>
#2      writeDepfile (package:vm/kernel_front_end.dart:799:21)
<asynchronous suspension>
#3      FrontendCompiler.compile (package:frontend_server/frontend_server.dart:472:15)
<asynchronous suspension>
#4      _FlutterFrontendCompiler.compile (package:flutter_frontend_server/server.dart:38:22)
#5      starter (package:flutter_frontend_server/server.dart:149:27)
#6      main (file:///b/s/w/ir/cache/builder/src/flutter/flutter_frontend_server/bin/starter.dart:8:30)
#7      _startIsolate.<anonymous closure> (dart:isolate-patch/isolate_patch.dart:305:32)
#8      _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:174:12)

Target kernel_snapshot failed: Exception: Errors during snapshot creation: null
Failed to build bundle.
Failed to package /Users/Mohammad/Gemba/application_traxxion.

无法为设备构建预编译的应用程序。

您的应用程序似乎仍包含默认签名标识符。 尝试在 Xcode 中用您的签名 ID 替换“com.example”:打开 ios/Runner.xcworkspace

请注意,当前项目没有 import 'package:application_flutter_todo' 语句。 该语句属于另一个应用程序,不在我尝试运行的当前项目中。

我试过,1-flutter clean 2-更新 flutter 3- 更新包 4- 清理产品 5- 清理项目 6- 从终端、visual studio 代码、xcode 运行项目,这三个都给出了相同的结果。

以上都没有奏效。

正如错误所暗示的那样,您应该分别更改 Android 和 iOS 的包名称和 BundleId。 你不应该使用默认的。

您可以在此处找到操作方法。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM