Bug with starting Instruments via Profile under Xcode 4.1 Build 4B110

一世执手 提交于 2019-12-17 21:55:47

问题


Important Update

Strange bug is fixed (at least for me) in Xcode 4.2!


I've a severe problem with Xcode 4.1 Build 4B110 under Mac OS X Lion and running Instruments via Xcode. The problem is that Instrument freezes in partly if I start it via Xcode. So if I start a project in Xcode 4.1 and open "Profile" the Instruments UI appears. The timer starts running, but the instruments app doesn't track anything and the more severe problem:

The program seems to be running but does not react on any actions I make. So I can not click on any buttons etc. Nothing happens. The timer is still running, but I can not do anything. So I also can not close the window/app anymore. So I've to force stopping the Instruments app.

But if I start the Instruments app directly via Developer/Applications/Instruments.app everything is ok. Of course the app doesn't track anything, but I can click on the buttons and anything possible there.

So does anyone know about this problem?

Does anybody know how to fix this weird problem?

I've also deleted the developers folder with the corresponding deinstall-script file and reinstalled Xcode 4.1. But still the same problem.

Can anybody give me a hint, tip, etc.?

Would be really great!

Update

So, further weird stuff:

Profile somehow worked for iOS 3.0 version apps, but after making a short break it didn't worked again. So I don't know where this bug is located. I guess it's about the target app iOS version.

Thanks, Andreas


回答1:


Quoting your comment on this, andi1984, so that no one misses this "big" answer for anyone (like me) for whom it is a lifesaver. This worked great for me!

If I'm opening Xcode, choose Profile and choose one instrument (let's say Leaks) the new Instrument window opens. Then I need to go back to Xcode (while Instrument.app window is still open in background!) and have to use command + tab to choose out of Xcode in front the Instrument.app again. Then the Instrument app shows me the tracked data. Really weird problem, but now it works. ;-)




回答2:


Epaga's solution sometimes works & sometimes doesn't.

Therefore I suggest everyone duplicates the following open radar so that Apple gives this issue some priority:

http://openradar.appspot.com/9855452




回答3:


I had the problem of instruments locking up and the above cmd-tab trick didn't work until I did it such that the dialog "Instruments is trying to access your computer" appeared asking for my password. After I entered the password then I could get to instruments. I suspect the problem is the password dialog is hidden in the Xcode windows. In this case Instruments is frozen because it has the modal dialog open.

So:

  1. Run Instruments
  2. Cmd Tab to Xcode covering the instruments. Cycle and hide messages until password dialog is found. Close Xcode

This may be a one time thing... now that I gave Instruments access it may not need the password again.




回答4:


I've found that if I leave two Instruments windows open at the same time, when Instruments locks up in one window, bringing the other window into the foreground seems to snap Instruments out of it. It seems to bring Instruments back if you can get the focus on a different Instruments window than the one that's locked.

I've found the two-window-method works all the time while the Xcode-profile-method only works sometimes.

Edit:

After trying the two-window-method a bit more, this method also only works sometimes.



来源:https://stackoverflow.com/questions/6801310/bug-with-starting-instruments-via-profile-under-xcode-4-1-build-4b110

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!