[Resolved] Cannot migrate old site with Polylang to new site with WPML
This thread is resolved. Here is a description of the problem and solution.
Problem: The client is attempting to migrate a website from Polylang to WPML using the migration plugin, but the process is stalling and never completes, even after leaving it running for an extended period and restarting several times. Solution: If you're experiencing a stalled migration process when moving from Polylang to WPML, we recommend trying the solution outlined in our forum post. Follow the steps provided in the WPML forum topic to resolve the issue.
If this solution doesn't seem relevant or if you continue to face issues, please open a new support ticket with us, and we'll be happy to assist you further.
This is the technical support forum for WPML - the multilingual WordPress plugin.
Everyone can read, but only WPML clients can post here. WPML team is replying on the forum 6 days per week, 22 hours per day.
I am trying to build a new website for a client with old site with 815 posts and Polylang. So on the new installation I have installed Polylang, imported all posts and then saved Polylang languages and enabled WPML and the migration plugin. I have basically followed the instructions from this article: https://wpml.org/documentation/related-projects/migrate-polylang-wpml/ But the process never finishes. Left it for a full day, then restarted it several times for another day and still no results. This is a fresh WP install, only important content are the posts, I can provide admin access. Please help!
Link to a page where the issue can be seen: hidden link
It's possible one (or more) posts do not have a language assigned? Maybe some kind of draft or some leftover...
You can see in the error set_original_language with " " so that's possibly something missing here.
You can try this
- do a full backup
- do a database cleanup with a plugin (I don't have one to recommend specifically)
- deactivate all plugins except WPML
- start the migration again
Hi! I did what you suggested - database cleanup and deactivating plugins, restarting migration. Here's the error list now:
[21-Nov-2023 09:42:54 UTC] PHP Deprecated: ltrim(): Passing null to parameter #1 ($string) of type string is deprecated in /var/web/site/public_html/wp-includes/formatting.php on line 4494
[21-Nov-2023 09:44:54 UTC] PHP Notice: Only variables should be passed by reference in /var/web/site/public_html/wp-content/object-cache.php on line 315
[21-Nov-2023 09:44:54 UTC] PHP Notice: wp_cache_flush() used, this is broadly not recommended. Called in /var/web/site/public_html/wp-content/plugins/wp-hummingbird/core/modules/class-advanced.php line 429 in /var/web/site/public_html/wp-content/object-cache.php on line 320
[21-Nov-2023 09:44:55 UTC] PHP Notice: Only variables should be passed by reference in /var/web/site/public_html/wp-content/object-cache.php on line 315
[21-Nov-2023 09:44:55 UTC] PHP Notice: wp_cache_flush() used, this is broadly not recommended. Called in /var/web/site/public_html/wp-content/plugins/wp-hummingbird/core/modules/class-advanced.php line 429 in /var/web/site/public_html/wp-content/object-cache.php on line 320
[21-Nov-2023 09:44:55 UTC] PHP Notice: Only variables should be passed by reference in /var/web/site/public_html/wp-content/object-cache.php on line 315
[21-Nov-2023 09:44:55 UTC] PHP Notice: wp_cache_flush() used, this is broadly not recommended. Called in /var/web/site/public_html/wp-content/plugins/wp-hummingbird/core/modules/class-advanced.php line 429 in /var/web/site/public_html/wp-content/object-cache.php on line 320
[21-Nov-2023 09:44:55 UTC] PHP Notice: Only variables should be passed by reference in /var/web/site/public_html/wp-content/object-cache.php on line 315
[21-Nov-2023 09:44:55 UTC] PHP Notice: wp_cache_flush() used, this is broadly not recommended. Called in /var/web/site/public_html/wp-content/plugins/wp-hummingbird/core/modules/class-advanced.php line 429 in /var/web/site/public_html/wp-content/object-cache.php on line 320
[21-Nov-2023 09:44:55 UTC] PHP Notice: Only variables should be passed by reference in /var/web/site/public_html/wp-content/object-cache.php on line 315
[21-Nov-2023 09:44:55 UTC] PHP Notice: wp_cache_flush() used, this is broadly not recommended. Called in /var/web/site/public_html/wp-content/plugins/wp-hummingbird/core/modules/class-advanced.php line 429 in /var/web/site/public_html/wp-content/object-cache.php on line 320
[21-Nov-2023 09:44:55 UTC] PHP Notice: Only variables should be passed by reference in /var/web/site/public_html/wp-content/object-cache.php on line 315
[21-Nov-2023 09:44:55 UTC] PHP Notice: wp_cache_flush() used, this is broadly not recommended. Called in /var/web/site/public_html/wp-content/plugins/wp-hummingbird/core/modules/class-advanced.php line 429 in /var/web/site/public_html/wp-content/object-cache.php on line 320
[21-Nov-2023 09:44:55 UTC] PHP Notice: Only variables should be passed by reference in /var/web/site/public_html/wp-content/object-cache.php on line 315
[21-Nov-2023 09:44:55 UTC] PHP Notice: wp_cache_flush() used, this is broadly not recommended. Called in /var/web/site/public_html/wp-content/plugins/wp-hummingbird/core/modules/class-advanced.php line 429 in /var/web/site/public_html/wp-content/object-cache.php on line 320
[21-Nov-2023 09:45:51 UTC] PHP Warning: exif_imagetype(): Stream does not support seeking in /var/web/site/public_html/wp-includes/functions.php on line 3310
[21-Nov-2023 09:45:57 UTC] PHP Warning: exif_imagetype(): Stream does not support seeking in /var/web/site/public_html/wp-includes/functions.php on line 3310
[21-Nov-2023 09:46:11 UTC] PHP Warning: exif_imagetype(): Stream does not support seeking in /var/web/site/public_html/wp-includes/functions.php on line 3310
[21-Nov-2023 09:46:44 UTC] PHP Fatal error: Uncaught TypeError: Cannot access offset of type string on string in /var/web/site/public_html/wp-content/plugins/migrate-polylang-to-wpml-0.4/classes/class-mpw_migrate_posts.php:89
Stack trace:
#0 /var/web/site/public_html/wp-content/plugins/migrate-polylang-to-wpml-0.4/classes/class-mpw_migrate_posts.php(24): mpw_migrate_posts->set_original_post_language_details('', Array)
#1 /var/web/site/public_html/wp-content/plugins/migrate-polylang-to-wpml-0.4/migrate-polylang-to-wpml.php(295): mpw_migrate_posts->migrate_posts()
#2 /var/web/site/public_html/wp-includes/class-wp-hook.php(324): Migrate_Polylang_To_WPML->ajax_migrate_posts('')
#3 /var/web/site/public_html/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters('', Array)
#4 /var/web/site/public_html/wp-includes/plugin.php(517): WP_Hook->do_action(Array)
#5 /var/web/site/public_html/wp-admin/admin-ajax.php(188): do_action('wp_ajax_mpw_mig...')
#6 {main}
thrown in /var/web/site/public_html/wp-content/plugins/migrate-polylang-to-wpml-0.4/classes/class-mpw_migrate_posts.php on line 89
[21-Nov-2023 09:47:44 UTC] Cron error for planned event hook: action_scheduler_run_queue, Error code: invalid_schedule, Error message: No planned events., Data: {"schedule":"every_minute","args":["WP Cron"],"interval":60}
I also checked the old export site and there are indeed many non translated posts. Could this be the reason? Is there a way to solve it without translating them, since they are like 200+? Thanks!
Hey, this solved the issue! Huge thanks! Just a note, that I couldn't find it myself in the forum search for some reason, I tried that first before opening a ticket. Thank you!
Manage Cookie Consent
We use cookies to optimize our website and services. Your consent allows us to process data such as browsing behavior. Not consenting may affect some features.
Functional
Always active
Required for our website to operate and communicate correctly.
Preferences
The technical storage or access is necessary for the legitimate purpose of storing preferences that are not requested by the subscriber or user.
Statistics
We use these to analyze the statistics of our site. Collected information is completely anonymous.The technical storage or access that is used exclusively for anonymous statistical purposes. Without a subpoena, voluntary compliance on the part of your Internet Service Provider, or additional records from a third party, information stored or retrieved for this purpose alone cannot usually be used to identify you.
Marketing
These cookies track your browsing to provide ads relevant to you.