-
Notifications
You must be signed in to change notification settings - Fork 60
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
[Bug]: Cannot import CSV file with specified text. #371
Comments
Confirming the problem, it looks like
Thinking of a solution for this but might be a third-partyish issue See also https://core.trac.wordpress.org/ticket/47448 confirming also that problem persist when quoting the code and set the enclosure to |
I think the real problem is the extension of the downloaded file. If I download the "data.csv" file, its name changes to "upload.import" after downloading on the server. This is misleading for "finfo_file" because there is no metadata in the csv file and you can only rely on the contents and extension of the file. The extension ("import") cannot match any mime type and the content contains html, so this fits best. Leaving the file extension "csv" solves this problem without having to expand the list of accepted mime types. |
it's a good input but i've tried to change to not change the file extension from More details On the opposite end, changing to symfony mime type guesser also doesn't help since |
Fixed by #374 |
Expected behavior
The CSV file will be imported properly and a preview will be generated.
Actual behavior
It shows the message "Uploaded no valid preview file." instead of preview and the error "Uploaded file not valid, not creating any queue items and doing any cleanup." occurs when trying to execute import.
Steps to reproduce
Create import configuration. Select CSV as file format. Try to load file with below contents:
The text was updated successfully, but these errors were encountered: