Call to undefined method Drupal\ai_translate\Controller\AiTranslateController::translateContent()

Created on 19 February 2025, about 2 months ago

Problem/Motivation

Getting the error when clicking on Add Translation

The website encountered an unexpected error. Try again later.

Error: Call to undefined method Drupal\ai_translate\Controller\AiTranslateController::translateContent() in Drupal\auto_translation\Utility->drupalAiTranslateApiCall() (line 218 of modules/contrib/auto_translation/src/Utility.php).
Drupal\auto_translation\Utility->translate() (Line: 448)
Drupal\auto_translation\Utility->formTranslate() (Line: 39)
auto_translation_form_node_form_alter() (Line: 459)
Drupal\Core\Extension\ModuleHandler->alter() (Line: 833)
Drupal\Core\Form\FormBuilder->prepareForm() (Line: 249)
Drupal\autosave_form\Form\AutosaveFormBuilder->prepareForm() (Line: 280)
Drupal\Core\Form\FormBuilder->buildForm() (Line: 97)
Drupal\autosave_form\Form\AutosaveFormBuilder->buildForm() (Line: 48)
Drupal\Core\Entity\EntityFormBuilder->getForm() (Line: 413)
Drupal\content_translation\Controller\ContentTranslationController->add()
call_user_func_array() (Line: 123)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 593)
Drupal\Core\Render\Renderer->executeInRenderContext() (Line: 121)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext() (Line: 97)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 183)
Symfony\Component\HttpKernel\HttpKernel->handleRaw() (Line: 76)
Symfony\Component\HttpKernel\HttpKernel->handle() (Line: 53)
Drupal\Core\StackMiddleware\Session->handle() (Line: 48)
Drupal\Core\StackMiddleware\KernelPreHandle->handle() (Line: 28)
Drupal\Core\StackMiddleware\ContentLength->handle() (Line: 32)
Drupal\big_pipe\StackMiddleware\ContentLength->handle() (Line: 116)
Drupal\page_cache\StackMiddleware\PageCache->pass() (Line: 90)
Drupal\page_cache\StackMiddleware\PageCache->handle() (Line: 48)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle() (Line: 51)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle() (Line: 36)
Drupal\Core\StackMiddleware\AjaxPageState->handle() (Line: 51)
Drupal\Core\StackMiddleware\StackedHttpKernel->handle() (Line: 709)
Drupal\Core\DrupalKernel->handle() (Line: 19)

Steps to reproduce

- Configure Auto Translation for a content type
- Click on Add translation for the content
- See the error

Proposed resolution

NA

Remaining tasks

NA

User interface changes

NA

API changes

NA

Data model changes

NA

🐛 Bug report
Status

Active

Version

1.2

Component

Code

Created by

🇮🇳India Vivek Panicker Kolkata

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024