Common issues in the Xamarin 15.2.2 release being tracked by the Xamarin team

In case it might be useful for reference, here is an update on the previous list of commonly seen issues from the Xamarin 15.2 release. Many of those issues are now resolved in the Xamarin 15.2.2 release.  This updated list gives the latest statuses and workarounds for a few remaining issues from the Xamarin 15.2 release and the Xamarin 15.2.2 release, with a focus on bug reports that have several subscribed users.

  • Bug 56787 [Xamarin.VisualStudio, Xamarin.iOS, Xamarin.Android] “Could not load file or assembly ‘Mono.Posix, Version=2.0.0.0, …'” in some cases when attempting to start debugging with breakpoints set. This happens because the Mono.Posix.dll file is missing from the Xamarin.VisualStudio installer.
    • Temporary workaround:
      1. Download the missing Mono.Posix file and unzip the archive.
      2. Right-click the Mono.Posix.dll file in Explorer and select Properties.
      3. Check the Digital Signatures tab to ensure the file shows a valid Xamarin Inc. signature.
      4. At the bottom of the General tab, if an Unblock checkbox appears, enable it and select OK. (This checkbox appears depending on how the file was downloaded.)
      5. For Visual Studio 2017, copy the Mono.Posix.dll file into the “Xamarin.VisualStudio” extension directory. For example, for a default installation of the Enterprise edition, copy the file into:
        C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\Common7\IDE\Extensions\Xamarin.VisualStudio
      6. For Visual Studio 2015, copy the file into the “Xamarin\Xamarin” extension directory:
        C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\Extensions\Xamarin\Xamarin\
      7. Quit and restart Visual Studio.
    • If these steps to do not resolve the issue in your environment, please see the bug report for information about enabling “Fusion logging” (assembly binding logging) and submitting a new bug report for further investigation.
  • Bug 56893 and Bug 56808 [Xamarin.VisualStudio, Xamarin.iOS] Breakpoints are non-functional  and exception call stacks show user code as “External Code” in certain scenarios when debugging on iOS devices and simulators with the linker enabled.
    • Possible temporary workaround: Change the DebugType to portable to more closely match the build behavior of Visual Studio for Mac.
      1. Open each project .csproj file in a text editor. For example, right-click each project in the Solution Explorer and select Unload Project, and then right-click it again and select Edit.
      2. Under the PropertyGroup for the “Debug|AnyCPU” configuration, set:
        <DebugType>portable</DebugType>
      3. Save the changes and reload the projects.
      4. Clean the solution and manually delete the “bin” and “obj” folders to remove any left-over .mdb debugger symbol files.
      5. If any of the projects use async partial methods, install the Microsoft.Net.Compilers  pre-release version 2.3.0-beta1 NuGet package (or higher) into all of the projects (to fix Roslyn issue 17934).
  • Bug 56246 [Mono, Xamarin.Android, Xamarin.iOS, Xamarin.Mac] Tracking bug for upstream Roslyn issue 17934: “error MSB6006: “csc.exe” exited with code 1″ due to KeyNotFoundException when compiling projects that include async partial methods.
    • Possible temporary workaround: Install the Microsoft.Net.Compilers  pre-release version 2.3.0-beta1 NuGet package (or higher) into all of the projects to get the pre-release Roslyn C# compiler that includes the fix.
    • Alternate temporary workaround: Switch back to mcs and xbuild.
      1. Add the following PropertyGroup element to the bottom of the .csproj file for your app project just before the closing </Project> tag:
        <PropertyGroup Condition=" '$(OS)' == 'Unix' ">
            <CscToolExe>mcs.exe</CscToolExe>
        </PropertyGroup>
      2. Disable Visual Studio > Preferences > Build > Build with MSBuild instead of xbuild. (This setting is also available in Xamarin Studio 6.3. It is disabled by default in Xamarin Studio, but some users might have enabled it by hand in the past.)
      3. Close and reopen the solution to ensure the new setting is used.
      4. Clean and rebuild the project.
    • developercommunity 63718 [Xamarin.VisualStudio] In certain environments, Visual Studio crashes often due to an unhandled exception in a Zeroconf method called by Xamarin.VisualStudio.ZeroConf.MacDiscoveryService.