Skip Navigation

This thread is resolved. Here is a description of the problem and solution.

Problem:
WPML > Translation Management > Jobs > Get Translation > 500 error

Solution:
It was due to a custom theme, please see this reply for details: https://wpml.org/forums/topic/wpml-translation-management-jobs-get-translation-500-error/page/2/#post-14065827

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.

This topic contains 15 replies, has 3 voices.

Last updated by michaelV-60 1 year, 4 months ago.

Assisted by: Waqas Bin Hasan.

Author Posts
July 4, 2023 at 1:04 am #13936651

michaelV-60

I am trying to:

- get a translation in WPML > Translation Management > Jobs > Get Translation
- Translation that is translated by "Crowdin"!!!!

Link to a page where the issue can be seen:

- hidden link

I expected to see:

- Translation has been downloaded

Instead, I got:

- "Translation could not be downloaded"
- in the Console it throws an error: /wp-json/wpml/tm/v1/tp/apply-translations/:1 Failed to load resource: the server responded with a status of 500 ()
- the same functionality works just fine on our production site safetyculture.com

Screenshot 2023-07-04 at 10.18.47 am.png
July 4, 2023 at 8:21 am #13937891

Alejandro
Supporter

Languages: English (English ) Spanish (Español ) Italian (Italiano )

Timezone: Europe/Rome (GMT+01:00)

Hello!

Could you tell us if the jobs you mention here were initially sent from the production site?

I mean, could it be you were sending it from the production site, then you cloned the site into this staging one and you have issues with it in the staging site?

Because, that is somewhat expected (the site is different because the domain is different and the process started somewhere and needs to finish somewhere else). however, i'd need this information to try to better understand the problem a bit better.

-----------------------

At the same time, if you go to WPML > Support > Communication Logs, can you see something? if it contains text, can you please send it over? it might contain useful information about this issue that we can send to our developers.

Regards.

July 4, 2023 at 10:07 pm #13944909

michaelV-60

Hi Alejandro,

Thank you for your reply.

I've tested the "get translation" on the staging, but the job was sent from the production site, that is the case. However, when I test it locally and the local domain is (wp-safetyculture.local) , the "get translation" works fine.

We have this issue on the staging site, and a new site that is in development and sitting on hidden link

Since you need more accurate case, let's jump on hidden link site.

A bit about this hidden link website:

- multisite
- used as headless CMS (the front-end is on Next.js)
- this is a production site, one of the sites sitting there is live which is Safety Culture Care hidden link
- the other one, is in development and where the problem is with the translations

The jobs are sent from there and have the same issue.

Communication log:

