CSV Import - Invalid settings. advanced-settings: Array


After upgrading to Omeka S 3.0.1 and CSV Import 2.2.1, we have been getting errors when trying an import. When you go to Import Settings and choose a file, you get an error which reads “Invalid settings. advanced-settings: Array.” I’ve tried a variety of settings - the error with all combinations tried so far.

The PHP error log provides more context: Got error ‘PHP message: PHP Notice: Array to string conversion in /modules/CSVImport/src/Controller/IndexController.php on line 173’, referer: /admin/csvimport

Does anyone have any advice for resolving this error?


I’ve been able to edit CSV Import to resolve the array to string error, (the form message used key value pairs and the value was an empty array and the key was advanced-settings). The error still occurs in the Omeka interface (just not the Apache logs). Based on the error message, it seems plausible that this is an issue with invalid advanced settings. However, since this is the first form page of the module, I’m not sure how to troubleshoot those settings. I noticed that advanced-settings are present on the Src/Form/MappingForm.php of CSV Import line 271, but am not sure what valid settings would look like.

Also, I have set up a development environment with Omeka S 3.0.1 and CSV Import 2.2.1 and the module works without issues there. Any ideas why this would happen in one environment but not the other? I’ve replicated the modules (same modules, same versions) and the same PHP version. Just to be sure, I uninstalled, recopied, and reinstalled the modules to verify they are running the same code.

Additional output: array(1) { [“rows_by_batch”]=> array(1) { [“isEmpty”]=> string(36) “Value is required and can’t be empty” } }

It turns out the cause was the PHP (php.ini) setting file_uploads was turned off during our server upgrade, just in case this helps anyone else who encounters a similar issue.

Thanks for updating with your findings. I don’t think we’ve seen that one before.

This topic was automatically closed 250 days after the last reply. New replies are no longer allowed.