As a part of the Visual Studio 2017 UWP build process, an app called MakePri.exe is run. It is throwing an error in my project but I have no idea why. The command line call is:
C:\Program Files (x86)\Windows
Kits\10\bin\10.0.16299.0\x64\MakePri.exe New -ProjectRoot
C:\AdaptSource\src\Xivic\Adapt.Presentation.XamarinForms\Adapt.Presentation.Xivic.UWP\
-ConfigXml obj\x86\Debug\priconfig.xml -OutputFile C:\AdaptSource\src\Xivic\Adapt.Presentation.XamarinForms\Adapt.Presentation.Xivic.UWP\bin\x86\Debug\resources.pri
-IndexName AdaptSolutionsPty.Ltd.Xivic-Helpdesk -Verbose -Overwrite
The error that it returns is:
error PRI175 : 0x80073b0f - Processing Resources failed with error :
Duplicate Entry.
GENERATEPROJECTPRIFILE : error PRI277: 0xdef00532 - Conflicting values
for resource ''
I have no idea what it is talking about. There is no useful information in the error message. After sifting through a lot of google results, I see that the problem seems to come up when there are references to certain or duplicate DLLs in referenced .NET Standard / PCL projects.
For example:
https://forums.xamarin.com/discussion/103956/strange-build-error-xamarin-uwp
UWP unit test compile errors
But in other threads, at least people are getting a resource name to work with. I've removed as many references as I can. I've used resharper to help. I really need to get a useful error message out of MakePri. Does anyone know anything about this? Is there a way to see what it is stumbling on?
Edit: The issue was that my solution was using two versions of Xamarin.Forms. Once I consolidated the NuGet packages, the problem went away. But, I feel like this is a bug because the error message should be more descriptive. It wastes a lot of time. So, I've logged the issue here:
https://github.com/dotnet/buildtools/issues/1912
I'll leave this open until there is some kind of response at Microsoft.
Consolidate both Xamarin.Forms and Microsoft.NETCore.UniversalWindowsPlatform version for all the dependency projects will resolve the issue. It is mainly due to the Xamarin.Forms latest stable version requires higher version of Microsoft.NETCore.UnivesalWindowsPlatform nuget i.e.,(6.0.1).
The message is missing a piece, may caused by 16299 sdk
please try use 15063 and you may get the right key
I had the same problem, with the exact same error message. My fix was different than yours.
By deleting resources one at a time, until the build succeeded, i found the cause to be in one of my language .resw files I had forgotten to append .Text to the name.
Language A:
"Message.Text", "Hello world"
Language B:
"Message", "Hello world"
This oversight gave me the error you mention in the heading.
The fix for me was to append .Text so the names are identical.
Related
I started encountering this issue about 3 days ago after an update that I randomly clicked on when I was in Visual Studio Code. Whenever I try to access HttpRequest.Query from the Microsoft.AspNetCore.Http namespace, I get an the following error message: "Entry Point was not found".
I have not been unable to fix this and this has interrupted my ability to work. I've talked this over with my teammates, and they are not encountering this issue at all.
I've tried pretty much everything I could google and think of.
Auto Generating Bindings
Deleted and re installed every Nuget Package at C:\Users{username}.nuget\packages
Deleting and reinstalling everything about Visual Studio and Visual Studio Code
Using the most recent versions of Microsoft.NET.Sdk.Functions
Deleting the bin and obj folders of my project
Removing unused references in my project
At this point, I'm not even sure what's really wrong any more. I found a post with my EXACT SAME issue, but the way the person fixed it did not apply to me:
Azure Functions .NetCore 3.0 Request.Query throwing "Entry point not found" error
Some Info- may or may not be useful.
When I go through the code step by step in the debugger, HttpRequest.Query shows up properly with all of the keys. I'm wondering if there is some kind of name conflict between HttpRequest object from Microsoft.AspNetCore.Http vs System.Web
If I set my project to use the most recent version of Microsoft.NET.Sdk.Functions, I get a new error instead of an entry point error, I get this instead:
I'm using Visual studio Code.
Can anyone assist? I'd be happy to provide any information needed!
I gave up. I spent about 3 days trying to solve this and this was affecting my ability to work. I just had my entire laptop reformatted and that "fixed" the issue. I tried pretty much everything I could find and nothing worked and I couldn't wait any more. Best of luck to anyone who encounters this!
Our team has been working on some UWP apps for some time now, recently after updating some nugget packages on any Rebuild of the project we get errors similar to this:
File=MakePri: Processing Resources failed with error: Duplicate Entry.
File=MakePri: Conflicting values for resource 'ExceptionStringTable/NameScopeNameNotFound'
There are similar questions on SO that are caused either by user created/managed resources or that are simply fixed by cleaning the project outputs and/or rebuilding.
This is different to other questions around MakePri and resource duplicate entries on SO because these resources that have conflicts are not provided or managed by any of my application code. Therefor I cannot simply remove the duplicate entry in my code.
The problem is that there are two resource files in the output that have duplicate entries. Mind you it's not a duplicate file, just a small handful of entries exist in both of these files:
\obj\ARM\Debug\System.Xaml\en-US\ExceptionStringTable.resw
\obj\ARM\Debug\WindowsBase\en-US\ExceptionStringTable.resw
My Question, is there a way in VS ALM to smartly either ignore these errors, or fix the duplicate entries before/during compilation? Further, has anyone else noticed this issue and is there a better way to resolve it? I suspect messing around with NuGet package versions might help but I'm keen to see what the rest of the community has to say before I spend much more time on this.
Turns out, you cannot simply delete these files, if you do so the next build will put them back, but what you can do is edit the files to remove the entries. Then the file will remain until the project outputs are cleared.
I'm not going to list the conflicts, we found them through trial and error and then after a while got lazy and removed whole chunks from these resources.
The consequences of this action is that now if an exception is raised and it's message string was one of those resources we carelessly removed, I have to google the exception code if I'm not already familiar with it. That took some getting used to :)
As I said, I suspect versions of NuGet packages could be to blame. But I'm not sure where System.Xaml.dll comes from. Surely the good guys as MS on the WindowsBase and XAML teams must be aware of this conflict and I'm hoping that it gets resolved in the future. Which is why I'm looking for a low effort solution
WindowsBase: \.NETFramework\v4.6.1\WindowsBase.dll
PM> Install-Package Microsoft.NETCore.UniversalWindowsPlatform (v5.3.1)
Our current solution is to replace the XAML version of the ExceptionStringTable.resw file with one that we previously edited and saved back to the solution root. It's an annoying process that I often forget.
Has anyone else experienced this and found a better solution?
I'm trying to run a .NET MVC application on my local computer that I got from GitHub.
When I hit run on Visual Studio, everything complies and a new browser window opens with the error:
CS1980: Cannot define a class or member that utilizes 'dynamic' because the compiler required type 'System.Runtime.CompilerServices.DynamicAttribute'
The compiler section in the same window, shows the following error:
I've checked on google and this seems to be the same error.
This guy was using a dynamic type himself, on the other hand I'm not using any dynamic type, this is being auto generated by .NET's compiler, and I'm using .net 4.5 which should has support for dynamics.
I tried to apply the same solution (Changing all System.Core references to 4.0)
but the thing is that all of them are version 4.0 already.
Do you have any idea how could I resolve this?
I had a similar error on a project I was trying to migrate. Try re-targeting the framework of the project back a version or two, and once you find a target version where you do not get the error, re-target back to the version you originally had trouble with.
I was getting the same error on a website project targeted for 4.6.2 that was referencing some older libraries, re-targeted it back to 4.5.1 and that resolved the error. I immediately re-targeted back to 4.6.2 and did not encounter the error again.
I had this same issue, but none of the answers here solved it, but did point me in the right direction. I think I didn't update the .NET version on my machine to the newer one. After installing it, I rolled back the targeted framework (as was suggested), retargeted the newer framework, and did a few extra things also:
Reinstalled ALL packages by running this in the package manager:
update-package -reinstall
I also compared my project to one that was working for 4.5 and did this:
Opened my project file and removed all "BCL" related elements.
Uninstalled all "BCL" packages in the NuGet package manager for the project (guess it's not needed moving to 4.5+...?)
Removed an old package version of System.Net.Http, which did not get updated for some reason (see web.config - versions should show oldVersion="0.0.0.0-4.0.0.0" newVersion="4.0.0.0").
Have to restart VS.
Rebuild solution.
Error is now gone. ;)
One other thing I did to resolve some other errors was to clear the component cache by deleting all files in here:
C:\Users\{USERNAME}\AppData\Local\Microsoft\VisualStudio\14.0\ComponentModelCache\
[rant] Wasted a whole day with all this. Thanks to MS for stealing one more day of my life fixing senseless issues that should never be. Every time I upgrade I always get a wonderful surprise, and a lovely game of fix the red herring. Would it not hurt to detect these conflicts for those upgrading old projects? Perhaps better error traces when things go wrong? I doubt it would be that difficult. Perhaps even something like AsmSpy, but more advanced, built in to VS? [/rant]
Saw this in VS 2019. I excluded and re-included the problematic file (in my case _Layout.cshtml) and that fixed the problem.
I got this error suddenly a couple days after updating to VS2015.3 using 'traditional' MVC app (not new .NET Core / vNext app).
Turns out this error can be a complete red herring.
Make sure:
You haven't got any other errors at all
You've checked the output window for any errors that don't show in the 'Output' window.
Make sure you don't have any conflicting references
In my case I had a typescript error that was causing an error and for some reason triggering this weird 'red herring' dynamic error too.
My fix was to go into the .csproj file and update the typescript tools version to 1.8 (need to unload project and edit by hand). As I said this is unrelated to the error, but I mention the specifics because someone else may end up with this same problem.
I believe that 1.7 didn't accept 'None' for the typescript module system whereas 1.8 does, hence the error.
Adding a reference to System.Dynamic.Runtime did it for me.
I hesitate to write this as an answer, but for me the error appeared in a .cshtml file. I closed the page, rebuilt, and the error vanished. Always best to try the simple things first.
I had the same error, there were just 2 unused tables of my databaseset that I had to delete. I wonder why it worked when I manually change sth in an auto-generated code work but after deleting, it worked.
So be aware that such inconsistencies can also cause this error.
My solution was to correct the version of MVC in web.config under Views folder. E.g. the project referenced MVC assembly version 5.2.2.0 but in the Views/web.config file was version 5.2.4.0 (see image).
Image
Tried a few other answers with no luck, but the overall consensus appears to be that this some sort of issue with cached build artifacts or compiler state or something. Here's what worked for me:
Delete the problem .cshtml file, watch error disappear
Open source control and revert the deletion
This error will come because of the different versions of your Sitecore.Web.Mvc.Dll in solution reference folder(Project name->References->Sitecore.Web.Mvc->right click and check properties) and the version of Sitecore.Web.Mvc.Dll in Web.Config in views Folder.
For solving this error you have to make sure that the version of Sitecore.Web.Mvc.Dll is same in both folders.
Thanx.
For my case, I fixed to run the command line "update-package -reinstall" on the Package Manager Controler.
My problem was in the _Layout.cshtml.
None of the solutions above did the trick for me. I am using VS2017 for this project, upgraded an ran into the same message.
I had commented out a 2 lines in 1 comment #* *#
My solution was to comment out each line separately. What a mystery!
A few hours lost on this.
Last year an ex-employee pushed a Visual Studio project to our GitBlit repository, but once I checked it out and tried to compile it, it says
Error 51 Metadata file 'D:\GIT\epimst\MSTDAO\bin\Debug\MSTDAO.dll' could not be found D:\GIT\epimst\EPIMST\CSC EPIMST
Error 47 Metadata file 'D:\GIT\epimst\EPIDAO\bin\Debug\EPIDAO.dll' could not be found D:\GIT\epimst\epiapputils\CSC epiapputils
Error 48 Metadata file 'D:\GIT\epimst\EPIDAO\bin\Debug\EPIDAO.dll' could not be found D:\GIT\epimst\MSTDAO\CSC MSTDAO
Error 50 Metadata file 'D:\GIT\epimst\EPIDAO\bin\Debug\EPIDAO.dll' could not be found D:\GIT\epimst\EPIMST\CSC EPIMST
So my solution was to copy these DLLs from our deployed software and simply copy them back into their various directories. This fixed the 'count not be found' errors, but then a host of undefined code errors came up.
Seeing as how this code did work at some point and the live packages still function, I cant figure out what went wrong between the code being checked in and eventually checked out by me.
Unfortunately we cant get in touch with that one employee that pushed up the code, and I've spent a few days reading about changing target frameworks, output options, build settings, etc, but none of them fix the dependencies problems or missing DLLs.
We are almost positive the DLLs are from the same version as we only released one version of the software, but somehow the source code no longer works.
I notice that you are listing the errors out of sequence. This suggests that you have made a common mistake which is especially critical when bringing up a solution in a new environment:
You are reading the tabular "Error List" window rather than the compiler output.
This is bad for two reasons:
The compiler output contains additional information related to the compile and often related to the errors. But all non-error messages get stripped by the IDE and don't appear in the "Error List" window.
The first messages are the most important, because later errors are often side effects of the first few.
Switch to the "Output" window, make sure the setting is "Show output from: Build", scroll to the top, and start addressing errors in the order of occurrence.
The most likely possibility is that the coder forgot to check in one file, resulting in errors in that project where other files used that class. Then since that project didn't build, all the dependent projects can't find anything that's contained in that or any other dependent project, resulting in hundreds of errors. Which is really hard to sort out in the Error List, but perfectly clear when you switch to the actual Build Output log.
I have used windows store apps 8.0 in my project and upgraded it to be 8.1. And also upgraded Visual Studio from 2012 to 2013.
First, I got an error that cannot use the Microsoft.VCLibs Version 11.0 and 12.0. So I removed the 11.0 version.
And then I got this errors:
I tried to find some information on the internet, but nothing.
Also when I double clicked on the error it doesn't bring me to the error's spot.
I have tried to do many things, and nothing helped, so I decided to write this post.
Can someone help me resolve this errors?
EDIT:
I am adding some more information, maybe this can lead to the problem:
Solved:
With the help of Hans Passant the errors have fixed. The problem was that I had this duplicate on my resource file:
I did it twice because one is for buttons (that has content), and one is for message dialogs on code behind.
In Visual Studio 2012 this code was working fine, but somehow, not in Visual Studio 2013.
I deleted the row of Cancel.Content and the errors disappeared and it works fine :)
Here is somebody else with the same problem.
I'll just copy Caplan's guidance. Look through the .resw file(s) in your project and look for a duplicated "Cancel" resource. I should note that intentionally forcing a duplicate resource produced another message when I built the program on VS2013:
1>MakePri : error 0x80073b0f: Processing Resources with error: Duplicate Entry.
1>MakePRI : error 0xdef00532: Conflicting values for resource 'Resources/String1'
Same message from either duplicating the resource in the same .resw file and by making a copy of the .resw file and adding it to the project. So Caplan's explanation isn't exactly a slam-dunk. I'd pay attention to other projects in your solution that might also have a resource named "Cancel". A likely scenario when your solution has a dependency on VCLibs, that sounds like you are mixing C# and C++/CX.
I came across this MSDN URL which seemed to be pretty helpful.
2 snippets in particular you could try:
You could actually have a duplicate resource entry in your project file.
Your obj files could have become corrupt, you need to clear out your obj files (although I haven't seen this problem for a while in my
team - it might be fixed in 2008).
If you are using a custom culture, perhaps with the .Net RegisterCulture method, ensure that the culture has been registered on
your computer. If you've reinstalled your OS and installed VS2008 and
you can't build due to this problem it could be because you need to
register your custom cultures before you build. This error seems to
be thrown when msbuild cannot find the culture.
Alternatively:
PS - There is also a Visual Studio 2012 Update 3 available that could possibly help?
Visual Studio 2012 Update 3
I hope this helps.
A similar error can also occur if you update a Nuget package in one project, but not in another dependent project also using the same Nuget package.
i.e. it can be a version mismatch error when referencing different versions of a dependency across two dependent projects.
I don't know if you have tried re-installing VS 2013, I was getting the same error but it was resolved when I re-installed.
In my case, after retargeting a working Win8 App for Win81 App, was UI string. Imho it is correct but soehow the VS2013 has some problems with it.
Locations SomeString
Locations.Text SomeStringForUI
Removing the one of them solved my problem.
Recently i got a similar build exception on my UWP Project
MakePri : error 0x80073b0f: Processing Resources failed with error: Doppelter Eintrag.
MakePRI : error 0xdef00532: Conflicting values for resource 'System.Design/ClassComments1'
I found a lot of information about the error but no solution. It looks like the error must be in the entry application project but it isn't.
In my case the VS integrated automaticly a reference to System.Activities because a made a mistake.
After i deleted the wrong reference, it works fine again.
Got this error in a UWP Xamarin.Forms project when a fellow developer referenced System.Web in a PCL that the Xamarin.Forms PCL references.
For more info:
Add System.Web Reference To A Windows 10 Universal App