PDF from HTML is not generating document in its Output

Good afternoon all,

We are seeing an issue with generating a PDF file from the HTML document (that was generated with 'HTML Doc from Template' Smart service). We are using the Smart Service 'PDF from HTML' that is available in 'Dynamic Document Generator' (version 2.2.0) plug-in. This is was working earlier and suddenly stopped working for the past 2 weeks. We are currently on Appian version 23.4

Following is the error stack from the logs:

2024-03-05 17:19:32,294 [Appian Work Item - 2966 - WorkID 946 - execution00 - process 1066450 - model 4572 : UnattendedJavaActivityRequest] ERROR com.appiancorp.ps.xmlfo.util.HtmlUtil - Error while generating the PDF file.
javax.swing.text.ChangedCharSetException
	at javax.swing.text.html.parser.DocumentParser.handleEmptyTag(DocumentParser.java:189)
	at javax.swing.text.html.parser.Parser.startTag(Parser.java:429)
	at javax.swing.text.html.parser.Parser.parseTag(Parser.java:1956)
	at javax.swing.text.html.parser.Parser.parseContent(Parser.java:2097)
	at javax.swing.text.html.parser.Parser.parse(Parser.java:2271)
	at javax.swing.text.html.parser.DocumentParser.parse(DocumentParser.java:122)
	at javax.swing.text.html.parser.ParserDelegator.parse(ParserDelegator.java:102)
	at javax.swing.text.html.HTMLEditorKit.read(HTMLEditorKit.java:262)
	at javax.swing.text.JTextComponent.read(JTextComponent.java:1577)
	at javax.swing.JEditorPane.read(JEditorPane.java:539)
	at com.appiancorp.ps.xmlfo.util.HtmlToPdfConverterCallable.call(HtmlToPdfConverterCallable.java:33)
	at com.appiancorp.ps.xmlfo.util.HtmlToPdfConverterCallable.call(HtmlToPdfConverterCallable.java:15)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:750)
2024-03-05 17:19:32,297 [Appian Work Item - 2966 - WorkID 946 - execution00 - process 1066450 - model 4572 : UnattendedJavaActivityRequest] ERROR com.appiancorp.ps.xmlfo.ss.AbstractDocumentGeneration - javax.swing.text.ChangedCharSetException
java.lang.Exception: javax.swing.text.ChangedCharSetException
	at com.appiancorp.ps.xmlfo.util.HtmlUtil.convertHtmlToPdf(HtmlUtil.java:41)
	at com.appiancorp.ps.xmlfo.ss.PdfFromHtml.runSmartService(PdfFromHtml.java:34)
	at com.appiancorp.ps.xmlfo.ss.AbstractDocumentGeneration.run(AbstractDocumentGeneration.java:53)
	at com.appiancorp.process.runtime.framework.DefaultActivityExecutor$1.lambda$call$0(DefaultActivityExecutor.java:136)
	at com.appiancorp.plugins.PluginUsageLogger.runWithPluginInformation(PluginUsageLogger.java:54)
	at com.appiancorp.process.runtime.framework.DefaultActivityExecutor$1.call(DefaultActivityExecutor.java:136)
	at com.appiancorp.process.runtime.framework.DefaultActivityExecutor$1.call(DefaultActivityExecutor.java:130)
	at com.appiancorp.common.ContextClassLoaderSwitcher.runInContext(ContextClassLoaderSwitcher.java:28)
	at com.appiancorp.process.runtime.framework.DefaultActivityExecutor.execute(DefaultActivityExecutor.java:130)
	at com.appiancorp.process.engine.UnattendedJavaActivityRequest.execute(UnattendedJavaActivityRequest.java:88)
	at com.appiancorp.process.engine.UnattendedJavaActivityRequestResponseCreator.getJavaActivityResultResponse(UnattendedJavaActivityRequestResponseCreator.java:22)
	at com.appiancorp.process.engine.UnattendedJavaActivityRequest.getJavaActivityResultResponse(UnattendedJavaActivityRequest.java:67)
	at com.appiancorp.process.engine.UnattendedJavaActivityRequest.execute0(UnattendedJavaActivityRequest.java:55)
	at com.appiancorp.common.persistence.data.AppianDataUserContextProvider.executeWithConsistentDataReads(AppianDataUserContextProvider.java:143)
	at com.appiancorp.process.engine.ProcessContinuationRequest.executeOuter(ProcessContinuationRequest.java:68)
	at com.appiancorp.process.engine.ContinuationRequest.execute(ContinuationRequest.java:129)
	at com.appiancorp.process.workpoller.UnattendedRequestHandlerBean.onMessage(UnattendedRequestHandlerBean.java:36)
	at com.appiancorp.process.workpoller.WorkItem.run(WorkItem.java:110)
	at org.springframework.jca.work.SimpleTaskWorkManager$DelegatingWorkAdapter.run(SimpleTaskWorkManager.java:241)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:750)
Caused by: javax.swing.text.ChangedCharSetException
	at javax.swing.text.html.parser.DocumentParser.handleEmptyTag(DocumentParser.java:189)
	at javax.swing.text.html.parser.Parser.startTag(Parser.java:429)
	at javax.swing.text.html.parser.Parser.parseTag(Parser.java:1956)
	at javax.swing.text.html.parser.Parser.parseContent(Parser.java:2097)
	at javax.swing.text.html.parser.Parser.parse(Parser.java:2271)
	at javax.swing.text.html.parser.DocumentParser.parse(DocumentParser.java:122)
	at javax.swing.text.html.parser.ParserDelegator.parse(ParserDelegator.java:102)
	at javax.swing.text.html.HTMLEditorKit.read(HTMLEditorKit.java:262)
	at javax.swing.text.JTextComponent.read(JTextComponent.java:1577)
	at javax.swing.JEditorPane.read(JEditorPane.java:539)
	at com.appiancorp.ps.xmlfo.util.HtmlToPdfConverterCallable.call(HtmlToPdfConverterCallable.java:33)
	at com.appiancorp.ps.xmlfo.util.HtmlToPdfConverterCallable.call(HtmlToPdfConverterCallable.java:15)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	... 3 more

Appreciate any help in resolving this issue. Please let me know if you need any other information, thank you.

  Discussion posts and replies are publicly visible