1

Closed

ArgumentException in VS

description

One of my solutions is making the Roslyn bits throw fits in VS2013. I've attached the solution code, hopefully this can be reproduced. Seems like it may be related to just viewing some files, but building the solution always reproduces the crash.

This is all I get from VS for information:

System.ArgumentException was unhandled
Message: An unhandled exception of type 'System.ArgumentException' occurred in Microsoft.CodeAnalysis.Workspaces.dll
Additional information: An item with the same key has already been added.

file attachments

Closed Apr 11 at 7:06 PM by srivatsn
Thanks for reporting this issue. This is a dupe of https://roslyn.codeplex.com/workitem/52 and has already been fixed.

comments

ggeslin wrote Oct 1 at 1:07 PM

Hello,

Does RoslynPreview contains the fix for this bug ?
We can't work on one of our solutions when Roslyn Preview is enabled and we face the same exception.

We use VS Premium 2013 with Roslyn Preview v0.6.40331.3.

First, the ArgumentException was thrown while solution was loading.
We deleted some duplicates "SuppressMessage" attributes in our GlobalSuppress.cs files.

Now the solution loading finished well but the ArgumentException is still thrown later.

Thank you.

srivatsn wrote Oct 3 at 5:00 AM

This fix is contained in the VS "14" CTPs. We are not planning to release previews on top of VS 2013 anymore. The RoslynPreview does not contain this bug fix.