34

I'm trying to compile my Xamarin Forms Android app on iOS. However I keep running into an error:

[db] _LSSchemaConfigureForStore failed with error Error Domain=NSOSStatusErrorDomain Code=-10817 "(null)" UserInfo={_LSFunction=_LSSchemaConfigureForStore, ExpectedSimulatorHash={length = 32, bytes = 0x35effaa3 2bab3fa8 68f8c96b cd17d15e ... 9bf8f6b7 fd486754 }, _LSLine=405, WrongSimulatorHash={length = 32, bytes = 0xe14e0f7b 39a9580e 8e4762c4 846107dc ... 21618def 3c69a5ae }}

[db] Failed to initialize client context with error Error Domain=NSOSStatusErrorDomain Code=-10817 "(null)" UserInfo={_LSFunction=_LSSchemaConfigureForStore, ExpectedSimulatorHash={length = 32, bytes = 0x35effaa3 2bab3fa8 68f8c96b cd17d15e ... 9bf8f6b7 fd486754 }, _LSLine=405, WrongSimulatorHash={length = 32, bytes = 0xe14e0f7b 39a9580e 8e4762c4 846107dc ... 21618def 3c69a5ae }}

These 2 lines will repeat about 20 times.

I am compiling on a MacBook Air 2020 with the M1 chip.

I have tried debugging the app on a colleague's iPhone, which doesn't cause this error and works just fine.

Gero
  • 4,394
  • 20
  • 36
Tygo
  • 441
  • 1
  • 4
  • 3
  • 1
    Same problem :( – Shivani Bajaj Jan 07 '21 at 12:01
  • 1
    Also facing the same problem :( – Adrienne Jan 08 '21 at 18:32
  • To clarify: This log output comes from the compilation, or the start-up of the app on the simulator? I am unfamiliar with Xamarin, but to me it looks like it just doesn't find the correct/expected simulator to start. I assume that comes after the app hass been successfully built. Also, while it might be M1 related, I think the question title is a little misleading, so you might want to change that (no idea how, though, sorry). – Gero Jan 12 '21 at 10:13
  • @Gero This is the application output running on the iPhone Simulator on an M1 chip MacBook. When debugging on a physical iPhone, these errors do not occur. – Tygo Jan 13 '21 at 15:00
  • Hm, unfortunately that means I won't be able to help then. A quick search leads me to this: https://stackoverflow.com/q/65287834/710041. Appears you're not alone with this phenomenon. They don't mention Xamarin, so my assumption would be that it's indeed an M1 related bug in Apple's stuff. Perhaps some private framework gets confused by the new architecture (as the simulator is now arm64 and not x86_64), but that's just guessing here. You might want to play around with the architecture settings (no idea how to do so with Xamarin), but my bet is Apple needs to fix this, ultimately. – Gero Jan 14 '21 at 07:29

2 Answers2

8

Using a simulator on iOS 13.7 is working for me, but that's obviously a workaround.

To install:

  1. Window -> Devices and Simulators
  2. click Simulators
  3. click the "+" in the lower left corner click plus button
  4. install 13.7

select OS version

froggomad
  • 1,747
  • 2
  • 17
  • 40
-5

You can add OS_ACTIVITY_MODE = disable in the Environment Variables's Arguments

Product -> Edit Schema -> Run -> Arguments

Adi Nugroho
  • 860
  • 10
  • 12