Problem downloading PDFs

I have a power automate desktop script that is downloading PDFs in a loop.
Sometimes the PDFs start being downloaded as tmp files. I thought it might be a timing problem but I stopped the script and did a manual download and still got a tmp file. When I clear my chrome cache and reboot it seems to resolve the problem. But it occurs again on subsequent runs. I am running windows 11 and have 32gb ram.