Bug 34576 - Resource.designer.cs throws "can not find definition for..." exception
Summary: Resource.designer.cs throws "can not find definition for..." exception
Status: CONFIRMED
Alias: None
Product: Android
Classification: Xamarin
Component: General (show other bugs)
Version: 5.2
Hardware: Macintosh Mac OS
: --- normal
Target Milestone: ---
Assignee: dean.ellis
URL:
Depends on:
Blocks:
 
Reported: 2015-10-05 20:20 UTC by Ian Geoghegan
Modified: 2015-10-12 15:41 UTC (History)
10 users (show)

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


Attachments
Xamarin Studio logs (60.98 KB, application/zip)
2015-10-07 20:01 UTC, Kent Green [MSFT]
Details


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 for Bug 34576 on Developer Community or GitHub if you have new information to add and do not yet see a matching new report.

If the latest results still closely match this report, you can use the original description:

  • Export the original title and description: Developer Community HTML or GitHub Markdown
  • Copy the title and description into the new report. Adjust them to be up-to-date if needed.
  • Add your new information.

In special cases on GitHub you might also want the comments: GitHub Markdown with public comments

Related Links:
Status:
CONFIRMED

Description Ian Geoghegan 2015-10-05 20:20:29 UTC
Hi. I upgraded to 1.5 and then the 1.5.1 pre-release and the bug exists with both. Multiple definitions exceptions are thrown and project no longer compiles. In addition, updating various packages upon which the package depends (CardView, AppCompat) to comparable pre-release builds does nothing to ameliorate the bug. Nor does deleting bin and obj directories.
Comment 1 Jonathan Pryor 2015-10-06 17:42:41 UTC
Please provide reproduction instructions.
Comment 2 Ian Geoghegan 2015-10-07 11:17:54 UTC
Jonathan, I have created a demo solution with all the packages, assemblies, etc. that I have in my own solution that cause the meltdown. I have confirmed that this demo results in the same bug and have posted the whole thing to my google drive. You can find it here:

bit.ly/1OY55Uu
Comment 3 Kent Green [MSFT] 2015-10-07 20:01:01 UTC
Created attachment 13234 [details]
Xamarin Studio logs

I was able to reproduce the issue with the sample provided in comment 2. Building the sample throws 78 errors, all seem to be of the form:

> .../Resource.designer.cs(115,115): Error CS0117: `ResourceIssueRepro.Droid.Resource.Animation' does not contain a definition for `fab_in' (CS0117) (ResourceIssueRepro.Droid)

Attaching the logs from my reproduction of the issue.
Comment 6 dean.ellis 2015-10-12 07:55:12 UTC
This looks like a package dependency issue. I downgraded the Xamarin.Forms component from the -pre release (which is what the project was using) to the latest stable (1.5.0.6447) as well as the Xamarin.Forms.Maps component (1.5.0.6447) and the project now compiles successfully. 

I think the pre-release version has been built against slightly different versions of Xamarin.Android.Support.Design.. The latest version of that package however does NOT contain resources such as fab_in ... in fact a grep of the entire google package which was downloaded shows that fab_in.xml does not exist (or any other kind of resource called fab_in .. the only reference is design_fab_in.xml. I'm not 100% sure but it looks like google renamed or removed something in the new design stuff (which is not unusual).
Comment 7 Rui Marinho 2015-10-12 09:11:03 UTC
Xamarin.Forms 1.5.1-pre1 depends on Xamarin.Android.Support version 22 , so all support libs should not be upgraded to the latest version (v23) if using Xamarin.Forms 1.5.1-pre1 .

Removing all Xamarin.Android.Support packages and Xamarin.Forms and installing Xamarin Forms 1.5.1-pre1 nuget again should install the correct versions on the Android project.
Comment 8 Ian Geoghegan 2015-10-12 15:41:45 UTC
@Rui Marinho
That didn't work out.

@dean.ellis@xamarin.com
Still trying to massage this configuration; no luck yet but still midstream.