strapi / strapi

🚀 Strapi is the leading open-source headless CMS. It’s 100% JavaScript/TypeScript, fully customizable and developer-first.
https://strapi.io
Other
62.85k stars 7.89k forks source link

Getting error when trying to download pdf in strapi gui using cloudinary file upload: v3.5.2 #9646

Closed ajohnson10209 closed 3 years ago

ajohnson10209 commented 3 years ago

Describe the bug I'm using strapi-provider-upload-cloudinary (3.5.2) and I uploaded a pdf file via the media library in the strapi gui. When I try and download the file, I see a 404 error in the web console. The page seems to be requesting a file that doesn't exist in cloudinary.

Steps to reproduce the behavior Spin up a strapi project using the strapi-provider-upload-cloudinary upload provider Go to media library and upload a pdf file Click edit on the pdf file and click download Inspect the page and go to the console. You will see a 404 error coming from cloudinary You can click on this link here (same link that you will see in the screenshot below) and you will get an error:

Expected behavior The file should download onto your file system

Screenshots image image

System

Additional context I updated my version and still got the same error, so I created a follow up ticket to the one below.

9627

@derrickmehaffy

derrickmehaffy commented 3 years ago

@ajohnson10209 is this on a fresh project or do you have custom modifications?

Also is your project code somewhere I can look at? (I can't reproduce this on a fresh project)

ajohnson10209 commented 3 years ago

Here is the link to the repo: https://github.com/ajohnson10209/business-bar-strapi/tree/update/verison. The only modifications I made was adding the strapi-provider-upload-cloudinary plugin. @derrickmehaffy

TXavierLopes commented 3 years ago

@ajohnson10209 Hi, sorry for pinging you but im having exactly the same problem as you had, did you find any solution? Can you help a brother out please?

Thanks

ajohnson10209 commented 3 years ago

@DropTheBase No one got back to me on this issue so since I'm familiar with aws and their sdk, I used s3 for uploading my pdfs. I can share my repo if you are interested.

derrickmehaffy commented 3 years ago

This issue comes from Cloudinary itself and the security settings in Cloudinary. I'm marking as confirmed but it's an upstream issue.

LouisMarzorati commented 3 years ago

Do you have PDFs enabled on your Cloudinary account? Free Cloudinary accounts block PDF uploads unless you manually request access to them from their support.

ajohnson10209 commented 3 years ago

@LouisMarzorati I didn't request pdf access on Cloudinary. Thank you.

abhijithkmpixel commented 1 month ago

But still in strapi the thumbnail for pdf is not getting generated also the url i get in strapi after the pdf is uploaded is https://res.cloudinary.com/demnmts6e/image/upload/v1723547442/sohardevelopment/english_tarrifs_apr_2024_1_eb109c050a.pdf

im using the latest version of strapi v4.25.4