als_desc":"","how_to_get_credentials_url":"","client_create_account_page_url":"","partner":false,"review_url":"","uses_ate":false,"self_registered":false,"custom_fields":[{"label":"API Key","name":"api_key","type":"text"}],"default_service":0,"translation_feedback":false,"feedback_forward_method":"manual","rankings":{"quality":0,"quality_ranking":0.0,"speed":0,"speed_ranking":0.0,"popularity":0,"popularity_ranking":0.0,"primary":0.0,"primary_ranking":0.0},"ratings":{"wpml_average_user_rating":0.0},"specializations":[],"countries":[],"certifications":[],"redirect_to_ts?":true},{"id":117,"name":"Smartcat","description":"Smartcat is an all-in-one platform connecting businesses and translators into a continuous translation delivery loop by combining a collaborative workflow solution, a marketplace, and a network of translation professionals.\r\n","url":"https://wpml.org/go/smartcat/","logo_url":"hidden link","logo_preview_url":"hidden link","project_details_url":"%{server_url}/projects/%{project_id}","add_language_pair_url":"","custom_text_url":"","select_translator_iframe_url":"","translator_contact_iframe_url":"","quote_iframe_url":"","has_translator_selection":false,"project_name_length":128,"suid":"d1c696251639dde597dd81b6fec113a9","doc_url":"https://wpml.org/translation-service/smartcat/","notification":false,"tms":true,"has_language_pairs":false,"deadline":true,"oauth":false,"oauth_url":"","popup_message":"","how_to_get_credentials_desc":"","how_to_get_credentials_url":"","client_create_account_page_url":"","partner":false,"review_url":"","uses_ate":false,"self_registered":false,"custom_fields":[{"label":"Server URL","name":"server_url","type":"text"},{"label":"API key","name":"api_key","type":"text"},{"label":"Account ID","name":"account_id","type":"text"}],"default_service":0,"translation_feedback":false,"feedback_forward_method":"api","rankings":{"quality":0,"quality_ranking":0.0,"speed":0,"speed_ranking":0.0,"popularity":0,"popularity_ranking":0.0,"primary":0.0,"primary_ranking":0.0},"ratings":{"wpml_average_user_rating":0.0},"specializations":[],"countries":[],"certifications":[],"redirect_to_ts?":true},{"id":121,"name":"Smartling","description":"Smartling is a translation management platform and language services provider to localize content across devices and platforms. Author of Enterprise Translation Cloud, a data-driven approach to localization that helps customers achieve higher quality translation at a lower total cost.","url":"https://wpml.org/go/smartling/","logo_url":"hidden link","logo_preview_url":"hidden link","project_details_url":"hidden link{account_id}/account-jobs/{project_id}:{job_id}","add_language_pair_url":"","custom_text_url":"","select_translator_iframe_url":"","translator_contact_iframe_url":"","quote_iframe_url":"","has_translator_selection":false,"project_name_length":128,"suid":"3f1d34db7a1c34e0840e81b4aceb97db","doc_url":"https://wpml.org/translation-service/smartling/","notification":true,"tms":true,"has_language_pairs":true,"deadline":false,"oauth":false,"oauth_url":"","popup_message":"","how_to_get_credentials_desc":"","how_to_get_credentials_url":"","client_create_account_page_url":"","partner":false,"review_url":"","uses_ate":false,"self_registered":false,"custom_fields":[{"label":"User Identifier","name":"user_identifier","type":"text"},{"label":"User Secret","name":"user_secret","type":"text"},{"label":"Account UID","name":"account_uid","type":"text"},{"label":"Project ID","name":"project_id","type":"text"}],"default_service":0,"translation_feedback":false,"feedback_forward_method":"manual","rankings":{"quality":0,"quality_ranking":0.0,"speed":0,"speed_ranking":0.0,"popularity":0,"popularity_ranking":0.0,"primary":0.0,"primary_ranking":0.0},"ratings":{"wpml_average_user_rating":0.0},"specializations":[],"countries":[],"certifications":[],"redirect_to_ts?":true},{"id":144,"name":"SDL Language Cloud TMS","description":"The SDL Language Cloud TMS connector for WPML provides a seamless link between WPML and SDL Language Cloud TMS, allowing fast and easy management of multilingual web content and translation projects from within WordPress.","url":"hidden link","logo_url":"hidden link","logo_preview_url":"hidden link","project_details_url":"hidden link","add_language_pair_url":"","custom_text_url":"","select_translator_iframe_url":"","translator_contact_iframe_url":"","quote_iframe_url":"","has_translator_selection":false,"project_name_length":128,"suid":"a87dad5a887e062d5a269574bd54fc3b","doc_url":"https://wpml.org/translation-service/sdl-language-cloud/","notification":false,"tms":true,"has_language_pairs":false,"deadline":true,"oauth":false,"oauth_url":"","popup_message":"","how_to_get_credentials_desc":"Your username and password are the same as the credentials you use to login to SDL Language Cloud","how_to_get_credentials_url":"https://wpml.org/translation-service/sdl-language-cloud/#connecting-to-language-cloud","client_create_account_page_url":"hidden link","partner":false,"review_url":"","uses_ate":false,"self_registered":false,"custom_fields":[{"label":"Username","name":"username","type":"text"},{"label":"Password","name":"password","type":"text"},{"label":"Client ID","name":"client_id","type":"text"},{"label":"Client Secret","name":"client_secret","type":"text"}],"default_service":0,"translation_feedback":true,"feedback_forward_method":"manual","rankings":{"quality":0,"quality_ranking":0.0,"speed":0,"speed_ranking":0.0,"popularity":0,"popularity_ranking":0.0,"primary":0.0,"primary_ranking":0.0},"ratings":{"wpml_average_user_rating":0.0},"specializations":[],"countries":[],"certifications":[],"redirect_to_ts?":true},{"id":148,"name":"Crowdin","description":"More than 1 000 000 people use Crowdin to translate, manage and organize localization projects. No matter if you manage projects for clients, you work for a Fortune 100 company, or you're self-employed, Crowdin has features and integrations that will suit your localization needs.","url":"hidden link","logo_url":"hidden link","logo_preview_url":"hidden link","project_details_url":"","add_language_pair_url":"","custom_text_url":"","select_translator_iframe_url":"","translator_contact_iframe_url":"","quote_iframe_url":"","has_translator_selection":false,"project_name_length":128,"suid":"699e6ed91a275d04372c7289922a5610","doc_url":"","notification":true,"tms":true,"has_language_pairs":true,"deadline":false,"oauth":false,"oauth_url":"","popup_message":"","how_to_get_credentials_desc":"","how_to_get_credentials_url":"","client_create_account_page_url":"","partner":true,"review_url":"","uses_ate":false,"self_registered":false,"custom_fields":[{"label":"API token","name":"api_token","type":"text"}],"default_service":0,"translation_feedback":true,"feedback_forward_method":"manual","rankings":{"quality":0,"quality_ranking":0.0,"speed":0,"speed_ranking":0.0,"popularity":0,"popularity_ranking":0.0,"primary":0.0,"primary_ranking":0.0},"ratings":{"wpml_average_user_rating":0.0},"specializations":[],"countries":[],"certifications":[],"redirect_to_ts?":false},{"id":149,"name":"Parlam","description":"The Parlam connector for WPML will link your WordPress platform with your Parlam TMS account. Once there, you can translate the content yourself assisted by the translation memory or assign it to the freelance translator or LSP of your choice.","url":"hidden link","logo_url":"hidden link","logo_preview_url":"hidden link","project_details_url":"","add_language_pair_url":"","custom_text_url":"","select_translator_iframe_url":"","translator_contact_iframe_url":"","quote_iframe_url":"","has_translator_selection":false,"project_name_length":128,"suid":"b5a3b7ee5fa28c5370ed81e9a5db619b","doc_url":"","notification":true,"tms":true,"has_language_pairs":true,"deadline":false,"oauth":false,"oauth_url":"","popup_message":"","how_to_get_credentials_desc":"","how_to_get_credentials_url":"","client_create_account_page_url":"","partner":true,"review_url":"","uses_ate":false,"self_registered":false,"custom_fields":[{"label":"API token","name":"api_token","type":"text"}],"default_service":0,"translation_feedback":true,"feedback_forward_method":"manual","rankings":{"quality":0,"quality_ranking":0.0,"speed":0,"speed_ranking":0.0,"popularity":0,"popularity_ranking":0.0,"primary":0.0,"primary_ranking":0.0},"ratings":{"wpml_average_user_rating":0.0},"specializations":[],"countries":[],"certifications":[],"redirect_to_ts?":false}]
}
07/04/2023 10:04:19 pm - call - /jobs.json?api_version=1.1&filter%5Bjob_state%5D=translation_ready&filter%5Barchived%5D=0&filter%5Brevision_greater_than%5D=1&accesskey=UNDISCLOSED - {"api_version":1.1,"filter":{"job_state":"translation_ready","archived":0,"revision_greater_than":1},"accesskey":"UNDISCLOSED"}
07/04/2023 10:04:19 pm - response - {
"status": {
"code": 0,
"message": "success!",
"debug": ""
},

"response": []
}
07/04/2023 10:04:25 pm - call - /jobs/1460980/xliff.json?api_version=1.1&accesskey=UNDISCLOSED - {"api_version":1.1,"job_id":1460980,"accesskey":"UNDISCLOSED"}

