Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[v2] - Error: ENOENT: no such file or directory, open '//data.trie' #1058

Closed
tafelito opened this issue Nov 11, 2020 · 7 comments
Closed

[v2] - Error: ENOENT: no such file or directory, open '//data.trie' #1058

tafelito opened this issue Nov 11, 2020 · 7 comments

Comments

@tafelito
Copy link

Describe the bug
I think updating to the new version of textkit in this commit 3a5bb34 breaks the build using webpack

I've been using the v2.beta in a nextjs app and everything was working fine until beta.14. As soon as I updated to beta.17 I started to get this error. I googled it and it seems that a few people had that issue and webpack with pdfkit, so I assumend it had to do with the update of textkit to v0.4

Desktop (please complete the following information):

  • OS: MacOS
  • Browser NA
  • React-pdf version 2.beta.17
@Mario8419
Copy link

same problem here, it was working with beta.14. Any idea or how is it going in general with mobile support @diegomura ?

@tomaswitek
Copy link

tomaswitek commented Feb 10, 2021

@tafelito @Mario8419 are you using next.js? If yes, what kind of build target did you use in your next.config.js?
I started to have this kind of problem after changing the build target from server to serverless.
I think it's related to this issue: foliojs/pdfkit#990

@Mario8419
Copy link

sry, I'm on gatsby. solved the enoent problem with proper state handling...the problem occurs if you do have to much rerenderings. ;)

@tomaswitek
Copy link

@Mario8419 thx for the info

@tomaswitek
Copy link

tomaswitek commented Feb 11, 2021

I found a workaround for next.js serverless apps.
This commit should fix the issue.
It's inspired by https://github.com/Pzixel/PDFKit-example

@tomaswitek
Copy link

tomaswitek commented Feb 11, 2021

Hey @diegomura,
I think updating unicode-properties should resolve this issue: foliojs/unicode-properties#2
I tried to prepare a PR, but the original repo is quite different to yours :(

@diegomura
Copy link
Owner

This is fixed in the last versions. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants