简体   繁体   English

使用xcode运行时ios App挂在ionic上

[英]ios App hangs in ionic, while running using xcode

After building our ionic app using : 使用以下命令构建我们的离子应用程序后:

cordova build ios

I ran it in my iphone 6 using xcode. 我使用xcode在我的iPhone 6中运行了它。 It works great. 效果很好。 Now when I kill the app in device and click on the app icon to launch it from the device it takes longer to launch, and stays in a hanged state, unable to even inspect it using safari. 现在,当我在设备中杀死该应用程序并单击该应用程序图标以从设备启动它时,它需要更长的启动时间,并且处于挂起状态,甚至无法使用野生动物园对其进行检查。

(No way related to this question, still) there occurs no issues even if the app is killed in android. (仍然没有与此问题相关的方式)即使该应用在android中被杀死,也不会发生任何问题。 It works just fine. 它工作正常。

Has anyone experienced such an issues? 有没有人遇到过这样的问题? Is there a way out to it? 有办法吗?

The issue is actually discussed in Ionic Forums . 该问题实际上在Ionic论坛中进行了讨论。 It's not of logic, but when you run via Xcode, there are controls of xcode associated to the build. 这不合逻辑,但是当您通过Xcode运行时,会有与构建关联的xcode控件。 So once we kill the app and restart it, the controls of Xcode are disconnected, so there are 2 issues: 因此,一旦我们终止该应用程序并重新启动它,Xcode的控件就会断开连接,因此存在两个问题:

1) Xcode maintains some active connection which is used for debugging purposes, while launching app via xcode. 1) Xcode在通过xcode启动应用程序时会维护一些活动连接,用于调试目的。

2) If that connection is broken - to mess with the phone Xcode is expected to throw an error about a process being killed or something but to block the main-thread. 2)如果该连接断开-弄乱手机Xcode,则会抛出有关进程被终止或其他原因的错误,但会阻塞主线程。 But that doesn't happen. 但这不会发生。

3) It has something to do with how the XCode debugger works. 3)与XCode调试器的工作方式有关。 Either the PC or the device is trying to poll each other constantly and if we deviate from what they are expecting it causes problems on the iPhone. PC或设备都在尝试不断地相互轮询,如果我们偏离了他们的预期,则会在iPhone上引起问题。

Although xcode detects if the phone is disconnected, but it still fails to detect if the app was killed 尽管xcode会检测手机是否已断开连接,但仍无法检测到该应用是否被杀死

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

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