Bug 52518 - Android workbook is unable to connect to the VS Android Emulator
Summary: Android workbook is unable to connect to the VS Android Emulator
Alias: None
Product: Workbooks & Inspector
Classification: Xamarin
Component: Agent: Android ()
Version: 1.2.2
Hardware: PC Windows
: --- normal
Target Milestone: 1.3
Assignee: xamarininteractive
Depends on:
Reported: 2017-02-15 01:52 UTC by Mark McLemore
Modified: 2017-08-29 14:27 UTC (History)
3 users (show)

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

Xamarin interactive log (51.93 KB, text/x-log)
2017-02-15 01:52 UTC, Mark McLemore

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:

Description Mark McLemore 2017-02-15 01:52:20 UTC
Created attachment 19822 [details]
Xamarin interactive log

I've installed XamarinInteractive.msi (from today's link in Slack, #docs channel) on Windows (has Visual Studio 2015, Android SDK, and Visual Studio Android Emulator installed). Next I loaded up the following on Windows 10 (has Visual Studio 2015 installed):


It starts the emulator without any problems, but at the bottom of the Workbook I get the error "Unable to connect". Clicking the "Reconnect" button retries but ends up with the same error. Same results if I start the VS Android Emulator before starting up the Workbook.  I also tried updating the VS Android Emulator to the latest version, but no difference.

I've retrieved the log from %LOCALAPPDATA%/Xamarin/Inspector/Logs and attached it to this bug.
Comment 1 Bojan Rajkovic [MSFT] 2017-02-15 03:33:36 UTC
Is there an existing Workbooks app on the emulator already? Can you delete it, if so? 

I'm seeing INSTALL_FAILED_UPDATE_INCOMPATIBLE in your log, which suggests there's some incompatibility between an installed version of the app and the one we're trying to deploy.

Not sure _why_ that would be the case, but…Android?
Comment 2 Sandy Armstrong [MSFT] 2017-02-15 04:17:32 UTC
This is a known issue when switching between debug and release builds. Perhaps it somehow also occurs with the custom installer Bojan made?

I do not believe we typically have this issue when changing the installed version with official installers.
Comment 3 Bojan Rajkovic [MSFT] 2017-02-15 04:19:48 UTC
Yeah, that's what I was thinking as well. My Windows installer was built in Release mode, but it could be any number of factors when using a custom drop.
Comment 4 Sandy Armstrong [MSFT] 2017-02-15 04:20:03 UTC
Looks like it could be related to the key used to sign the apk, which would differ between the official build machine and Bojan's machine?
Comment 5 Sandy Armstrong [MSFT] 2017-02-15 04:21:19 UTC
Perhaps we should check for this error, and when it occurs, run `adb uninstall whatever.the.package.id.is` and try again.