HOME DOCUMENTATION DOWNLOADS

Error when printing pdf with FastReport

When I try to print pdf with FastReport on our dev and test environment, I get this error:

{"ClassName":"System.TypeLoadException","Message":"Method 'get_CommonSyntaxTrees' in type 'Microsoft.CodeAnalysis.CSharp.CSharpCompilation' from assembly 'Microsoft.CodeAnalysis.CSharp, Version=3.8.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' does not have an implementation.","Data":null,"InnerException":null,"HelpURL":null,"StackTraceString":" at FastReport.Code.CSharp.CSharpCodeProvider.CompileAssemblyFromSource(CompilerParameters cp, String code)\n at FastReport.Code.AssemblyDescriptor.InternalCompile(CompilerParameters cp, CompilerResults& cr)\n at FastReport.Code.AssemblyDescriptor.InternalCompile()\n at FastReport.Code.AssemblyDescriptor.Compile()\n at FastReport.Report.Compile()\n at FastReport.Report.Prepare(Boolean append)\n at Origam.BI.FastReport.FastReportService.GetReport(Guid reportId, IXmlContainer data, String format, Hashtable parameters, String dbTransaction) in D:\\a\\1\\s\\origam-source\\Origam.BI.FastReport\\FastReportService.cs:line 66\n at Origam.Workflow.ReportServiceAgent.GetReport(Guid reportId, IXmlContainer data, String format, Hashtable parameters) in D:\\a\\1\\s\\origam-source\\Origam.Workflow\\Service Agents\\ReportServiceAgent.cs:line 55\n at Origam.Workflow.ReportServiceAgent.Run() in D:\\a\\1\\s\\origam-source\\Origam.Workflow\\Service Agents\\ReportServiceAgent.cs:line 154\n at Origam.Workbench.Services.CoreServices.ReportService.GetReport(Guid reportId, XmlDocument data, String format, Hashtable parameters, String transactionId) in D:\\a\\1\\s\\origam-source\\Origam.Workbench.Services\\CoreServices\\ReportService.cs:line 49\n at Origam.ServerCore.Controller.ReportController.HandleReport(ReportRequest reportRequest, String reportName) in D:\\a\\1\\s\\origam-source\\Origam.ServerCore\\Controller\\ReportController.cs:line 119\n at Origam.ServerCore.Controller.ReportController.Get(Guid reportRequestId) in D:\\a\\1\\s\\origam-source\\Origam.ServerCore\\Controller\\ReportController.cs:line 100","RemoteStackTraceString":null,"RemoteStackIndex":0,"ExceptionMethod":null,"HResult":-2146233054,"Source":"FastReport.Compat","WatsonBuckets":null,"TypeLoadClassName":"Microsoft.CodeAnalysis.CSharp.CSharpCompilation","TypeLoadAssemblyName":"Microsoft.CodeAnalysis.CSharp, Version=3.8.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35","TypeLoadMessageArg":"get_CommonSyntaxTrees","TypeLoadResourceID":6012}

Docker version: Version 2021.2.0.2251 (master-latest)

NEW: It seems that it is problem of this newest docker version, older version origam/server:2021.1.0.2220 (which is not accesible anymore) worked OK.

There wasn’t build 2021.1.0.2220. Either it was 2021.1.0.2219 or 2021.1.0.2221. These should be still available. 2220 is 2021.2 build and it is here: Docker Hub.

Maybe this PR broke it. Can anyone try to revert and test?

Thanks for the link. I reverted to origam/server:2021.2-beta.2.2220 and print works. So it’s problem with some later version.