.NET for Android error XA4239

Example message

error XA4239: Unknown Maven repository: 'example.com'.

Issue

The specified Maven repository is invalid.

For example the following Maven repository must be specified with https://:

<ItemGroup>
  <AndroidMavenLibrary Include="com.example:mylib" Version="1.0.0" Repository="example.com" />
</ItemGroup>

Solution

To resolve this error, ensure that the Maven repository follows the documented values:

<ItemGroup>
  <AndroidMavenLibrary Include="com.example:mylib" Version="1.0.0" Repository="https://example.com" />
</ItemGroup>