Your request couldn't be completed. Try again later.
Hello, I am trying to convert PDF pages to images but I often run into this error:
[CONVEX A(pdf:pageToUrl)] Your request couldn't be completed. Try again later.
11 Replies
Thanks for posting in <#1088161997662724167>.
Reminder: If you have a Convex Pro account, use the Convex Dashboard to file support tickets.
- Provide context: What are you trying to achieve, what is the end-user interaction, what are you seeing? (full error message, command output, etc.)
- Use search.convex.dev to search Docs, Stack, and Discord all at once.
- Additionally, you can post your questions in the Convex Community's <#1228095053885476985> channel to receive a response from AI.
- Avoid tagging staff unless specifically instructed.
Thank you!
Pastebin
export const pageToUrl = internalAction({ args: { pdfUrl: v.str...
Pastebin.com is the number one paste tool since 2002. Pastebin is a website where you can store text online for a set period of time.
This is my code
Can you share an example of the args that would be passed to that action? Have you confirmed that the args passed are what you expect?
I recommend logging to the console in a few places to more precisely identify what part of the action is failing.
It seems to fail when I try to run
PDFiumLibrary.init();
(https://github.com/hyzyla/pdfium) but only sometimesGitHub
GitHub - hyzyla/pdfium: Typescript wrapper for the PDFium library, ...
Typescript wrapper for the PDFium library, works in browser and node.js - hyzyla/pdfium
9/6/2025, 6:19:12 PM [CONVEX A(pdf:pageToUrl)] [LOG] {
format: 'jpeg',
page: 2,
pdfUrl: '<R2_URL>',
renderFormFields: true,
scale: 1.5
}
9/6/2025, 6:19:13 PM [CONVEX A(pdf:pageToUrl)] [LOG] 'fetch response status' 200
9/6/2025, 6:19:14 PM [CONVEX A(pdf:pageToUrl)] [LOG] 'PDF Bytes MB' 13.7
9/6/2025, 6:19:32 PM [CONVEX A(pdf:pageToUrl)] Your request couldn't be completed. Try again later.

Have you tried adding the
use node
directive to the top of the file containing the action? https://docs.convex.dev/functions/actions#choosing-the-runtime-use-nodeActions | Convex Developer Hub
Call third-party services and external APIs from Convex
Yes, it already has "use node"
nodeVersion is set to 22, and pdfium is marked as an external package
in convex.json
i may be wrong, but it seems to me like it always works for the first page, but then when it tries to run for the second / third / etc time, it always "times out" when trying to load pdfium and crashes. is it because the node environment is shared? destroying the lib instance doesn't seem to fix it either
I'm not familiar with the inner workings of that part of the system. We might need to wait for one of the Convex team to chime in on this. They sometimes do so over weekends, but there's no guarantee.
thank you, appreciate it