[GH-ISSUE #676] Signing thorws "Unknown font format" Error #190

Closed
opened 2026-02-26 18:45:48 +03:00 by kerem · 5 comments
Owner

Originally created by @david-loe on GitHub (Nov 23, 2023).
Original GitHub issue: https://github.com/documenso/documenso/issues/676

Originally assigned to: @Mythie on GitHub.

Issue Description

When signing a document including a Signature Field an Error is thrown.

Steps to Reproduce

  1. Open Gitpod Workspace (or any clean installation)
  2. Sign Up
  3. Upload any file (e.g. https://www.w3.org/WAI/ER/tests/xhtml/testfiles/resources/pdf/dummy.pdf)
  4. Add a signer
  5. Add a signature field onto the document
  6. Send
  7. Open Sign Document Link in the Email
  8. Try to sign

Expected Behavior

No response

Current Behavior

Frontend

Unhandled Runtime Error

Error: Unknown font format
Call Stack

Object.create
../node_modules/@pdf-lib/fontkit/dist/fontkit.es.js (17839:10)
create
../node_modules/pdf-lib/es/core/embedders/CustomFontEmbedder.js (37:57)
call
../node_modules/pdf-lib/node_modules/tslib/tslib.es6.js (100:22)
step
../node_modules/pdf-lib/node_modules/tslib/tslib.es6.js (81:52)
next
../node_modules/pdf-lib/node_modules/tslib/tslib.es6.js (74:70)
new Promise
<anonymous>
__awaiter
../node_modules/pdf-lib/node_modules/tslib/tslib.es6.js (70:11)
CustomFontEmbedder.for
../node_modules/pdf-lib/es/core/embedders/CustomFontEmbedder.js (33:25)
fontkit
../node_modules/pdf-lib/es/api/PDFDocument.js (881:72)
call
../node_modules/pdf-lib/node_modules/tslib/tslib.es6.js (100:22)
step
../node_modules/pdf-lib/node_modules/tslib/tslib.es6.js (81:52)
next
../node_modules/pdf-lib/node_modules/tslib/tslib.es6.js (74:70)
new Promise
<anonymous>
__awaiter
../node_modules/pdf-lib/node_modules/tslib/tslib.es6.js (70:11)
PDFDocument.embedFont
../node_modules/pdf-lib/es/api/PDFDocument.js (861:25)

Backend Console

@documenso/web:dev:  ⨯ ../node_modules/@pdf-lib/fontkit/dist/fontkit.es.js (17839:10) @ Object.create
@documenso/web:dev:  ⨯ Error: Unknown font format
@documenso/web:dev:     at new Promise (<anonymous>)
@documenso/web:dev:     at new Promise (<anonymous>)
@documenso/web:dev: null

Screenshots (optional)

No response

Operating System [e.g., Windows 10]

Win 10

Browser [e.g., Chrome, Firefox]

Firefox

Version [e.g., 2.0.1]

main (c054fc78a4)

Please check the boxes that apply to this issue report.

  • I have searched the existing issues to make sure this is not a duplicate.
  • I have provided steps to reproduce the issue.
  • I have included relevant environment information.
  • I have included any relevant screenshots.
  • I understand that this is a voluntary contribution and that there is no guarantee of resolution.
  • I want to work on creating a PR for this issue if approved
Originally created by @david-loe on GitHub (Nov 23, 2023). Original GitHub issue: https://github.com/documenso/documenso/issues/676 Originally assigned to: @Mythie on GitHub. ### Issue Description When signing a document including a Signature Field an Error is thrown. ### Steps to Reproduce 1. Open Gitpod Workspace (or any clean installation) 2. Sign Up 3. Upload any file (e.g. https://www.w3.org/WAI/ER/tests/xhtml/testfiles/resources/pdf/dummy.pdf) 4. Add a signer 5. Add a signature field onto the document 6. Send 7. Open `Sign Document` Link in the Email 8. Try to sign ### Expected Behavior _No response_ ### Current Behavior ## Frontend ### Unhandled Runtime Error **Error: Unknown font format** Call Stack ``` Object.create ../node_modules/@pdf-lib/fontkit/dist/fontkit.es.js (17839:10) create ../node_modules/pdf-lib/es/core/embedders/CustomFontEmbedder.js (37:57) call ../node_modules/pdf-lib/node_modules/tslib/tslib.es6.js (100:22) step ../node_modules/pdf-lib/node_modules/tslib/tslib.es6.js (81:52) next ../node_modules/pdf-lib/node_modules/tslib/tslib.es6.js (74:70) new Promise <anonymous> __awaiter ../node_modules/pdf-lib/node_modules/tslib/tslib.es6.js (70:11) CustomFontEmbedder.for ../node_modules/pdf-lib/es/core/embedders/CustomFontEmbedder.js (33:25) fontkit ../node_modules/pdf-lib/es/api/PDFDocument.js (881:72) call ../node_modules/pdf-lib/node_modules/tslib/tslib.es6.js (100:22) step ../node_modules/pdf-lib/node_modules/tslib/tslib.es6.js (81:52) next ../node_modules/pdf-lib/node_modules/tslib/tslib.es6.js (74:70) new Promise <anonymous> __awaiter ../node_modules/pdf-lib/node_modules/tslib/tslib.es6.js (70:11) PDFDocument.embedFont ../node_modules/pdf-lib/es/api/PDFDocument.js (861:25) ``` ## Backend Console ``` @documenso/web:dev: ⨯ ../node_modules/@pdf-lib/fontkit/dist/fontkit.es.js (17839:10) @ Object.create @documenso/web:dev: ⨯ Error: Unknown font format @documenso/web:dev: at new Promise (<anonymous>) @documenso/web:dev: at new Promise (<anonymous>) @documenso/web:dev: null ``` ### Screenshots (optional) _No response_ ### Operating System [e.g., Windows 10] Win 10 ### Browser [e.g., Chrome, Firefox] Firefox ### Version [e.g., 2.0.1] main (c054fc78a490302c7b05224a8b459ff8c1cdc019) ### Please check the boxes that apply to this issue report. - [X] I have searched the existing issues to make sure this is not a duplicate. - [X] I have provided steps to reproduce the issue. - [X] I have included relevant environment information. - [X] I have included any relevant screenshots. - [X] I understand that this is a voluntary contribution and that there is no guarantee of resolution. - [ ] I want to work on creating a PR for this issue if approved
kerem 2026-02-26 18:45:48 +03:00
Author
Owner

@Mythie commented on GitHub (Nov 23, 2023):

Feels like Gitpod doesn’t like me, I might need to dedicate some time to coding in it so I can catch all these preemptively. Appreciate your patience with these bugs 😄

I’ll hope to have this one sorted later tonight!

<!-- gh-comment-id:1823911345 --> @Mythie commented on GitHub (Nov 23, 2023): Feels like Gitpod doesn’t like me, I might need to dedicate some time to coding in it so I can catch all these preemptively. Appreciate your patience with these bugs 😄 I’ll hope to have this one sorted later tonight!
Author
Owner

@david-loe commented on GitHub (Nov 23, 2023):

Haha :D I actualy think it's not Gitpod.. ;) But it's very helpful for me to be sure that the error is not due to my dev enviroment

<!-- gh-comment-id:1823920745 --> @david-loe commented on GitHub (Nov 23, 2023): Haha :D I actualy think it's not Gitpod.. ;) But it's very helpful for me to be sure that the error is not due to my dev enviroment
Author
Owner

@bilalqv commented on GitHub (Nov 23, 2023):

@Mythie This error occurs in Local Development setup as well.

<!-- gh-comment-id:1823935008 --> @bilalqv commented on GitHub (Nov 23, 2023): @Mythie This error occurs in Local Development setup as well.
Author
Owner

@catalinpit commented on GitHub (Nov 23, 2023):

Thanks for reporting this!

<!-- gh-comment-id:1824102258 --> @catalinpit commented on GitHub (Nov 23, 2023): Thanks for reporting this!
Author
Owner

@david-loe commented on GitHub (Nov 24, 2023):

Fixed by 8230349114

<!-- gh-comment-id:1825234093 --> @david-loe commented on GitHub (Nov 24, 2023): Fixed by 823034911487d5785473ca8aef9bfe46e271be88
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/documenso#190
No description provided.