Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug: Metalama doesn't like it when Resharper updates namespaces #335

Open
WhitWaldo opened this issue Jul 19, 2024 · 1 comment
Open

Bug: Metalama doesn't like it when Resharper updates namespaces #335

WhitWaldo opened this issue Jul 19, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@WhitWaldo
Copy link

WhitWaldo commented Jul 19, 2024

I copied several files from one project to another and then used Resharper to update the namespaces of the copied files. This immediately threw an exception as follows:

Metalama Application: Metalama.DesignTime
Metalama Version: 2024.2.16-rc
Runtime: .NET 8.0.7
Processor Architecture: X64
OS Description: Microsoft Windows 10.0.19045
OS Architecture: X64
Exception type: System.InvalidOperationException
Exception message: The old syntax tree is no longer alive.
===== Exception =====
System.InvalidOperationException: The old syntax tree is no longer alive.
at Metalama.Framework.DesignTime.Pipeline.Diff.SyntaxTreeChange.get_OldSyntaxTreeVersionDangerous()
at Metalama.Framework.DesignTime.Pipeline.Diff.SyntaxTreeChange.Merge(SyntaxTreeChange& newChange)
at Metalama.Framework.DesignTime.Pipeline.Diff.ProjectVersionProvider.Implementation.MergeCompilationChangesAsync(CompilationChangesHandle firstHandle, CompilationChanges second, TestableCancellationToken cancellationToken)
at Metalama.Framework.DesignTime.Pipeline.Diff.ProjectVersionProvider.Implementation.MergeReferencedProjectChangesAsync(ReferencedProjectChange first, ReferencedProjectChange second, TestableCancellationToken cancellationToken)
at Metalama.Framework.DesignTime.Pipeline.Diff.ProjectVersionProvider.Implementation.MergeCompilationChangesAsync(CompilationChangesHandle firstHandle, CompilationChanges second, TestableCancellationToken cancellationToken)
at Metalama.Framework.DesignTime.Pipeline.Diff.ProjectVersionProvider.Implementation.GetCompilationChangesAsyncCoreAsync(Compilation oldCompilation, Compilation newCompilation, TestableCancellationToken cancellationToken)
at Metalama.Framework.DesignTime.Pipeline.Diff.ProjectVersionProvider.Implementation.GetCompilationVersionCoreAsync(Compilation oldCompilation, Compilation newCompilation, TestableCancellationToken cancellationToken)
at Metalama.Framework.DesignTime.Pipeline.Diff.ProjectVersionProvider.GetCompilationVersionAsync(Compilation oldCompilation, Compilation newCompilation, TestableCancellationToken cancellationToken)
at Metalama.Framework.DesignTime.Pipeline.DesignTimeAspectPipeline.GetDesignTimeProjectVersionAsync(Compilation compilation, Boolean autoResumePipeline, AsyncExecutionContext executionContext, TestableCancellationToken cancellationToken)
at Metalama.Framework.DesignTime.Pipeline.DesignTimeAspectPipeline.ExecuteAsync(Compilation compilation, Boolean autoResumePipeline, AsyncExecutionContext executionContext, TestableCancellationToken cancellationToken)
at Metalama.Framework.DesignTime.Pipeline.DesignTimeAspectPipeline.ExecuteAsync(Compilation compilation, Boolean autoResumePipeline, AsyncExecutionContext executionContext, TestableCancellationToken cancellationToken)
at Metalama.Framework.DesignTime.AnalysisProcessProjectHandler.ComputeAsync(Compilation compilation, TestableCancellationToken cancellationToken)
at Metalama.Framework.DesignTime.AnalysisProcessProjectHandler.ComputeAndPublishAsync(Compilation compilation, TestableCancellationToken cancellationToken)
at Metalama.Framework.DesignTime.Utilities.TaskBag.<>c__DisplayClass4_0.<b__0>d.MoveNext()

Unfortunately, it then proceeded to remind me of this exception every couple of minutes until I restarted VS.

@addabis
Copy link
Member

addabis commented Jul 19, 2024

Hello,

I'm filing this as a bug.

Thanks for the report.

@gfraiteur gfraiteur added the bug Something isn't working label Aug 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants