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

Version 3.0.1 causes react-pdf renderToStream to never return #61

Closed
renchap opened this issue Apr 5, 2024 · 5 comments · Fixed by #62
Closed

Version 3.0.1 causes react-pdf renderToStream to never return #61

renchap opened this issue Apr 5, 2024 · 5 comments · Fixed by #62

Comments

@renchap
Copy link
Contributor

renchap commented Apr 5, 2024

Hi!

I unfortunately do not have an easy direct reproduction, but the 3.0.1 version is causing issues with react-pdf. It's renderToStream function no longer completes after the update.

You can find the initial bug report here: diegomura/react-pdf#2675

Multiple people (including myself) confirmed that the issue is fixed by forcing restructure to version 3.0.0.

It was probably introduced by #52, but I am unsure how to figure out what is happening here.

@blikblum
Copy link
Member

blikblum commented Apr 5, 2024

@mcdurdin can you look at this? Seems the PR you submitted introduced a regression

@blikblum
Copy link
Member

blikblum commented Apr 5, 2024

@renchap a restructure only reproduction would help a lot

@renchap
Copy link
Contributor Author

renchap commented Apr 5, 2024

Looking at the code that changed, I assume that this while loop can now sometime never end:

https://github.com/foliojs/restructure/pull/52/files#diff-142426a87894195e6a9681240f8cf3f4d673910c24bdee65deb3825068dba01bR27-R31

@mcdurdin
Copy link
Contributor

mcdurdin commented Apr 5, 2024

Investigating. Am travelling with limited access for next week. Laptop battery about to die. Have asked @srl295 if he can look as well.

@srl295
Copy link
Contributor

srl295 commented Apr 6, 2024

See the issue, I just linked, I was able to reproduce it… I'm still not sure which restructure API it hits

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

Successfully merging a pull request may close this issue.

4 participants