cancel
Showing results for 
Search instead for 
Did you mean: 

[M2.4] Product CSV Import - Validation Results: The file cannot be uploaded.

SOLVED

[M2.4] Product CSV Import - Validation Results: The file cannot be uploaded.

Hello all,

Odd problem, I almost never ask for help I always just like to figure it out but this one is getting the best of me unfortunately (can't find any error logs for it, not much info on google like at all, the error is so vague...). I pray someone else has had this problem and figured it out...I have over 2k products that need importing and I seriously don't want to redo them Smiley Sad

 

I try to upload the CSV file for the product import (or any type of import on that page for that matter) but I just simply get the error: 

 

Validation Results

 

The file cannot be uploaded.
 
Now here's some information:
-I have tried my own CSV from a 2.3.5 export, same error (this is my actual file I need to be able to import) (this file is 4.5mb but I have php max upload at 6mb which it states I can go up to on the import page)
-I have tried the CSV (sample file) file exported FROM 2.4.1, same error
-I have tried saving both CSV files as UTF-8, same error
-I have tried saving both CSV files as UTF-8 BOM, same error
-I have tried a 20kb zip file, same error
-I have tried a 10kb .jpg file, same error
-File size can be 1kb or 4.5mb, same error
-Even tried a 0kb blank .csv file, same error
-Blank or a path in 'Image File Directory', same error
 
Basically, no matter what I put in there or select for options on that page it will only give that error.
 
Now for permissions - I have successfully completed this page: https://devdocs.magento.com/guides/v2.3/install-gde/prereq/file-system-perms.html#mage-owner-create-... 100%, my files/folder show all the right ownership and permissions (using ls -al) according to those magedocs. I updated from 2.4.0 to 2.4.1 recently and it all went fine. The whole site runs correctly except for this error...
 
Any ideas why nothing will 'upload' there? It seems to be strictly an upload issue because it won't even 'validate' anything, it gets stuck on the upload stage. What folder does it get uploaded to? I could 777 that folder temp if that would work...
 
Any help would be super appreciated! I'm trying to get this project going and these hiccups are depressing and frustrating Smiley Sad ...esp when google brings up almost nothing similar either.
 
Thank you so much in advance!
1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted

Re: [M2.4] Product CSV Import - Validation Results: The file cannot be uploaded.

@james_noon @kf_luk 

I just ran into this issue too. Exactly the same conditions. I went back and checked for any conflicting extensions etc.

While searching I remembered I had changed this option (without really knowing what it did..)

Stores > Configuration > Advanced > System > Media Gallery

when Enable Old Media Gallery = NO - I could no longer import products.

when Enable Old Media Gallery = YES - Import works perfectly.

 

Check this setting! It must be bug... Smiley Happy

 

edit: I posted the issue to magento github

https://github.com/magento/magento2/issues/30649

View solution in original post

5 REPLIES 5
Highlighted

Re: [M2.4] Product CSV Import - Validation Results: The file cannot be uploaded.

Alright well I just ended up making a new install (which I didn't want to do after 15 hours of setting this build up but what can ya do...smh). After some initial setup to the new install, the import works properly so I'm not sure what happened but it seems it was something with the original installation because the second install was done the exact same. So it must have been somewhere along the way of cli tinkering and changing this or that (so forewarning, ALWAYS MAKE FULL BACKUPS!). Unfortunately I'll never know...

 

But thanks for reading either way Smiley Happy

Highlighted

Re: [M2.4] Product CSV Import - Validation Results: The file cannot be uploaded.

Hi @james_noon 

 

Did you have any clue found after setup new system?

We have same problem. -> link

 

Regards, kf

Highlighted

Re: [M2.4] Product CSV Import - Validation Results: The file cannot be uploaded.

@james_noon @kf_luk 

I just ran into this issue too. Exactly the same conditions. I went back and checked for any conflicting extensions etc.

While searching I remembered I had changed this option (without really knowing what it did..)

Stores > Configuration > Advanced > System > Media Gallery

when Enable Old Media Gallery = NO - I could no longer import products.

when Enable Old Media Gallery = YES - Import works perfectly.

 

Check this setting! It must be bug... Smiley Happy

 

edit: I posted the issue to magento github

https://github.com/magento/magento2/issues/30649

View solution in original post

Highlighted

Re: [M2.4] Product CSV Import - Validation Results: The file cannot be uploaded.

Hi @shaunrealbfee5 

 

OMG, thanks for your comment.

I will be unable to locate the problem in a decade if you won't tell me.

Thanks a lot for your advice, it solved the problem.

 

This option give you a modern gallery with search and view customization.

But compare to the import, it can be neglect.

Thanks again.

 

Regards,

kf

Highlighted

Re: [M2.4] Product CSV Import - Validation Results: The file cannot be uploaded.

No worries, it was driving me crazy as to why my file wasn't uploading when I had successfully imported last week. Luckily, I remembered I had changed that setting because I could not see anything else that could conflict with the importer. 

 

Yeah, you are right, I saw the new media gallery after changing the option.. but compared to importing large product catalog, I'd rather that feature working than a new media gallery!