AEM Guides:由於不支援的語言代碼,未建立sr-LA的翻譯專案

塞爾維亞語地區設定sr-LA的翻譯專案未出現在Adobe Experience Manager (AEM) Guides中,且翻譯工作建立因不支援的語言錯誤而失敗。 AEM在語言登入中未包含sr-LA作為支援的語言代碼,因此翻譯工作流程不會建立對應的翻譯專案。 在AEM語言登入中新增sr-LA的自訂語言定義,並重新建立翻譯工作。 若要解決此問題,請新增並驗證自訂sr-LA語言定義。

說明 description

環境

Adobe Experience Manager (AEM) Guides (所有版本)

問題/症狀

  • 塞爾維亞語地區設定sr-LA,的主題顯示為進行中,但AEM中未出現對應的翻譯專案。
  • 嘗試建立sr-LA的翻譯工作失敗。
  • UI會顯示不一致的翻譯概觀。
  • 記錄會顯示下列錯誤:
Caused by: com.day.cq.workflow.WorkflowException: Translation for destination language is not supported
    at com.adobe.cq.wcm.translation.impl.process.TranslateSitePrepareProcess.execute(TranslateSitePrepareProcess.java:228)
...
Error while translating language copy for .../sr-LA in null.

AEM語言登入(/libs/wcm/core/resources/languages)不包含sr-lasr_LA作為支援的語言代碼。 只定義下列塞爾維亞文變體:

  • “sr”: { “language”: “Serbian”, “defaultCountry”: “sr_rs”, “country”: “*” }
  • “sr_rs”:
  • “sr_ba”:
  • “sr_me”:

重製條件

  • 嘗試在AEM Guides中建立或檢視sr-LA的翻譯專案。
  • a { text-decoration: none; color: rgba(70, 79, 235, 1) } tr th, tr td { border: 1px solid rgba(230, 230, 230, 1) } tr th { background-color: rgba(245, 245, 245, 1) }
    使用sr-LA作為目標地區設定。
  • 此問題可在現成可用的AEM執行個體上及多個環境中重現。

原因

根本原因是sr-LA不是AEM語言登入支援的預設語言代碼。 翻譯工作流程拒絕不支援的語言代碼,導致sr-LA無法建立翻譯專案。

解決方法 resolution

請依照下列步驟解決問題:

  1. /libs/wcm/core/resources/languages檢查語言登入以確認sr-lasr_LA不存在。

  2. /apps/wcm/core/resources/languages處建立覆蓋。

  3. 新增自訂語言節點:

    • /apps/wcm/core/resources/languages/sr-la
    • language = "Serbian"
    • country = "Latin"
  4. 新增自訂語言節點後,在AEM Guides中建立sr-LA的翻譯專案。

  5. 確認已建立翻譯工作,且工作流程按預期進行。

  6. 如果sr-LA的翻譯專案先前已運作,請確認最近是否已移除或修改自訂語言定義。

  7. 視需要還原或更新自訂語言代碼。

recommendation-more-help
experience-cloud-kcs-help-kbarticles