Open ArchieCoder opened 8 months ago
@jasonmalinowski something to do with generated files probably?
@CyrusNajmabadi @jasonmalinowski Here is my example just now. I'm not doing anything fancy. Duplicate a line and type new letters.
I get this experience 10-15 times a day for weeks.
Please file the stacks you're running into. We're fixing the issues reported.
I suspect this issue will be heavily mitigated in 17.10 Preview 1 by #68214
@ArchieCoder If you can give 17.9.0 a shot, we just shipped it a few minutes ago. One possible cause of the stack you posted is fixed in it (but hard to say without trying it).
Installing! I will report back my new stack traces if any. Thanks for the fast update.
I have same problem on 17.9 and 17.10 Preview. It is happenig always after I uupdate and add SDK
StreamJsonRpc.RemoteInvocationException: Can't create a reference to a module.
at StreamJsonRpc.JsonRpc.<InvokeCoreAsync>d__151`1.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at Microsoft.CodeAnalysis.Remote.BrokeredServiceConnection`1.<TryInvokeAsync>d__21.MoveNext()
RPC server exception:
System.NotSupportedException: Can't create a reference to a module.
at Microsoft.CodeAnalysis.CompilationReference.GetProperties(Compilation compilation, ImmutableArray`1 aliases, Boolean embedInteropTypes)
at Microsoft.CodeAnalysis.CSharp.CSharpCompilation.ToMetadataReference(ImmutableArray`1 aliases, Boolean embedInteropTypes)
at Microsoft.CodeAnalysis.SolutionCompilationState.CompilationTracker.GetPartialMetadataReference(ProjectState fromProject, ProjectReference projectReference)
at Microsoft.CodeAnalysis.SolutionCompilationState.CompilationTracker.GetPartialCompilationState(SolutionCompilationState compilationState, DocumentId id, ProjectState& inProgressProject, CompilationPair& compilations, CompilationTrackerGeneratorInfo& generatorInfo, Dictionary`2& metadataReferenceToProjectId, CancellationToken cancellationToken)
at Microsoft.CodeAnalysis.SolutionCompilationState.CompilationTracker.FreezePartialStateWithTree(SolutionCompilationState compilationState, DocumentState docState, SyntaxTree tree, CancellationToken cancellationToken)
at Microsoft.CodeAnalysis.SolutionCompilationState.WithFrozenPartialCompilationIncludingSpecificDocument(DocumentId documentId, CancellationToken cancellationToken)
at Microsoft.CodeAnalysis.Document.WithFrozenPartialSemantics(CancellationToken cancellationToken)
at Microsoft.CodeAnalysis.DesignerAttribute.DesignerAttributeDiscoveryService.ProcessProjectAsync(Project project, Document specificDocument, Boolean useFrozenSnapshots, ICallback callback, CancellationToken cancellationToken)
at Microsoft.CodeAnalysis.DesignerAttribute.DesignerAttributeDiscoveryService.ProcessSolutionAsync(Solution solution, DocumentId priorityDocumentId, Boolean useFrozenSnapshots, ICallback callback, CancellationToken cancellationToken)
at Microsoft.CodeAnalysis.Remote.BrokeredServiceBase.<>c__DisplayClass16_0.<<RunServiceAsync>b__1>d.MoveNext()
--- End of stack trace from previous location ---
at Microsoft.CodeAnalysis.Remote.RemoteWorkspace.<>c__DisplayClass9_0`1.<<RunWithSolutionAsync>g__ProcessSolutionAsync|1>d.MoveNext()
--- End of stack trace from previous location ---
at Microsoft.CodeAnalysis.Remote.RemoteWorkspace.RunWithSolutionAsync[T](AssetProvider assetProvider, Checksum solutionChecksum, Int32 workspaceVersion, Boolean updatePrimaryBranch, Func`2 implementation, CancellationToken cancellationToken)
at Microsoft.CodeAnalysis.Remote.RemoteWorkspace.RunWithSolutionAsync[T](AssetProvider assetProvider, Checksum solutionChecksum, Int32 workspaceVersion, Boolean updatePrimaryBranch, Func`2 implementation, CancellationToken cancellationToken)
at Microsoft.CodeAnalysis.Remote.BrokeredServiceBase.RunWithSolutionAsync[T](Checksum solutionChecksum, Func`2 implementation, CancellationToken cancellationToken)
at Microsoft.CodeAnalysis.Remote.BrokeredServiceBase.<>c__DisplayClass16_0.<<RunServiceAsync>b__0>d.MoveNext()
--- End of stack trace from previous location ---
at Microsoft.CodeAnalysis.Remote.BrokeredServiceBase.RunServiceImplAsync(Func`2 implementation, CancellationToken cancellationToken)
17.9 after uupdate
@kubakorecek that seems entirely unrelated. Can you file a new issue with your repro project?
I filed https://github.com/dotnet/roslyn/issues/72183 for @kubakorecek's issue since I think I recognize this one.
@CyrusNajmabadi SUure, but i fix it by actually restarting whole computer. So basiccally it seems to have this problem only until first hard restart... so i guess i will leave it.
Latest VS version. Exception happens while coding.