We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Use x86 or x64 DLLs of Aspose.Words.Shaping.HarfBuzz for x86 or x64 Applications to avoid Text Shaper Factory Failed Error AWS VM

We are getting an error “Text shaper factory failed to return text shaper for ‘C:\WINDOWS\Fonts\calibri.ttf’, face index ‘0’” on two servers (one on AWS, one on premises) but not on any other servers.

Initial Words/Harfbuzz versions where 19.7 and we have tried 20.1 with the same result.

Error is raised in one of these three functions (unsure which one) UpdateListLabels, UpdateFields, UpdatePageLayout.

It looks to be the same issue raised here Render Thai language Text in DOCX to PDF using OpenType Features of Aspose.Words API

Looking for some guidance on what to investigate as we can not reproduce it on other machines.

Application is asp.net x64 compiled for .NET Framework 4.7.2

@bruceb6,

Please first remove Aspose.Words for .NET and Aspose.Words.Shaping.HarfBuzz references from your application solution. After that install the ‘same versions’ of Aspose.Words for .NET and Aspose.Words.Shaping.HarfBuzz packages i.e. 20.1 from NuGet. Hope this helps.

Thanks. I’ve removed and added Words and Harfbuzz. That resulted in no csproj differences and I’ve confirmed the 5 Harbuzz dlls in the build are there.

It doesn’t appear to be a permissions issue as I can switch the apppool user to an admin and the problem remains.
What are some of the reasons or what is being attempted when this error is raised? Not sure what to investigate next.

Windows Server 2019 Datacenter edition AWS VM. Possibly hardened in some way that may be causing this component to fail.

@bruceb6,

You can also try manually adding reference to HarfBuzz DLLs in your project. Please open Aspose.Words.Shaping.HarfBuzz and click on the Download package. Rename the .nupkg to .zip and extract the ZIP file. Inside the ~/runtimes folder you will find win-x64 and win-x86 folders. Depending upon the platform target (x86, x64) of your IIS application host, please copy the DLL files from correct folder to inside the Debug folder of your application. Hope, this helps.

The correct HarfBuzz dlls are in the published output. No problems there.

@bruceb6,

Please ZIP and upload your input Word document you are getting this problem with and a simplified Console or ASP.NET application here for testing. Please also provide complete steps that we can follow on our end to observe this behavior. We will then investigate the scenario on our end and provide you more information. Thanks for your cooperation.