Screenshot 2023-07-05 at 8.04.53 am.png
Screenshot 2023-07-05 at 8.04.30 am.png
July 5, 2023 at 11:27 am #13949579

Waqas Bin Hasan
Supporter

Languages: English (English )

Timezone: Asia/Karachi (GMT+05:00)

Hi,

Thank you for providing the details, I am assigned this ticket and 'll try my best to help you on the matter.

May I ask you to try and provide the followings please?

Take full backup of site and database before proceeding.

1. Update WordPress to the latest version, as well as, other plugins and theme as needed. And retry.

2. If that doesn't help, enable debugging on your site. See https://wpml.org/documentation/support/debugging-wpml/ for details. And reproduce the issue. Since you mentioned about a 500 error, we need more details on that. Debugging 'll help logging the errors in debug.log file.

3. Once debugging is enabled, try with a minimal setup like WPML and only most required plugins active (i.e. relevant to that particular type of content). At this point, theme may also play a role. If theme isn't required for this kind of content, it is better to try with a standard one (i.e. 2021 or 2023).

Trying this 'll log the errors as well as 'll give a more clear perspective. For example, if there's any compatibility problem and etc.

I'll also request access to your site for more investigation. Please note that I 'll have to go through the above mentioned as well. That's why it is highly advised to take fresh backups beforehand.

I've set your next reply as private to share this information safely.

IMPORTANT: If you don't see the section for providing access information, do not write in the message box or the information may appear as public.

See https://wpml.org/purchase/support-policy/privacy-and-security-when-providing-debug-information-for-support/ for details on privacy and security.

Regards.

July 6, 2023 at 7:44 am #13955969

Waqas Bin Hasan
Supporter

Languages: English (English )

Timezone: Asia/Karachi (GMT+05:00)

Thank you for providing the access and details.

I see lot of needing update but no worries, I'll check back shortly or 'll do it myself. Since it is a staging site, I hope it won't be an issue.

I'll keep you posted about the progress.

July 6, 2023 at 12:11 pm #13959599

Waqas Bin Hasan
Supporter

Languages: English (English )

Timezone: Asia/Karachi (GMT+05:00)

Thank you for waiting on this.

I am trying to update a few WPML plugins but looks like WPML's registration has some mismatched site key error.

Can you please fix the WPML registration on your sandpit site so it is able to connect to WPML servers, because trying to get translations, I am also getting an error like "Communication error.... Can't find this job, or you don't have access to it.".

You can go to /wp-admin/plugin-install.php?tab=commercial, unregister to get rid of old mismatched registration and register again by creating a new dev key, for the same site.

