Skip to content

Error compiling CodeDom with .Net 5 #25

@zubialevich

Description

@zubialevich

Hello!

I am trying CodeDom evaluator but randomly I am getting this error:

    CSScriptLib.CompilerException : D:\Users\user\AppData\Local\Temp\1\CSSCRIPT\8304.32641ef8-d66d-487b-9764-c3609e081ccb.tmp(0,0): error CS0006:  Metadata file 'C:\Program Files\dotnet\shared\Microsoft.NETCore.App\5.0.5\' could not be found
    
    Data:
      Errors: System.Collections.Generic.List`1[CSScripting.CodeDom.CompilerError]
    
  Stack Trace: 
    CodeDomEvaluator.CompileAssemblyFromFileBatch_with_Csc(String[] fileNames, String[] ReferencedAssemblies, String outAssembly, Boolean IncludeDebugInformation, CompileInfo info)
    CodeDomEvaluator.Compile(String scriptText, String scriptFile, CompileInfo info)
    EvaluatorBase`1.CompileCode(String scriptText, String scriptFile, CompileInfo info)
    EvaluatorBase`1.CompileCode(String scriptText)
    EvaluatorBase`1.LoadCode[T](String scriptText, Object[] args)```

For RoslynEvaluator and MonoEvaluator everything works without random exception.
I've checked content of `C:\Program Files\dotnet\shared\Microsoft.NETCore.App\5.0.5\` and it's not empty.

Can you point me to a right direction to check?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions