Problem/Motivation
when visiting admin/lingotek/settings
get this error
The website encountered an unexpected error. Please try again later.
Drupal\lingotek\Exception\LingotekApiException: Failed to get filters: Client error: `GET https://myaccount.lingotek.com/api/filter?limit=1000` resulted in a `404 Not Found` response: {"messages":["No view access."]} in Drupal\lingotek\Remote\LingotekApi->getFilters() (line 540 of modules/contrib/lingotek/src/Remote/LingotekApi.php).
Drupal\lingotek\Lingotek->getResource('resources.filter', 'getFilters', ) (Line: 219)
Drupal\lingotek\Lingotek->getFilters() (Line: 166)
Drupal\lingotek\Lingotek->getResources() (Line: 109)
Drupal\lingotek\Form\LingotekSettingsTabAccountForm->buildForm(Array, Object)
call_user_func_array(Array, Array) (Line: 536)
Drupal\Core\Form\FormBuilder->retrieveForm('lingotek.settings_tab_account_form', Object) (Line: 283)
Drupal\Core\Form\FormBuilder->buildForm('Drupal\lingotek\Form\LingotekSettingsTabAccountForm', Object) (Line: 224)
Drupal\Core\Form\FormBuilder->getForm('Drupal\lingotek\Form\LingotekSettingsTabAccountForm') (Line: 25)
Drupal\lingotek\Controller\LingotekSettingsController->content()
call_user_func_array(Array, Array) (Line: 123)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 592)
Drupal\Core\Render\Renderer->executeInRenderContext(Object, Object) (Line: 124)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext(Array, Array) (Line: 97)
Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 182)
Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object, 1) (Line: 76)
Symfony\Component\HttpKernel\HttpKernel->handle(Object, 1, 1) (Line: 58)
Drupal\Core\StackMiddleware\Session->handle(Object, 1, 1) (Line: 48)
Drupal\Core\StackMiddleware\KernelPreHandle->handle(Object, 1, 1) (Line: 50)
Drupal\ban\BanMiddleware->handle(Object, 1, 1) (Line: 48)
Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle(Object, 1, 1) (Line: 51)
Drupal\Core\StackMiddleware\NegotiationMiddleware->handle(Object, 1, 1) (Line: 51)
Drupal\Core\StackMiddleware\StackedHttpKernel->handle(Object, 1, 1) (Line: 704)
Drupal\Core\DrupalKernel->handle(Object) (Line: 19)
Forced to change to bypass it
/**
* {@inheritdoc}
*/
public function getFilters() {
// try {
// $this->logger->debug('Lingotek::getFilters called.');
// $response = $this->lingotekClient->get('/api/filter', ['limit' => 1000]);
// }
// catch (\Exception $e) {
// throw new LingotekApiException('Failed to get filters: ' . $e->getMessage());
// }
// return $this->formatResponse($response);
return [];
}
Have not found out what the problem might be
Steps to reproduce
Proposed resolution
Remaining tasks
User interface changes
API changes
Data model changes