Let me know when you are done.

July 6, 2023 at 11:09 pm #13963377

michaelV-60

Hey Waqas,

Please do not updated manually we have it managed via git.

I've done 're-register' part and it seem it has fixed the issue 🙂 I just tried to "Get translations" and it worked 🙂

I've tried to do the same on the other site(which is multisite) and it didn't work 🙁

scnextsite.wpenginepowered.com

We have this URL hidden link registered in WPML, do we need to register a particular site that sits in the multisite install as separate site?

This is communication log from the multisite:

roduction/logos/preview_smartcat-64847b2b95859d374aac.png","project_details_url":"%{server_url}/projects/%{project_id}","add_language_pair_url":"","custom_text_url":"","select_translator_iframe_url":"","translator_contact_iframe_url":"","quote_iframe_url":"","has_translator_selection":false,"project_name_length":128,"suid":"d1c696251639dde597dd81b6fec113a9","doc_url":"https://wpml.org/translation-service/smartcat/","notification":false,"tms":true,"has_language_pairs":false,"deadline":true,"oauth":false,"oauth_url":"","popup_message":"","how_to_get_credentials_desc":"","how_to_get_credentials_url":"","client_create_account_page_url":"","partner":false,"review_url":"","uses_ate":false,"self_registered":false,"custom_fields":[{"label":"Server URL","name":"server_url","type":"text"},{"label":"API key","name":"api_key","type":"text"},{"label":"Account ID","name":"account_id","type":"text"}],"default_service":0,"translation_feedback":false,"feedback_forward_method":"api","rankings":{"quality":0,"quality_ranking":0.0,"speed":0,"speed_ranking":0.0,"popularity":0,"popularity_ranking":0.0,"primary":0.0,"primary_ranking":0.0},"ratings":{"wpml_average_user_rating":0.0},"specializations":[],"countries":[],"certifications":[],"redirect_to_ts?":true},{"id":121,"name":"Smartling","description":"Smartling is a translation management platform and language services provider to localize content across devices and platforms. Author of Enterprise Translation Cloud, a data-driven approach to localization that helps customers achieve higher quality translation at a lower total cost.","url":"https://wpml.org/go/smartling/","logo_url":"hidden link","logo_preview_url":"hidden link","project_details_url":"hidden link{account_id}/account-jobs/{project_id}:{job_id}","add_language_pair_url":"","custom_text_url":"","select_translator_iframe_url":"","translator_contact_iframe_url":"","quote_iframe_url":"","has_translator_selection":false,"project_name_length":128,"suid":"3f1d34db7a1c34e0840e81b4aceb97db","doc_url":"https://wpml.org/translation-service/smartling/","notification":true,"tms":true,"has_language_pairs":true,"deadline":false,"oauth":false,"oauth_url":"","popup_message":"","how_to_get_credentials_desc":"","how_to_get_credentials_url":"","client_create_account_page_url":"","partner":false,"review_url":"","uses_ate":false,"self_registered":false,"custom_fields":[{"label":"User Identifier","name":"user_identifier","type":"text"},{"label":"User Secret","name":"user_secret","type":"text"},{"label":"Account UID","name":"account_uid","type":"text"},{"label":"Project ID","name":"project_id","type":"text"}],"default_service":0,"translation_feedback":false,"feedback_forward_method":"manual","rankings":{"quality":0,"quality_ranking":0.0,"speed":0,"speed_ranking":0.0,"popularity":0,"popularity_ranking":0.0,"primary":0.0,"primary_ranking":0.0},"ratings":{"wpml_average_user_rating":0.0},"specializations":[],"countries":[],"certifications":[],"redirect_to_ts?":true},{"id":144,"name":"SDL Language Cloud TMS","description":"The SDL Language Cloud TMS connector for WPML provides a seamless link between WPML and SDL Language Cloud TMS, allowing fast and easy management of multilingual web content and translation projects from within WordPress.","url":"hidden link","logo_url":"hidden link","logo_preview_url":"hidden link","project_details_url":"hidden link","add_language_pair_url":"","custom_text_url":"","select_translator_iframe_url":"","translator_contact_iframe_url":"","quote_iframe_url":"","has_translator_selection":false,"project_name_length":128,"suid":"a87dad5a887e062d5a269574bd54fc3b","doc_url":"https://wpml.org/translation-service/sdl-language-cloud/","notification":false,"tms":true,"has_language_pairs":false,"deadline":true,"oauth":false,"oauth_url":"","popup_message":"","how_to_get_credentials_desc":"Your username and password are the same as the credentials you use to login to SDL Language Cloud","how_to_get_credentials_url":"https://wpml.org/translation-service/sdl-language-cloud/#connecting-to-language-cloud","client_create_account_page_url":"hidden link","partner":false,"review_url":"","uses_ate":false,"self_registered":false,"custom_fields":[{"label":"Username","name":"username","type":"text"},{"label":"Password","name":"password","type":"text"},{"label":"Client ID","name":"client_id","type":"text"},{"label":"Client Secret","name":"client_secret","type":"text"}],"default_service":0,"translation_feedback":true,"feedback_forward_method":"manual","rankings":{"quality":0,"quality_ranking":0.0,"speed":0,"speed_ranking":0.0,"popularity":0,"popularity_ranking":0.0,"primary":0.0,"primary_ranking":0.0},"ratings":{"wpml_average_user_rating":0.0},"specializations":[],"countries":[],"certifications":[],"redirect_to_ts?":true},{"id":148,"name":"Crowdin","description":"More than 1 000 000 people use Crowdin to translate, manage and organize localization projects. No matter if you manage projects for clients, you work for a Fortune 100 company, or you're self-employed, Crowdin has features and integrations that will suit your localization needs.","url":"hidden link","logo_url":"hidden link","logo_preview_url":"hidden link","project_details_url":"","add_language_pair_url":"","custom_text_url":"","select_translator_iframe_url":"","translator_contact_iframe_url":"","quote_iframe_url":"","has_translator_selection":false,"project_name_length":128,"suid":"699e6ed91a275d04372c7289922a5610","doc_url":"","notification":true,"tms":true,"has_language_pairs":true,"deadline":false,"oauth":false,"oauth_url":"","popup_message":"","how_to_get_credentials_desc":"","how_to_get_credentials_url":"","client_create_account_page_url":"","partner":true,"review_url":"","uses_ate":false,"self_registered":false,"custom_fields":[{"label":"API token","name":"api_token","type":"text"}],"default_service":0,"translation_feedback":true,"feedback_forward_method":"manual","rankings":{"quality":0,"quality_ranking":0.0,"speed":0,"speed_ranking":0.0,"popularity":0,"popularity_ranking":0.0,"primary":0.0,"primary_ranking":0.0},"ratings":{"wpml_average_user_rating":0.0},"specializations":[],"countries":[],"certifications":[],"redirect_to_ts?":false},{"id":149,"name":"Parlam","description":"The Parlam connector for WPML will link your WordPress platform with your Parlam TMS account. Once there, you can translate the content yourself assisted by the translation memory or assign it to the freelance translator or LSP of your choice.","url":"hidden link","logo_url":"hidden link","logo_preview_url":"hidden link","project_details_url":"","add_language_pair_url":"","custom_text_url":"","select_translator_iframe_url":"","translator_contact_iframe_url":"","quote_iframe_url":"","has_translator_selection":false,"project_name_length":128,"suid":"b5a3b7ee5fa28c5370ed81e9a5db619b","doc_url":"","notification":true,"tms":true,"has_language_pairs":true,"deadline":false,"oauth":false,"oauth_url":"","popup_message":"","how_to_get_credentials_desc":"","how_to_get_credentials_url":"","client_create_account_page_url":"","partner":true,"review_url":"","uses_ate":false,"self_registered":false,"custom_fields":[{"label":"API token","name":"api_token","type":"text"}],"default_service":0,"translation_feedback":true,"feedback_forward_method":"manual","rankings":{"quality":0,"quality_ranking":0.0,"speed":0,"speed_ranking":0.0,"popularity":0,"popularity_ranking":0.0,"primary":0.0,"primary_ranking":0.0},"ratings":{"wpml_average_user_rating":0.0},"specializations":[],"countries":[],"certifications":[],"redirect_to_ts?":false}]
}
07/06/2023 10:58:34 pm - call - /jobs.json?api_version=1.1&filter%5Bjob_state%5D=translation_ready&filter%5Barchived%5D=0&filter%5Brevision_greater_than%5D=1&accesskey=UNDISCLOSED - {"api_version":1.1,"filter":{"job_state":"translation_ready","archived":0,"revision_greater_than":1},"accesskey":"UNDISCLOSED"}
07/06/2023 10:58:35 pm - response - {
"status": {
"code": 0,
"message": "success!",
"debug": ""
},

"response": []
}
07/06/2023 10:59:33 pm - call - /jobs.json?api_version=1.1&filter%5Bjob_state%5D=translation_ready&filter%5Barchived%5D=0&filter%5Brevision_greater_than%5D=1&accesskey=UNDISCLOSED - {"api_version":1.1,"filter":{"job_state":"translation_ready","archived":0,"revision_greater_than":1},"accesskey":"UNDISCLOSED"}
07/06/2023 10:59:34 pm - response - {
"status": {
"code": 0,
"message": "success!",
"debug": ""
},

"response": []
}
07/06/2023 10:59:43 pm - call - /jobs/1460980/xliff.json?api_version=1.1&accesskey=UNDISCLOSED - {"api_version":1.1,"job_id":1460980,"accesskey":"UNDISCLOSED"}
07/06/2023 11:02:56 pm - call - /jobs.json?api_version=1.1&filter%5Bjob_state%5D=translation_ready&filter%5Barchived%5D=0&filter%5Brevision_greater_than%5D=1&accesskey=UNDISCLOSED - {"api_version":1.1,"filter":{"job_state":"translation_ready","archived":0,"revision_greater_than":1},"accesskey":"UNDISCLOSED"}
07/06/2023 11:02:57 pm - response - {
"status": {
"code": 0,
"message": "success!",
"debug": ""
},

"response": []
}
07/06/2023 11:03:11 pm - call - /jobs/1460980/xliff.json?api_version=1.1&accesskey=UNDISCLOSED - {"api_version":1.1,"job_id":1460980,"accesskey":"UNDISCLOSED"}

