Error importing site - Sorry, we couldn't figure out what to do with the file

What issue or error are you experiencing?

Hi, I’m unable to import existing site in Local. It either gets stuck on some percentage of import (this happens if i import backup made through cPanel), or when i try to import zip with WP migrate lite it gives me vague error " Sorry, we couldn’t figure out what to do with the file."

I have latest version of Local 7.1.0 running on windows 10, using only built in firewall which i disabled.

Thanks

What steps can be taken to replicate the issue? Feel free to include screenshots, videos, etc


System Details

  • Local Version:
    7.1.0

  • Operating System (OS) and OS version:
    Windows 10


Local Logs

Attach your Local Logs here (Help Doc - Retrieving Local’s Log)
local-lightning.log (37.3 KB)


Security Reminder
Local does a pretty good job of scrubbing private info from the logs and the errors it produces, however there’s always the possibility that something private can come through. Because these are public forums, always review the screenshots you are sharing to make sure there isn’t private info like passwords being displayed.

Hi @Boiica

There might be something in the file that is confusing Local. This could happen if there are like multiple site backups or database backups for example.

You could attempt a more manual import. The steps would look like this:

  • Unzip the file in a common location, like the desktop
  • Create a new, blank site in Local. Use whatever username/password you like since you’ll overwrite the DB with this site archive’s dump.
  • Copy the wp-content folder from the unzipped location to this newly created site’s location
  • Copy the correct SQL dump to the site root.
  • Within Local, open the site shell
  • Import the dump with wp db import <dumpfile>
  • If that works, now Search and replace the domains. wp search-replace ' https://production.com ' 'http:mylocalsite.local'

Hi Nick,
i got stuck on importing SQL dump, in shell i get warning about php:

Warning: PHP Startup: Unable to load dynamic library ‘php_imagick.dll’

and then error for import dump

Error: Failed to get current SQL modes. Reason: ERROR 2002 (HY000): Can’t connect to MySQL server on ‘localhost’ (10061)

Any ideas what can I do?

Thanks

@Boiica

Are you using the Preferred settings to create your site or Custom ones when you set it up? What do you have set for WP/PHP/MYSQL/Server?

I’m using custom settings (closest one to my live site);
PHP 7.4.30, Apache 2.4.43, MariaDB 10.4.10.

If you change to NGINX does that work?

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