新的Flutter应用程序构建失败,导致模拟器失败,权限被拒绝

时间:2020-09-07 16:39:30

标签: ios xcode flutter

当我尝试def input_handler(data, context): d = data.read().decode('utf-8') body = json.loads(d) s3path = body['s3_path'] s3 = S3FileSystem() df = np.load(s3.open(s3path)) return df 一个新创建的flutter应用程序时,构建失败,并出现以下错误。该计算机是在一年前用于Flutter开发的,我怀疑某个地方的某些不规则配置会导致此错误。我已经为此苦苦挣扎了几天,任何帮助将不胜感激。

复制步骤

  1. ERROR:python_service:exception handling request: The truth value of an array with more than one element is ambiguous. Use a.any() or a.all( Traceback (most recent call last): File "/sagemaker/python_service.py", line 289, in _handle_invocation_post res.body, res.content_type = self._handlers(data, context) File "/sagemaker/python_service.py", line 322, in handler response = requests.post(context.rest_uri, data=processed_input) File "/usr/local/lib/python3.6/dist-packages/requests/api.py", line 116, in post return request('post', url, data=data, json=json, **kwargs) File "/usr/local/lib/python3.6/dist-packages/requests/api.py", line 60, in request return session.request(method=method, url=url, **kwargs) File "/usr/local/lib/python3.6/dist-packages/requests/sessions.py", line 512, in request data=data or {} ,
  2. flutter run
  3. flutter create my_app

终端输出:

cd my_app

我已经尝试过:

  • 卸载并重新安装Xcode
  • 卸载并重新安装Flutter
  • 从Xcode运行
  • 删除pod / podfile并重新安装
  • 重新启动计算机
  • flutter run
  • 创建新应用
  • 检查是否符合Flutter所有“ Get started”说明
  • 从Xcode运行
  • 将工作区切换到旧版构建系统
  • Locking & unlocking login in Keychain Access
  • 使用Finder授予对项目文件夹和所有附带项目的读/写权限,并在文件上运行app/Frameworks/App.framework/App: signed bundle with Mach-O universal (x86_64 arm64) [io.flutter.flutter.app] /Users/user/Desktop/projects/myApp/build/ios/Debug-iphonesimulator/Runner. app/Frameworks/Flutter.framework/Flutter: replacing existing signature /Users/user/Desktop/projects/myApp/build/ios/Debug-iphonesimulator/Runner. app/Frameworks/Flutter.framework/Flutter: Permission denied Command PhaseScriptExecution failed with a nonzero exit code note: Using new build system note: Building targets in parallel note: Planning build note: Constructing build description Could not build the application for the simulator. Error launching application on iPhone 11.

flutter clean输出:

chmod +x

更新I have opened an issue in the Flutter Github repo

2 个答案:

答案 0 :(得分:0)

基于this问题,这似乎与xcode_backend.sh文件有关,使得某些Flutter文件为只读,请检查问题和this问题,可能有助于您解决问题,祝你好运。

答案 1 :(得分:0)

我终于能够解决此问题,并通过执行以下步骤在iOS模拟器上运行Flutter演示应用程序:

  1. flutter version v1.11.0(降级为Flutter的早期版本)
  2. flutter channel stable
  3. flutter upgrade
  4. flutter doctor
  5. flutter create test_app
  6. cd test_app
  7. flutter run