July 7, 2023 at 5:26 am #13964021

michaelV-60

I've registered another url, and tried again, on the multisite, still the same error, and here is the communication log:

als_desc":"","how_to_get_credentials_url":"","client_create_account_page_url":"","partner":false,"review_url":"","uses_ate":false,"self_registered":false,"custom_fields":[{"label":"API Key","name":"api_key","type":"text"}],"default_service":0,"translation_feedback":false,"feedback_forward_method":"manual","rankings":{"quality":0,"quality_ranking":0.0,"speed":0,"speed_ranking":0.0,"popularity":0,"popularity_ranking":0.0,"primary":0.0,"primary_ranking":0.0},"ratings":{"wpml_average_user_rating":0.0},"specializations":[],"countries":[],"certifications":[],"redirect_to_ts?":true},{"id":117,"name":"Smartcat","description":"Smartcat is an all-in-one platform connecting businesses and translators into a continuous translation delivery loop by combining a collaborative workflow solution, a marketplace, and a network of translation professionals.\r\n","url":"https://wpml.org/go/smartcat/","logo_url":"hidden link","logo_preview_url":"hidden link","project_details_url":"%{server_url}/projects/%{project_id}","add_language_pair_url":"","custom_text_url":"","select_translator_iframe_url":"","translator_contact_iframe_url":"","quote_iframe_url":"","has_translator_selection":false,"project_name_length":128,"suid":"d1c696251639dde597dd81b6fec113a9","doc_url":"https://wpml.org/translation-service/smartcat/","notification":false,"tms":true,"has_language_pairs":false,"deadline":true,"oauth":false,"oauth_url":"","popup_message":"","how_to_get_credentials_desc":"","how_to_get_credentials_url":"","client_create_account_page_url":"","partner":false,"review_url":"","uses_ate":false,"self_registered":false,"custom_fields":[{"label":"Server URL","name":"server_url","type":"text"},{"label":"API key","name":"api_key","type":"text"},{"label":"Account ID","name":"account_id","type":"text"}],"default_service":0,"translation_feedback":false,"feedback_forward_method":"api","rankings":{"quality":0,"quality_ranking":0.0,"speed":0,"speed_ranking":0.0,"popularity":0,"popularity_ranking":0.0,"primary":0.0,"primary_ranking":0.0},"ratings":{"wpml_average_user_rating":0.0},"specializations":[],"countries":[],"certifications":[],"redirect_to_ts?":true},{"id":121,"name":"Smartling","description":"Smartling is a translation management platform and language services provider to localize content across devices and platforms. Author of Enterprise Translation Cloud, a data-driven approach to localization that helps customers achieve higher quality translation at a lower total cost.","url":"https://wpml.org/go/smartling/","logo_url":"hidden link","logo_preview_url":"hidden link","project_details_url":"hidden link{account_id}/account-jobs/{project_id}:{job_id}","add_language_pair_url":"","custom_text_url":"","select_translator_iframe_url":"","translator_contact_iframe_url":"","quote_iframe_url":"","has_translator_selection":false,"project_name_length":128,"suid":"3f1d34db7a1c34e0840e81b4aceb97db","doc_url":"https://wpml.org/translation-service/smartling/","notification":true,"tms":true,"has_language_pairs":true,"deadline":false,"oauth":false,"oauth_url":"","popup_message":"","how_to_get_credentials_desc":"","how_to_get_credentials_url":"","client_create_account_page_url":"","partner":false,"review_url":"","uses_ate":false,"self_registered":false,"custom_fields":[{"label":"User Identifier","name":"user_identifier","type":"text"},{"label":"User Secret","name":"user_secret","type":"text"},{"label":"Account UID","name":"account_uid","type":"text"},{"label":"Project ID","name":"project_id","type":"text"}],"default_service":0,"translation_feedback":false,"feedback_forward_method":"manual","rankings":{"quality":0,"quality_ranking":0.0,"speed":0,"speed_ranking":0.0,"popularity":0,"popularity_ranking":0.0,"primary":0.0,"primary_ranking":0.0},"ratings":{"wpml_average_user_rating":0.0},"specializations":[],"countries":[],"certifications":[],"redirect_to_ts?":true},{"id":144,"name":"SDL Language Cloud TMS","description":"The SDL Language Cloud TMS connector for WPML provides a seamless link between WPML and SDL Language Cloud TMS, allowing fast and easy management of multilingual web content and translation projects from within WordPress.","url":"hidden link","logo_url":"hidden link","logo_preview_url":"hidden link","project_details_url":"hidden link","add_language_pair_url":"","custom_text_url":"","select_translator_iframe_url":"","translator_contact_iframe_url":"","quote_iframe_url":"","has_translator_selection":false,"project_name_length":128,"suid":"a87dad5a887e062d5a269574bd54fc3b","doc_url":"https://wpml.org/translation-service/sdl-language-cloud/","notification":false,"tms":true,"has_language_pairs":false,"deadline":true,"oauth":false,"oauth_url":"","popup_message":"","how_to_get_credentials_desc":"Your username and password are the same as the credentials you use to login to SDL Language Cloud","how_to_get_credentials_url":"https://wpml.org/translation-service/sdl-language-cloud/#connecting-to-language-cloud","client_create_account_page_url":"hidden link","partner":false,"review_url":"","uses_ate":false,"self_registered":false,"custom_fields":[{"label":"Username","name":"username","type":"text"},{"label":"Password","name":"password","type":"text"},{"label":"Client ID","name":"client_id","type":"text"},{"label":"Client Secret","name":"client_secret","type":"text"}],"default_service":0,"translation_feedback":true,"feedback_forward_method":"manual","rankings":{"quality":0,"quality_ranking":0.0,"speed":0,"speed_ranking":0.0,"popularity":0,"popularity_ranking":0.0,"primary":0.0,"primary_ranking":0.0},"ratings":{"wpml_average_user_rating":0.0},"specializations":[],"countries":[],"certifications":[],"redirect_to_ts?":true},{"id":148,"name":"Crowdin","description":"More than 1 000 000 people use Crowdin to translate, manage and organize localization projects. No matter if you manage projects for clients, you work for a Fortune 100 company, or you're self-employed, Crowdin has features and integrations that will suit your localization needs.","url":"hidden link","logo_url":"hidden link","logo_preview_url":"hidden link","project_details_url":"","add_language_pair_url":"","custom_text_url":"","select_translator_iframe_url":"","translator_contact_iframe_url":"","quote_iframe_url":"","has_translator_selection":false,"project_name_length":128,"suid":"699e6ed91a275d04372c7289922a5610","doc_url":"","notification":true,"tms":true,"has_language_pairs":true,"deadline":false,"oauth":false,"oauth_url":"","popup_message":"","how_to_get_credentials_desc":"","how_to_get_credentials_url":"","client_create_account_page_url":"","partner":true,"review_url":"","uses_ate":false,"self_registered":false,"custom_fields":[{"label":"API token","name":"api_token","type":"text"}],"default_service":0,"translation_feedback":true,"feedback_forward_method":"manual","rankings":{"quality":0,"quality_ranking":0.0,"speed":0,"speed_ranking":0.0,"popularity":0,"popularity_ranking":0.0,"primary":0.0,"primary_ranking":0.0},"ratings":{"wpml_average_user_rating":0.0},"specializations":[],"countries":[],"certifications":[],"redirect_to_ts?":false},{"id":149,"name":"Parlam","description":"The Parlam connector for WPML will link your WordPress platform with your Parlam TMS account. Once there, you can translate the content yourself assisted by the translation memory or assign it to the freelance translator or LSP of your choice.","url":"hidden link","logo_url":"hidden link","logo_preview_url":"hidden link","project_details_url":"","add_language_pair_url":"","custom_text_url":"","select_translator_iframe_url":"","translator_contact_iframe_url":"","quote_iframe_url":"","has_translator_selection":false,"project_name_length":128,"suid":"b5a3b7ee5fa28c5370ed81e9a5db619b","doc_url":"","notification":true,"tms":true,"has_language_pairs":true,"deadline":false,"oauth":false,"oauth_url":"","popup_message":"","how_to_get_credentials_desc":"","how_to_get_credentials_url":"","client_create_account_page_url":"","partner":true,"review_url":"","uses_ate":false,"self_registered":false,"custom_fields":[{"label":"API token","name":"api_token","type":"text"}],"default_service":0,"translation_feedback":true,"feedback_forward_method":"manual","rankings":{"quality":0,"quality_ranking":0.0,"speed":0,"speed_ranking":0.0,"popularity":0,"popularity_ranking":0.0,"primary":0.0,"primary_ranking":0.0},"ratings":{"wpml_average_user_rating":0.0},"specializations":[],"countries":[],"certifications":[],"redirect_to_ts?":false}]
}
07/07/2023 05:25:09 am - call - /jobs.json?api_version=1.1&filter%5Bjob_state%5D=translation_ready&filter%5Barchived%5D=0&filter%5Brevision_greater_than%5D=1&accesskey=UNDISCLOSED - {"api_version":1.1,"filter":{"job_state":"translation_ready","archived":0,"revision_greater_than":1},"accesskey":"UNDISCLOSED"}
07/07/2023 05:25:10 am - response - {
"status": {
"code": 0,
"message": "success!",
"debug": ""
},

"response": []
}
07/07/2023 05:25:18 am - call - /jobs/1460980/xliff.json?api_version=1.1&accesskey=UNDISCLOSED - {"api_version":1.1,"job_id":1460980,"accesskey":"UNDISCLOSED"}

