admin/lingotek/settings WSOD, not loading

Created on 7 February 2024, 4 months ago
Updated 11 February 2024, 4 months ago

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

💬 Support request
Status

Active

Version

4.1

Component

Code

Created by

🇬🇷Greece GiorgosK Chios, Greece 🇬🇷

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

Comments & Activities

  • Issue created by @GiorgosK
  • 🇮🇳India dineshkumarbollu

    Hi @GiorgosK

    I checked the path admin/lingotek/settings i am unable to reproduce the issue.

  • 🇬🇷Greece GiorgosK Chios, Greece 🇬🇷

    I tried it on a new installation and on initial setup I get the WSOD

    Type	php
    Date	Sunday, February 11, 2024 - 06:35
    User	admin
    Location	http://projectname.docksal.site/admin/lingotek/setup/community
    Referrer	http://projectname.docksal.site/admin/lingotek/settings/accessToken
    Message	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 /var/www/web/modules/contrib/lingotek/src/Remote/LingotekApi.php).
    Severity	Error
    Hostname	172.20.0.2
    
Production build 0.69.0 2024