Notice (2018-05-24): bugzilla.xamarin.com is now in
Please join us on
Visual Studio Developer Community and in the
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
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 or GitHub 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.
So I've been porting a large app from XNA to IOS. I've been working primarily in the simulator and everything has been fine.
Today I dropped in a provision, got the build running against my Ipad and found it crashes. I'm pretty sure it's because of subtle differences between the simulator and the target in terms of how it handles file paths (the functionality is not 100% the same - the simulator is way more forgiving than the target is). However, on going back to try and run in the simulator, I get "Cannot execute" and a path that I cannot see completely, nor can I select it or open it see the completely path.
Now I've tried cleaning, rebuilding, with no luck. I've tried exiting Xamarin Studio and restarting, and the same thing happens.
This is a show stopper bug for me, because I cannot debug on the device using Xamarin Studio (which is another bug entirely).
More info. It looks very much like the Xamarin Studio is no longer copying the built bundle to the simulator directories.
The bundle builds successfully and I can see it in the Bin Directory for the Xamarin Studio project, but it is NOT being copied to the place where the simulator runs it from (and it used to be).
Is there some setting that was put in place for the building to target that _stops_ this copying from occurring now? Or is it just a bug?
There's no setting, so it's not something you did wrong.
Some other people are reporting similar problems and one person reported that his log file in ~/Library/Logs/XamarinStudio-4.0/Ide.log had an exception thrown by Bind() because the port was already in use.
It might be that we are leaking sockets, so I'm going to try and track that down tomorrow.
As to why files aren't being copied into the Simulator path, that could be a separate bug in the Xamarin.iOS tooling.
For you, it might be that it's not anything to do with Bind() and everything to do with the app not being installed into the Simulator by our iOS tools.
I'll have to do some digging to find out for sure. In the meantime, can you check if your log files contain the Bind() exception?
In ~/Library/Preferences/XamarinStudio-4.0/MonoDevelopProperties.xml, look for the MonoTouch settings:
<Property key="MonoTouch.Debugger.UsbDebugging" value="True" />
<Property key="MonoTouch.Debugger.Port" value="10000" />
<Property key="MonoTouch.Debugger.UsePermanentConnection" value="True" />
If you change the MonoTouch.Debugger.Port value to 0, does that fix this?
If so, then I think it's safe to say that a commit I just landed in git master will solve this issue.
The debugger port value is really only necessary for the original way we used to do debugging (we'd have to write that port # into a configuration file in the .app so that the app could connect back to Xamarin Studio, but we have since changed the way we do things so that we can pass that info along via the command-line instead).
What we should have been doing was using a value of 0 when connecting using the newer method (which is actually about a year or so old at this point) but it looks like where there was a merge conflict in the source a few months ago, it reintroduced the use of the MonoTouch.Debugger.Port value.
Changing the port to 0 seems to fix it for other users with this problem on the forums
*** Bug 11444 has been marked as a duplicate of this bug. ***
Created attachment 3704 [details]
Another recording showing that resolution of bug 11341 won't fix this one
Carlos: you probably got bitten by Xamarin Studio restoring the old value (which people on the forums have had happen to them)
*** Bug 11722 has been marked as a duplicate of this bug. ***
It looks like setting the DebuggerPort to 0 in the config file fixes the simulator, but breaks the device.
Anyways, that's not an issue with my actual fix since my actual fix hard-codes port 0 for the simulator but uses the value in the config file for USB debugging.