July 7, 2023 at 7:32 am #13964955

Waqas Bin Hasan
Supporter

Languages: English (English )

Timezone: Asia/Karachi (GMT+05:00)

Thank you for the updates.

Can you give access to the one having the problem? For example the hidden link (multisite).

So I can forward the case to our 2nd tier for an investigation.

I've set your next reply as private to provide the credentials safely.

July 11, 2023 at 6:58 am #14010587

Waqas Bin Hasan
Supporter

Languages: English (English )

Timezone: Asia/Karachi (GMT+05:00)

Thank you for the updates.

I've escalated the issue to the relevant team and 'll update you as soon as I hear back.

July 14, 2023 at 4:37 am #14037101

Waqas Bin Hasan
Supporter

Languages: English (English )

Timezone: Asia/Karachi (GMT+05:00)

Looks like WPML isn't registered on the site which may be a problem as well. Can you please go to hidden link and register it?

July 16, 2023 at 10:37 pm #14045469

michaelV-60

Hi Waqas,

Just done it, and it didn't help 🙁

July 17, 2023 at 6:40 am #14046043

Waqas Bin Hasan
Supporter

Languages: English (English )

Timezone: Asia/Karachi (GMT+05:00)

Thank you for the updates, I've checked and 've forwarded again to the relevant team.

