Bug 27012 - Error when targeting iOS app with Xamarin Profiler
Summary: Error when targeting iOS app with Xamarin Profiler
Status: RESOLVED FIXED
Alias: None
Product: Profiler
Classification: Xamarin
Component: General ()
Version: unspecified
Hardware: Macintosh Mac OS
: --- normal
Target Milestone: ---
Assignee: Rodrigo Moya
URL:
Depends on:
Blocks:
 
Reported: 2015-02-12 16:58 UTC by Yegor Ius
Modified: 2015-02-16 12:08 UTC (History)
2 users (show)

Tags:
Is this bug a regression?: ---
Last known good build:


Attachments
Xamarin profile error (8.11 KB, text/plain)
2015-02-12 16:58 UTC, Yegor Ius
Details
Profiler error (23.58 KB, image/png)
2015-02-12 16:59 UTC, Yegor Ius
Details
Xamarin and Xcode info (882 bytes, text/plain)
2015-02-12 17:00 UTC, Yegor Ius
Details


Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on Developer Community with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
RESOLVED FIXED

Description Yegor Ius 2015-02-12 16:58:56 UTC
Created attachment 9806 [details]
Xamarin profile error

Having trouble pointing profiler to my application's .app file and launching it. The error is: "could not open /var/folders/ns/GUID/T/GUID.tmp". Same error occurs when targeting the app on a simulator and on a device.
The profiler log (attached), restates the same error.

Any idea what is causing this?
The device logs don't seem to have any errors related to this.

Also, when I follow this article, http://developer.xamarin.com/guides/cross-platform/deployment,_testing,_and_metrics/xamarin-profiler/
and compare to my Xamarin Studio, the menu options are different. For example, instead of Run > Start Profiling, I have Tools > Launch Profiler.
I’m wondering if the issue I am experiencing is due to an incompatible version of XS? (I don’t want to switch to beta, only to stable releases, because of prior mishaps where I had to reinstall XS.)

I am able to reproduce the issue for multiple solutions. For example, the profiler throws the same error when I try to start the TaskyiOS app.

I assume others have gotten the profiler to work?

Thanks.
Comment 1 Yegor Ius 2015-02-12 16:59:57 UTC
Created attachment 9807 [details]
Profiler error
Comment 2 Yegor Ius 2015-02-12 17:00:24 UTC
Created attachment 9808 [details]
Xamarin and Xcode info
Comment 3 Rodrigo Moya 2015-02-13 08:24:38 UTC
Can you please attach the profiler logs (which are in ~/Library/Logs/Xamarin.Profiler)?

However, it looks like you are trying to load an iOS .app bundle directly, which doesn't work. You need to profile via XS (open your project and select 'Start Profiling').

We have fixed though the detection of .app bundles, which should be available in the new release that we'll be publishing in the next few days
Comment 4 Rodrigo Moya 2015-02-13 08:27:54 UTC
Sorry, missed the logs, so yes, you are trying to profile an iOS app by selecting its .app folder, which works for Mac apps, but not for iOS. So yes, for iOS you need to open your iOS project in XS, and select 'start profiling' from XS, which will start the profiler with the correct environment and arguments for it to work

Also, as mentioned before, we have fixed the detection of .app bundles, so marking this as fixed
Comment 5 Yegor Ius 2015-02-13 11:52:28 UTC
That's great news, looking forward to the new version.

In XS, I don't have a Start Profiling or anything equivalent in the menu options. Only the option to Launch Profiler in Tools, so you first suggestion doesn't work (perhaps menu items are different in the XS version that I have? 5.7.1.)
Comment 6 Rodrigo Moya 2015-02-16 11:19:53 UTC
XS checks the license you have and only displays those items if profiling is available for the current project, so what happens if you load a solution with an iOS project and you select the iOS project to be the startup project?
Comment 7 Yegor Ius 2015-02-16 11:55:57 UTC
Thanks Rodrigo. I already had the correct iOS project set be the start up project, but the solution was to simply switch to another project, then switch back. 
I am able to run the profiler now.
Though we are using Boehm GC, which I see is not supported. I will read up on what it means to switch to SGen GC.
Thanks.
Comment 8 Rodrigo Moya 2015-02-16 12:08:36 UTC
Boehm is not supported on the runtime profiler for iOS, so we get no data at all. SGen should be faster and better AFAIK, and is supported, so give it a try, at least for being able to profile