I am using Aspose.PDF version 20.3.0, for a product that runs on both Windows & Linux (Ubuntu via Docker container)
We have fillable PDFs in a document library, which we fill in form field values with answers to questions that we collect.
It works beautifully on Windows.
However, when we deploy to our Linux docker container, we are seeing null reference exceptions trying to set the value of text box form fields:
System.NullReferenceException: Object reference not set to an instance of an object.
at #=zKzeu6yEv9nebofO9$xNNnxVk59hmUl$dcwCk4i$5qbfH8yuPRlVnjLw=.#=zGfEiYyo=(#=zjejcm82eMFvKaImYz9FXZAHCevTxYX2e_yn5P5PRShcY #=zCduLOskwTWke)
at #=zZue$WINdUg3oHRscG064rtP7Z9oguOmGD1vjzK8dCOaRIVoJ5hLdZIkDgFba$d5r$zye7Td3wtmU.#=zOtSyB4Q=(String #=zgDhrh1s=, #=zAQxatDytNh8BOTUfBqM06kReyblV0WKVNDfKeNo= #=zaP2W_JE=, #=zYtDupo8XpnSo4yHeTWHilos0dK5UVcJEOpQzGFfqkIPBN8jGpDe$A8E= #=zNrheprBYdmGB, Boolean #=zswXRy1s=, Boolean #=zWApUTAI=, #=zaKRYDaRKfNUbWk69OrBg$Fr2lIxelkNDOw==& #=zR2hGbl4=, #=zjejcm82eMFvKaImYz9FXZAHCevTxYX2e_yn5P5PRShcY& #=zCduLOskwTWke, String& #=zTl$1FlfQhYcX)
at #=zKzeu6yEv9nebofO9$xNNnxVk59hmUl$dcwCk4i$5qbfH8yuPRlVnjLw=.#=zpt9hk4I=(#=zS9uC$025V4XeO$3YtdTDRdooP7MGlJB8sBbvhGPbYvDE57wg1GLicWR4DaRudWbnU0$_THZIy641Y8Dwjw==[] #=zjnKQOBqSQyW1U8FoGUH0puefS3Wa, String #=zgDhrh1s=, #=zAQxatDytNh8BOTUfBqM06kReyblV0WKVNDfKeNo= #=zaP2W_JE=, #=zYtDupo8XpnSo4yHeTWHilos0dK5UVcJEOpQzGFfqkIPBN8jGpDe$A8E= #=zNrheprBYdmGB, Boolean #=zswXRy1s=, Boolean #=zWApUTAI=, #=zaKRYDaRKfNUbWk69OrBg$Fr2lIxelkNDOw==& #=zSnssHX4=, #=zjejcm82eMFvKaImYz9FXZAHCevTxYX2e_yn5P5PRShcY& #=zCduLOskwTWke, String& #=zTl$1FlfQhYcX)
at #=zKzeu6yEv9nebofO9$xNNnxVk59hmUl$dcwCk4i$5qbfH8yuPRlVnjLw=.#=zX9fAAJ_6OosL(String #=z0l3XscY=, #=zAQxatDytNh8BOTUfBqM06kReyblV0WKVNDfKeNo= #=zaP2W_JE=, #=zaKRYDaRKfNUbWk69OrBg$Fr2lIxelkNDOw==& #=zVx_RAdQ=, #=zjejcm82eMFvKaImYz9FXZAHCevTxYX2e_yn5P5PRShcY& #=zCduLOskwTWke, String& #=z$Z$radA=)
at Aspose.Pdf.Forms.TextBoxField.#=zq_kIdDzn7aRY(#=zysJ3FsEpz_pB #=z98VMeT0=, Annotation #=zgs9ma0M=)
at Aspose.Pdf.Annotations.WidgetAnnotation.#=zPHGpUsU=(Annotation #=zgs9ma0M=)
at Aspose.Pdf.Forms.Field.#=z$L17Pb0=(String #=zcobXZv4=)
at Aspose.Pdf.Forms.Field.set_Value(String value)
at Aspose.Pdf.Forms.TextBoxField.set_Value(String value)
In our product, we also have GroupDocs.Conversion (also version 20.3.0).
For in our Dockerfile for building our linux docker container image, we have added a reference to SkiaSharp.NativeAssets.Linux, version 2.80.3
Lastly, we have resolved some previous issues that we have encountered with Aspose.PDF and GroupDocs.Conversion on linux, specifically with regards to fonts, by adding the fontconfig
and fonts-liberation
packages to our Dockerfile.
I’m thinking that the issue might be related to fonts, but I’m not entirely certain, given the obfustication in the stack trace.
Is there any way to get any further insight into what the error could be?
We can look into upgrading Aspose.PDF to a later version, although we do find we have issues with later versions and other features, so we have (for now) stabilized our product on the 20.3.0 release.
Thank you,
-Brian