I'll update you as soon as I hear back.

July 19, 2023 at 11:48 am #14065827

Waqas Bin Hasan
Supporter

Languages: English (English )

Timezone: Asia/Karachi (GMT+05:00)

Thank you for your patience and cooperation.

Our team investigated the problem and found the following error:

PHP Fatal error:  Uncaught Error: Call to undefined function get_sample_permalink() in \wp-content\themes\safetyculture\functions\preview.php:11
Stack trace:
#0 \wp-includes\class-wp-hook.php(310): save(1002)
#1 \wp-includes\class-wp-hook.php(332): WP_Hook->apply_filters(NULL, Array)
#2 \wp-includes\plugin.php(517): WP_Hook->do_action(Array)
#3 \wp-includes\post.php(4715): do_action('save_post', 1002, Object(WP_Post), true)
#4 \wp-includes\post.php(4817): wp_insert_post(Array, false, true)
#5 \wp-content\plugins\sitepress-multilingual-cms\inc\post-translation\wpml-create-post-helper.class.php(34): wp_update_post(Array, false)
#6 \wp-content\plugins\sitepress-multilingual-cms\inc\translation-jobs\helpers\wpml-save-translation-data-action.class.php(185): WPML_Create_Post_Helper->insert_post(Array, 'es')
#7 \wp-content\plugins\sitepress-multilingual-cms\inc\wpml-private- in \wp-content\themes\safetyculture\functions\preview.php on line 11

