I'm working on an application that runs on a virtual machine. Among other things, the application runs tasks, and one of them is responsible for generating PDFs and saving them directly to S3.

In the production environment, it works smoothly, but in the test environment, the PDFs are not being generated, and from the logs, I have this error (there are no differences in the code between production and test where the PDF is generated):

IronPDF requires a safe directory to unpack resource files. Please set IronPdf.Installation.TempFolderPath before using IronPDF E.g. IronPdf.Installation.TempFolderPath ="C:\Safe\Path\"; Documentation:https://ironpdf.com/c%23-pdf-documentation/html/F_IronPdf_Installation_TempFolderPath.htm Please read the installation FAQ: https://ironpdf.com/docs/questions/installation/

The error is telling me to set up a safe folder... but how do I set it? Do I need to write a logic to periodically empty it?

I'm not sure where to start, and in the code, I don't see any IronPDF configurations other than the license key.

1

There are 1 best solutions below

0
On BEST ANSWER

this is from the Iron Software team.

Could you enable logging with the below code:

// Place at the top of your code, prior to running any other IronPdf methods
IronPdf.Logging.Logger.EnableDebugging = true;
IronPdf.Logging.Logger.LogFilePath = "Default.log";
IronPdf.Logging.Logger.LoggingMode = IronPdf.Logging.Logger.LoggingModes.All;

Furthermore, could you provide more details on the following:

  • IronPdf version
  • Project type (ASP.NET, ASP.NET MVC, etc.)
  • Deployment type (Azure Web App, Azure Function, AWS)
  • Deployment configurations

Please send this information to [email protected]. I will then raise the issue with the development team accordingly.