gpt4 book ai didi

ios - Ionic - 构建 IOS 版本的应用程序时出错

转载 作者:行者123 更新时间:2023-12-02 02:55:18 26 4
gpt4 key购买 nike

我使用 PC 和 Windows 10 开发了整个应用程序。我成功构建了 Android 版本并将其上传到 Play 商店,该版本已被接受。

现在,我面临着准备iOS版本的挑战,我希望它会很简单。然而,几个小时后,我仍然面临着同样的问题,我不知道如何解决。运行ionic Cordova build ios,我收到以下错误:

(node:1852) UnhandledPromiseRejectionWarning: SyntaxError: Expected "/ Begin ", "/ End ", "\"", or [A-Za-z0-9_.] but "/" found. at peg$buildStructuredError (/Users/mitja/Projects/oventura/platforms/ios/cordova/node_modules/xcode/lib/parser/pbxproj.js:412:12) at Object.peg$parse [as parse] (/Users/mitja/Projects/oventura/platforms/ios/cordova/node_modules/xcode/lib/parser/pbxproj.js:1886:11) at pbxProject.parseSync (/Users/mitja/Projects/oventura/platforms/ios/cordova/node_modules/xcode/lib/pbxProject.js:46:24) at Object.parseProjectFile [as parse] (/Users/mitja/Projects/oventura/platforms/ios/cordova/lib/projectFile.js:41:15) at updateFileResources (/Users/mitja/Projects/oventura/platforms/ios/cordova/lib/prepare.js:480:33) at /Users/mitja/Projects/oventura/platforms/ios/cordova/lib/prepare.js:65:13 at _fulfilled (/Users/mitja/Projects/oventura/platforms/ios/cordova/node_modules/q/q.js:854:54) at self.promiseDispatch.done (/Users/mitja/Projects/oventura/platforms/ios/cordova/node_modules/q/q.js:883:30) at Promise.promise.promiseDispatch (/Users/mitja/Projects/oventura/platforms/ios/cordova/node_modules/q/q.js:816:13) at /Users/mitja/Projects/oventura/platforms/ios/cordova/node_modules/q/q.js:570:49 (node:1852) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1) (node:1852) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

我不知道哪个文件或应用程序的哪个部分导致了错误,但我确实知道创建一个新项目并构建它在那里工作得很好,所以肯定是我们的项目中的某些东西(在 Windows 上构建得很好)适用于 Android)。

这是我们的插件列表:

"cordova-plugin-statusbar"
"cordova-plugin-whitelist"
"cordova-plugin-device"
"cordova-plugin-splashscreen"
"cordova-plugin-ionic-webview"
"cordova-plugin-ionic-keyboard"
"cordova-plugin-datepicker"
"cordova-plugin-braintree"
"uk.co.workingedge.phonegap.plugin.launchnavigator"
"mx.ferreyra.callnumber"

对于 Braintree,我必须按照插件 github 存储库中所述执行 npm install plist 和 npm install Xcode,这样就完成了。

那么,什么可能导致错误呢?我可以尝试什么才能成功构建 iOS 版本?

最佳答案

我忘了更新答案,但就在这里。所以,正如已经发现的那样,问题在于 Braintree 的插件。要真正使其工作,您必须使用官方插件的 fork 版本:

ionic cordova platform remove ios
ionic cordova plugin add https://github.com/dpa99c/cordova-plugin-braintree
ionic cordova platform add ios

关于ios - Ionic - 构建 IOS 版本的应用程序时出错,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/49475271/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com