TypeError: Drupal\ai\Base\AiProviderClientBase::getAvailableConfiguration(): Argument #2 ($model_id) must be of type string, null given in Drupal\ai\Base\AiProviderClientBase->getAvailableConfiguration()

Created on 13 October 2024, about 1 month ago

Problem/Motivation

Hi all,

I just configured a number of automators on a taxonomy term, replacing the ECA models I was using before, which were still using the openai module.

Now when I try to save a new term, I get a WSOD with the following output:

The website encountered an unexpected error. Try again later.

TypeError: Drupal\ai\Base\AiProviderClientBase::getAvailableConfiguration(): Argument #2 ($model_id) must be of type string, null given in Drupal\ai\Base\AiProviderClientBase->getAvailableConfiguration() (line 325 of modules/contrib/ai/src/Base/AiProviderClientBase.php).

ReflectionMethod->invokeArgs() (Line: 109)
Drupal\ai\Plugin\ProviderProxy->wrapperCall() (Line: 81)
Drupal\ai\Plugin\ProviderProxy->__call() (Line: 475)
Drupal\ai_automator\PluginBaseClasses\RuleBase->prepareLlmInstance() (Line: 65)
Drupal\ai_automator\PluginBaseClasses\Lists->generate() (Line: 70)
Drupal\ai_automator\AiAutomatorRuleRunner->generateResponse() (Line: 70)
Drupal\ai_automator\Plugin\AiAutomatorProcess\DirectSaveProcessing->modify() (Line: 229)
Drupal\ai_automator\AiAutomatorEntityModifier->markFieldForProcessing() (Line: 129)
Drupal\ai_automator\AiAutomatorEntityModifier->saveEntity() (Line: 31)
ai_automator_entity_presave()
call_user_func_array() (Line: 416)
Drupal\Core\Extension\ModuleHandler->Drupal\Core\Extension\{closure}() (Line: 395)
Drupal\Core\Extension\ModuleHandler->invokeAllWith() (Line: 415)
Drupal\Core\Extension\ModuleHandler->invokeAll() (Line: 217)
Drupal\Core\Entity\EntityStorageBase->invokeHook() (Line: 900)
Drupal\Core\Entity\ContentEntityStorageBase->invokeHook() (Line: 529)
Drupal\Core\Entity\EntityStorageBase->doPreSave() (Line: 753)
Drupal\Core\Entity\ContentEntityStorageBase->doPreSave() (Line: 483)
Drupal\Core\Entity\EntityStorageBase->save() (Line: 806)
Drupal\Core\Entity\Sql\SqlContentEntityStorage->save() (Line: 354)
Drupal\Core\Entity\EntityBase->save() (Line: 197)
Drupal\taxonomy\TermForm->save()
call_user_func_array() (Line: 129)
Drupal\Core\Form\FormSubmitter->executeSubmitHandlers() (Line: 67)
Drupal\Core\Form\FormSubmitter->doSubmitForm() (Line: 597)
Drupal\Core\Form\FormBuilder->processForm() (Line: 326)
Drupal\Core\Form\FormBuilder->buildForm() (Line: 48)
Drupal\Core\Entity\EntityFormBuilder->getForm() (Line: 26)
Drupal\taxonomy\Controller\TaxonomyController->addForm()
call_user_func_array() (Line: 123)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 638)
Drupal\Core\Render\Renderer->executeInRenderContext() (Line: 121)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext() (Line: 97)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 181)
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: 50)
Drupal\ban\BanMiddleware->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: 741)
Drupal\Core\DrupalKernel->handle() (Line: 19)

Steps to reproduce

Proposed resolution

Remaining tasks

User interface changes

API changes

Data model changes

🐛 Bug report
Status

Active

Version

1.0

Component

AI Automators

Created by

🇹🇭Thailand AlfTheCat

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

Comments & Activities

Production build 0.71.5 2024