which is caused by a custom code in your theme's save() function in "\wp-content\themes\safetyculture\functions\preview.php".

The code works on save_post hook. However because of how WPML works, the permalink could not be obtained at the time of saving the post... [and] it should not hook like that in the first place.

The user should adjust his code to not cause fatal errors.

Remember to take a full backup beforehand.

So please replace the following code in said file:

  function save() {
    if ( ! wp_is_post_revision( get_the_ID() ) ) {
      remove_action( 'save_post', 'save' );
      wp_update_post( array( 'ID' => get_the_ID(), 'post_name' => get_sample_permalink( get_the_ID() )[1] ) );
      add_action( 'save_post', 'save' );
    }
  }
  add_action( 'save_post', 'save' );

with:

  function save() {
	  $checkforwpml = debug_backtrace();
	  foreach ($checkforwpml as $test) {
		  if ($test["class"] == "WPML_Create_Post_Helper"){
			 return;
		  }
	  }
    if ( ! wp_is_post_revision( get_the_ID() ) ) {
      remove_action( 'save_post', 'save' );
      wp_update_post( array( 'ID' => get_the_ID(), 'post_name' => get_sample_permalink( get_the_ID() )[1] ) );
      add_action( 'save_post', 'save' );
    }
  }
  add_action( 'save_post', 'save' );

Then try again and let me know how it works.

July 20, 2023 at 3:08 am #14068987

michaelV-60

Hi Waqas,

Thank you very much! it worked on the staging site, we will try to roll out the fix on the production site in the new few days and see how it goes.

Thanks
Pav