Bug 19390 - an element with the same key already exists in the dictionary. (XA0000)
Summary: an element with the same key already exists in the dictionary. (XA0000)
Status: RESOLVED NOT_REPRODUCIBLE
Alias: None
Product: Android
Classification: Xamarin
Component: Pre-release ()
Version: 4.13.x
Hardware: PC Windows
: Normal normal
Target Milestone: ---
Assignee: Jonathan Pryor
URL:
Depends on:
Blocks:
 
Reported: 2014-04-29 18:15 UTC by Ivan Godoy
Modified: 2017-06-27 00:17 UTC (History)
4 users (show)

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

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 or GitHub 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:
Status:
RESOLVED NOT_REPRODUCIBLE

Description Ivan Godoy 2014-04-29 18:15:44 UTC
Following the instructios for Release an Android APP, when I compile the solution in release mode, I get the error "an element with the same key already exists in the dictionary. (XA0000)" , what could be causing this? and how to solve it?

<Target Name="_Mandroid"
  DependsOnTargets="_BuildApkEmbed;_BuildApkBundle;_BuildApkFastDev"
  Inputs="$(MSBuildAllProjects);$(IntermediateOutputPath)android\bin\resources_and_assemblies"
  Outputs="$(ApkFile)">

  <Delete Files="$(ApkFileIntermediate)" Condition="Exists ('$(ApkFileIntermediate)')" />
  <Delete Files="$(ApkFile)" Condition="Exists ('$(ApkFile)')" />

  <Mandroid
		AndroidEmbedProfilers="$(AndroidEmbedProfilers)"
		Assemblies="$(OutDir)$(TargetFileName);@(ReferencePath)"
		I18nAssemblies="$(MandroidI18n)"
		UncompressedFileExtensions="$(AndroidStoreUncompressedFileExtensions)"
		BuildDirectory="$(MonoAndroidIntermediate)"
		ReferenceAssembliesDirectory="$(TargetFrameworkDirectory)"
		AndroidSdkDirectory="$(_AndroidSdkDirectory)"
		JavaSdkDirectory="$(_JavaSdkDirectory)"
		AndroidSdkPlatform="$(_AndroidApiLevel)"
		MonoAndroidToolsDirectory="$(_MonoAndroidToolsDirectory)"
		ResourceDirectory="$(MonoAndroidResDirIntermediate)"
		AssetDirectory="$(MonoAndroidAssetsDirIntermediate)"
		ManifestTemplate="$(_AndroidManifestAbs)"
		Package="$(_AndroidPackage)"
		NativeLibrary="@(AndroidNativeLibrary)"
		JavaSource="@(AndroidJavaSource)"
		Debug="$(AndroidIncludeDebugSymbols)"
		ExtraArgs="$(MandroidExtraArgs) $(MonoDroidExtraArgs)"
		SupportedAbis="$(AndroidSupportedAbis)"
		LinkMode="$(AndroidLinkMode)"
		UseSharedRuntime="$(AndroidUseSharedRuntime)"
		InputPackage="$(IntermediateOutputPath)android\bin\resources_and_assemblies"
		OutputPackage="$(ApkFileIntermediate)" />

  <Copy SourceFiles="$(ApkFileIntermediate)" DestinationFiles="$(ApkFile)" />

  <Delete Files="$(_UploadFlagFile)" Condition="Exists ('$(_UploadFlagFile)')" />
</Target>
Comment 1 Prashant manu 2014-05-01 02:22:37 UTC
We have checked and able to compile in release mode. 
Could you please provide us the test steps you followed. If possible please attach a small complete project that demonstrates this behavior.

Also can you please add the logs from the following places?:
On XS IDE Log  Location: XS>Help> Open Log Directory> IDE.log file (with latest timestamp)
AndroidTools log: XS->Help->Open Log Directory->AndroidTools.log

If using VS, 
IDE log: Location: C:\User\AppData\Local\Xamarin\Log\ 
(Devenev file with latest timestamp)
Android Trace log: Location: \AppData\Local\Xamarin\Log\XamarinAndroid

This will help us efficiently confirm and fix this bug.
Comment 4 Chris Hardy [MSFT] 2017-06-26 18:58:11 UTC
Unfortunately, we’re unable to reproduce this report. If this issue is still occurring for you, please reopen this issue and attach a reproduction to the bug by starting with a clean Xamarin.Android project adding just the code necessary to demonstrate the issue.