Alpha service release: Xamarin.Android 5.1.2, bug fixes for 5.1.0

BrendanZagaeskiBrendanZagaeski USForum Administrator, Xamarin Team Xamurai
edited May 2015 in Xamarin.Android

This thread has now been closed to direct all further updates about this service release onto the new Beta release thread:

http://forums.xamarin.com/discussion/41665/beta-service-release-xamarin-android-5-1-2-bug-fixes-for-5-1-0/p1

For anyone who has been commenting on this thread, feel free to continue the conversation in that new thread.


Alpha service release: Xamarin.Android 5.1.2.0, bug fixes for 5.1.0.115

Released versions:

Windows

Mac

Reason for release: Bug fixes for the 5.1.0.115 Stable Channel release on April 29.

Date published:

NOTE: Alpha versions have not yet completed the full suite of tests by the Xamarin QA team. That said, customer reports of any regressions (or bugs that are incorrectly marked "fixed") are still much appreciated, even if the problem would have eventually been caught during the full QA testing process.

Previous versions, downgrading

You can downgrade back to the current Stable version by switching updater channels.

You can downgrade back to the previous Stable versions (from before April 29) by manually reinstalling each old package (see also the article about downgrading). The links to the previous Stable versions are:

Windows

Mac

Guidelines for this thread

  1. This first post will be updated regularly.

  2. Hopefully this thread will help answer "what regressions have been fixed compared to the current Stable version?" and "what might break if I update to this release?"

  3. If you find a new problem that is specific to this version, please file a bug report (if this link redirects to the top-level https://kb.xamarin.com/ page the first time you click it, try clicking it once more).

  4. Please discuss older bugs that are unchanged in this release compared to the previous Stable version in Bugzilla instead.

  5. Of course for questions and discussions about topics other than bugs, feel free start new forum threads.

Fixes for "new known issues" in the April 29 Stable Channel release

  • Bug 29133 - [XamarinVS] [iOS] [Android] Visual Studio hangs when debugging some iOS and Android applications that use multiple threads.

  • Bug 29680 - [XamarinVS] [iOS] [Android] Ignorable "ERROR: Not implemented (Exception from HRESULT: 0x80004001 (E_NOTIMPL))" message from the new Test Cloud integration. Partial workaround: uninstall the Test Cloud integration: https://bugzilla.xamarin.com/show_bug.cgi?id=29680#c2.

  • Bug 29220 - [XamarinVS] [iOS] [Android] "ERROR: Value cannot be null. Parameter name: project" when opening and building projects. So far, this problem appears to be related to specifics of the system configuration. If anyone happens to notice one particular difference between a working project and a failing project (or a computer without the problem and a computer with the problem), be sure to let us know right away. Partial workaround: uninstall the Test Cloud integration: https://bugzilla.xamarin.com/show_bug.cgi?id=29680#c2.

  • Bug 29568 - [Android] "No resource found that matches the given name", for AppCompat resources in the Android Support library.

  • Non-public bug 29866 - [Android] Windows only: "System.InvalidOperationException: Can't not find the nested type" when building with the linker enabled.

  • Non-public Bug 29172 - [Android] "'...Resource' does not contain a definition for `Id'" (for example, when using the Scandit component).

  • Bug 29730 - [Android] Event handlers subscribed to (some?) events that are bound to Java callbacks no longer work (for example ViewTreeObserver.GlobalLayout). Workaround: use the corresponding "Add/Remove...Listener" methods instead: https://bugzilla.xamarin.com/show_bug.cgi?id=29730#c2.

  • Bug 29570 - [Android] Greater-than and less-than comparisons of decimal numbers do not work correctly.

  • Bug 29263 - [Android] Classes that are referenced by files in the "Resources/xml/" folder will currently all need [Register] attributes, even if the "XML element name" syntax is used.

  • Non-public Bug 29170 - [Android] Profiling via log:sample causes the app to crash at startup.

  • Non-public Bug 28557 - [Android] In certain cases breakpoints will only pause program execution the first time they are hit.

  • Bug 29039 - [Mono] CultureInfo.GetCultureInfo("ar-SA").DateTimeFormat throws a NullReferenceException for the ar-SA culture.

  • Bug 28210 - [XamarinVS] [Android] New projects created from templates show ignorable build warning: "@(Content) build action is not supported ... AndroidManifest.xml". Workaround: change the build action of "AndroidManifest.xml" to "none".

Remaining known issues from the April 29 Stable Channel release, with more common or severe issues near the top

(This list should get smaller as new Alpha builds are published over the coming week.)

  • Bug 29326 - [Android] String resources defined in NuGet packages overwrite string resources defined in app project, causing the displayed app name to be incorrect for example. Workaround: avoid using the same string key that is used in the NuGet packages.

  • Non-public Bug 29538 - [Android] Profiling via the graphical Xamarin Profiler ("Run -> Start Profiling") causes the app to crash at startup.

  • Non-public Bug 28995 - [Android] On certain devices apps crash rarely due to "System.ExecutionEngineException: SIGILL".

  • Bug 29731 - [Android] Android.Bluetooth.BluetoothAdapter.Enable is incorrectly marked as [Obsolete("deprecated")] for API level 20 and higher.

  • Bug 29725 - [Xamarin Studio] [iOS] [Android] Expressions in the Watch window are cleared each time you stop debugging.


EDIT May 07: Add XamarinVS bug 29822 and XamarinVS bug 29703.
EDIT May 07: Remove Xamarin.iOS non-public bug 29764 because it is not really a regression.
EDIT May 07: Add XamarinVS bug 29839.
EDIT May 08: Update version numbers for new Alpha builds. Move more bugs to the "Fixes" section accordingly. (29628 29680 29220 29568 29172 29730 29703)
EDIT May 08: Add Android bug 29538. Adjust Android bug 29170 description accordingly.
EDIT May 08: Add iOS bug 29745 with workarounds.
EDIT May 09: Add Alpha-only Android bug 29866.
EDIT May 11: Add XamarinVS.iOS bug 29849 with workaround.
EDIT May 13: Add Xamarin.iOS bug 28961.
EDIT May 13: Update version numbers for new Alpha builds. Move more bugs to the "Fixes" section accordingly. (29839 29866 29570)
EDIT May 13: Add "Xamarin Log" error message for 28961.
EDIT May 14: Update version numbers. iTunesMetadata.plist is now removed automatically from App Store builds.
EDIT May 19: Close this Alpha thread and a link to the new Beta thread.

Posts

  • BradChaseBradChase USMember

    Note that I am still getting:

    Error 117 Exception while loading assemblies: System.IO.FileNotFoundException: Could not load assembly 'System.Deployment, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'. Perhaps it doesn't exist in the Mono for Android profile?
    File name: 'System.Deployment.dll'
    at Xamarin.Android.Tuner.DirectoryAssemblyResolver.Resolve(AssemblyNameReference reference, ReaderParameters parameters)
    at Xamarin.Android.Tasks.ResolveAssemblies.AddAssemblyReferences(ICollection`1 assemblies, AssemblyDefinition assembly, Boolean topLevel)
    at Xamarin.Android.Tasks.ResolveAssemblies.Execute()

    For now I am going to revert back to an older version until this is fixed.

  • BradChaseBradChase USMember
    edited May 2015

    Well I tried to downgrade and now I am getting a new error:
    Error 146 The "LinkAssemblies" task failed unexpectedly.
    Xamarin.Android.XamarinAndroidException: error XA2006: Reference to metadata item 'System.Void Android.Widget.AbsListView::SetSelectionFromTop(System.Int32,System.Int32)' (defined in 'Xamarin.Forms.Platform.Android, Version=1.4.0.0, Culture=neutral, PublicKeyToken=null') from 'Xamarin.Forms.Platform.Android, Version=1.4.0.0, Culture=neutral, PublicKeyToken=null' could not be resolved. ---> Mono.Cecil.ResolutionException: Failed to resolve System.Void Android.Widget.AbsListView::SetSelectionFromTop(System.Int32,System.Int32)
    at Mono.Linker.Steps.MarkStep.MarkMethod(MethodReference reference)
    at Mono.Linker.Steps.MarkStep.MarkInstruction(Instruction instruction)
    at Mono.Linker.Steps.MarkStep.MarkMethodBody(MethodBody body)
    at Mono.Linker.Steps.MarkStep.ProcessMethod(MethodDefinition method)
    at Mono.Linker.Steps.MarkStep.ProcessQueue()
    at Mono.Linker.Steps.MarkStep.Process()
    at Mono.Linker.Steps.MarkStep.Process(LinkContext context)
    at Mono.Linker.Pipeline.Process(LinkContext context)
    at MonoDroid.Tuner.Linker.Process(LinkerOptions options, LinkContext& context)
    at Xamarin.Android.Tasks.LinkAssemblies.Execute()
    --- End of inner exception stack trace ---
    at Xamarin.Android.Diagnostic.Error(Int32 code, Exception innerException, String message, Object[] args)
    at Xamarin.Android.Tasks.LinkAssemblies.Execute()
    at Microsoft.Build.BackEnd.TaskExecutionHost.Microsoft.Build.BackEnd.ITaskExecutionHost.Execute()
    at Microsoft.Build.BackEnd.TaskBuilder.d__20.MoveNext()

    The Xamarin.Forms.Platform.Android that is being referenced is in my Packages/Xamarin.Forms.1.4.2.6359 directory. Do I need to do anything else to be able to get moving again?

    EDIT: I had zipped up a backup and I was able to use that without fail. So I learned a VERY important lesson. When upgrading xamarin, make sure to backup all code before hand. It was invaluable for me.

  • 15mgm1515mgm15 USMember ✭✭✭✭

    I am getting this while trying to download from the Alpha channel :/

  • BrendanZagaeskiBrendanZagaeski USForum Administrator, Xamarin Team Xamurai

    Could not load assembly 'System.Deployment

    Related to BradChase's post from earlier in the thread, so far the Xamarin QA team hasn't come across a sample that reproduces this error. If anybody might be able to zip up and attach a test case on a new bug report (or attach it directly on this thread, or send it in via [email protected]), that would be perfect. See the bug filing KB article for some additional hints and tips about filing a bug report and minimizing the test case. (If the link to the KB article redirects to the top-level kb.xamarin.com/ page the first time you click it, try clicking it once more.) Thanks!

  • BrendanZagaeskiBrendanZagaeski USForum Administrator, Xamarin Team Xamurai

    @15mgm15, that is often only a temporary error. Sometimes you can get it to stop by logging out and logging back in to your Xamarin account. (See also https://kb.xamarin.com/customer/portal/articles/1696718-errors-when-checking-for-updates. If that link redirects to the top-level kb.xamarin.com/ page the first time you click it, try clicking it once more.)

  • CarelLotzCarelLotz ZAMember ✭✭

    OK, downloaded and installed the latest Alpha (3.11.546) to get the fix for the Bug 29568. The fix works fine, however, I'm now getting the following issue when doing a Release build with Linking set to SDK assemblies only

    17>C:\Program Files (x86)\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(1290,5): error MSB4018: The "LinkAssemblies" task failed unexpectedly.
    17>C:\Program Files (x86)\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(1290,5): error MSB4018: System.InvalidOperationException: Can't not find the nested type '<System.Windows.Input.ICommand.Execute>d__4' in 'Microsoft.Practices.Prism.Commands.DelegateCommandBase
    17>C:\Program Files (x86)\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(1290,5): error MSB4018:    at Mono.Cecil.TypeParser.TryGetDefinition(ModuleDefinition module, Type type_info, TypeReference& type)
    17>C:\Program Files (x86)\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(1290,5): error MSB4018:    at Mono.Cecil.TypeParser.GetTypeReference(ModuleDefinition module, Type type_info)
    17>C:\Program Files (x86)\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(1290,5): error MSB4018:    at Mono.Cecil.TypeParser.ParseType(ModuleDefinition module, String fullname)
    17>C:\Program Files (x86)\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(1290,5): error MSB4018:    at Mono.Cecil.SignatureReader.ReadTypeReference()
    17>C:\Program Files (x86)\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(1290,5): error MSB4018:    at Mono.Cecil.SignatureReader.ReadCustomAttributeElementValue(TypeReference type)
    17>C:\Program Files (x86)\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(1290,5): error MSB4018:    at Mono.Cecil.SignatureReader.ReadCustomAttributeElement(TypeReference type)
    17>C:\Program Files (x86)\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(1290,5): error MSB4018:    at Mono.Cecil.SignatureReader.ReadCustomAttributeFixedArgument(TypeReference type)
    17>C:\Program Files (x86)\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(1290,5): error MSB4018:    at Mono.Cecil.SignatureReader.ReadCustomAttributeConstructorArguments(CustomAttribute attribute, Collection`1 parameters)
    17>C:\Program Files (x86)\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(1290,5): error MSB4018:    at Mono.Cecil.MetadataReader.ReadCustomAttributeSignature(CustomAttribute attribute)
    17>C:\Program Files (x86)\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(1290,5): error MSB4018:    at Mono.Cecil.CustomAttribute.<Resolve>m__1(CustomAttribute attribute, MetadataReader reader)
    17>C:\Program Files (x86)\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(1290,5): error MSB4018:    at Mono.Cecil.ModuleDefinition.Read[TItem,TRet](TItem item, Func`3 read)
    17>C:\Program Files (x86)\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(1290,5): error MSB4018:    at Mono.Cecil.CustomAttribute.Resolve()
    17>C:\Program Files (x86)\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(1290,5): error MSB4018:    at Mono.Cecil.CustomAttribute.get_HasConstructorArguments()
    17>C:\Program Files (x86)\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(1290,5): error MSB4018:    at Mono.Linker.Steps.MarkStep.MarkCustomAttributeArguments(CustomAttribute ca)
    17>C:\Program Files (x86)\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(1290,5): error MSB4018:    at Mono.Linker.Steps.MarkStep.MarkCustomAttribute(CustomAttribute ca)
    17>C:\Program Files (x86)\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(1290,5): error MSB4018:    at Mono.Linker.Steps.MarkStep.MarkCustomAttributes(ICustomAttributeProvider provider)
    17>C:\Program Files (x86)\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(1290,5): error MSB4018:    at Mono.Linker.Steps.MarkStep.ProcessMethod(MethodDefinition method)
    17>C:\Program Files (x86)\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(1290,5): error MSB4018:    at Mono.Linker.Steps.MarkStep.ProcessQueue()
    17>C:\Program Files (x86)\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(1290,5): error MSB4018:    at Mono.Linker.Steps.MarkStep.Process()
    17>C:\Program Files (x86)\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(1290,5): error MSB4018:    at Mono.Linker.Steps.MarkStep.Process(LinkContext context)
    17>C:\Program Files (x86)\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(1290,5): error MSB4018:    at Mono.Linker.Pipeline.Process(LinkContext context)
    17>C:\Program Files (x86)\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(1290,5): error MSB4018:    at MonoDroid.Tuner.Linker.Process(LinkerOptions options, LinkContext& context)
    17>C:\Program Files (x86)\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(1290,5): error MSB4018:    at Xamarin.Android.Tasks.LinkAssemblies.Execute()
    17>C:\Program Files (x86)\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(1290,5): error MSB4018:    at Microsoft.Build.BackEnd.TaskExecutionHost.Microsoft.Build.BackEnd.ITaskExecutionHost.Execute()
    17>C:\Program Files (x86)\MSBuild\Xamarin\Android\Xamarin.Android.Common.targets(1290,5): error MSB4018:    at Microsoft.Build.BackEnd.TaskBuilder.<ExecuteInstantiatedTask>d__20.MoveNext()
    

    I've turned off linking to past the issue but our app explodes from 18MB up to 43MB so this is not really a possible solution.
    I've created a bug report on.

  • CarelLotzCarelLotz ZAMember ✭✭

    I also tried ignoring the assembly using the AndroidLinkSkip, but this seems to have no affect at all. Seems other users are having the same issues. I've filed another bug for this as well.

  • BrendanZagaeskiBrendanZagaeski USForum Administrator, Xamarin Team Xamurai

    Thanks for the reports @CarelLotz! I have commented on the bug reports and added a non-public (filed by the QA team) Alpha-only bug that I believe matches the symptoms to the first post in the thread:

    Non-public bug 29866 - [Android] Windows only: "System.InvalidOperationException: Can't not find the nested type" when building with the linker enabled.

  • EstebanGimbernatEstebanGimbernat MXMember

    Now Android.Speech.TTS.TextToSpeech is marked as deprecated on this version.
    It is? If yes, what is the replacement?

  • BrendanZagaeskiBrendanZagaeski USForum Administrator, Xamarin Team Xamurai

    @EstebanGimbernat, hmm. That sounds like the same underlying problem as Bug 29731. To be safe, we should probably get a bug filed for the specific case of Android.Speech.Tts.TextToSpeech.

    I haven't yet found the right combination of versions where that type is marked as deprecated. (I see several methods, properties, and fields within that type that are marked as deprecated, but those all match the deprecations listed in the Android documentation.)

    So 2 quick follow-up questions:

    1. Is it the Android.Speech.Tts.TextToSpeech class itself that is coming up as deprecated, or is it some method, property, or field within that class?

    2. What do you have set either:

      • In Xamarin Studio under "Project Options -> Build -> General -> Target framework" and under "Project Options -> Android Application -> Target Android version".

      • Or in Visual Studio under "Project Properties -> Application -> Compile using Android version" and "Project Properties -> Application -> Target Android version".

    Thanks!

  • @BrendanZagaeski the latest alpha 3.11.558 failed to install for me on Windows. It left the Visual Studio extension broken. I had to uninstall and reinstall stable to get it working again. I haven't tried to reinstall the alpha again since. Let me know if you need more debugging info. Not sure if it is just me.

  • EstebanGimbernatEstebanGimbernat MXMember

    @BrendanZagaeski all right, that's what I found:
    1- Method Speak is marked depracated and according to documentation is above api 21 that originally Speak Mehod is obsolete, and actually, It preseverd the name, only the type of paramaters changed.
    2- I'm targeting api 19

    Thanks!

  • BrendanZagaeskiBrendanZagaeski USForum Administrator, Xamarin Team Xamurai

    @EstebanGimbernat, I can confirm that TextToSpeech.Speak(string, QueueMode, IDictionary<string, string>) is correctly marked deprecated on API 21 in Xamarin.Android. (And the other overrides of Speak() are not marked as deprecated.)

    Unfortunately, when targeting Xamarin.Android to API 19, I'm also seeing that TextToSpeech.Speak(string, QueueMode, IDictionary<string, string>) is correctly not marked as deprecated.

    Given that result, if you get a chance the most direct way forward would probably be to submit a test case that shows the problem on a new bug report (if this link redirects to the top-level kb.xamarin.com/ page the first time you click it, try clicking it once more). I think there's a good chance you might be able to create a sufficient test case with the following steps:

    1. Make a copy of your original app project that shows the problem.

    2. Delete all the files from the project except for MainActivity.cs (or whichever file contains the "MainLauncher" activity) and AndroidManifest.xml.

    3. Add a dummy IOnInitListener implementation somewhere in the project:

      public class MyTextToSpeechOnInitListener : Java.Lang.Object, Android.Speech.Tts.TextToSpeech.IOnInitListener
      {
          public void OnInit(Android.Speech.Tts.OperationResult status)
          {
              throw new NotImplementedException();
          }
      }
      
    4. Add the following 2 lines to the MainActivity.OnCreate() override:

      var textToSpeech = new Android.Speech.Tts.TextToSpeech(this, new MyTextToSpeechOnInitListener());
      textToSpeech.Speak("Hello", Android.Speech.Tts.QueueMode.Add, null);
      

    (If you like, a slightly simpler way to provide a test case could be to delete the bin, obj, Components, and packages folders, and attach the whole solution folder for your app to the bug report, optionally marking the bug report "private" to restrict visibility to Xamarin.)

    Thanks again!

  • BradChaseBradChase USMember

    Brendan, When I have time I will upgrade again and send you what I believe you need. I just have to have some spare time to upgrade, limit the solution down to the bare essentials, and make sure I can still get the issue. Sorry I cant be of more help with it right now, but we will need to upgrade at some point here so it has to happen.

  • BrendanZagaeskiBrendanZagaeski USForum Administrator, Xamarin Team Xamurai
    edited May 2015

    No worries Brad. Thanks for the reports so far!

  • ErikArenhillErikArenhill SEMember ✭✭

    When will you look into the "Non-public Bug 28995 - [Android] On certain devices apps crash rarely due to "System.ExecutionEngineException: SIGILL"." - bug?

    It seems to affect all Samsung S6 devices. I can't even run the default android-application from a new project in Xamarin Studio without having the SIGILL crash. Our development has stalled since we're using hardware features (need to debug and test on real device) and only have an S6 Edge device..

  • BenjaminRushBenjaminRush USMember
  • BrendanZagaeskiBrendanZagaeski USForum Administrator, Xamarin Team Xamurai

    Thanks for the reports @ErikArenhill, @BenjaminRush. I have marked both of you as affected customers on the bug report to help increase its prioritization. Bug 28995 is currently set as a top priority for the next service release. Alpha channel versions of that new service release will be published after this current Alpha/Beta version is promoted to Stable (tentatively by the end of May).

  • BrendanZagaeskiBrendanZagaeski USForum Administrator, Xamarin Team Xamurai

    This thread has now been closed to direct all further updates about this service release onto the new Beta release thread:

    http://forums.xamarin.com/discussion/41665/beta-service-release-xamarin-android-5-1-2-bug-fixes-for-5-1-0/p1

    For anyone who has been commenting on this thread, feel free to continue the conversation in that new thread.

This discussion has been closed.