Error: Import has finished with errors - HTTP 404

When there's an error importing one or more lines from your CSV file, you'll see the message below at the end of the import process:

Screenshot from the Import has finished with errors message

By clicking on the "view log" link, you'll be able to see what went wrong with each line (entry) of your CSV. If you see this specific error message below:

Screenshot of the HTTP 404 error

That means you are trying to import a broken URL into a file upload field or any other field that stores URLs, like the Signature field, for example.

There are two ways to fix this error: By correcting the broken link, which means pointing to the correct URL on your CSV file, or by using the code snippet below to instruct the importer to ignore the URL check it performs.

add_filter( 'gravityview/import/run/batch', function ( $batch ) {
	if ( empty( $batch['schema'] ) ) {
		return $batch;
	}

	foreach ( $batch['schema'] as &$schema ) {
		if ( ! isset( $schema['flags'] ) ) {
			$schema['flags'] = [];
		}

		$schema['flags'][] = 'keeplinks';
	}

	return $batch;
} );

See here where to put these code samples.

Correcting the URLs or using the code snippet above and re-running the import process will thus result in a successful message like this:

Screenshot showing the Import has finished message free of errors

Did this answer your question? Thanks for the feedback There was a problem submitting your feedback. Please try again later.

Still need help? Contact Us Contact Us