v4.5.x Fehler 500 bei Artikeloptionen

Thema wurde von Orange Raven, 11. September 2021 erstellt.

  1. Orange Raven

    Orange Raven Erfahrener Benutzer

    Registriert seit:
    3. April 2013
    Beiträge:
    272
    Danke erhalten:
    83
    Danke vergeben:
    33
    Ich leite das hier einfach mal weiter. Ist eine Info von einem meiner Kunden, der es nicht selbst posten kann.

    Ich habe bei mir im Testshop1die neue Version 4.5.1.0 BETA1 eingespielt,

    Vorgängerversion war die 4.4.0.3. Attribute waren unter Module nicht installiert!

    Unter Optionen kommt oben Rechts die Meldung 500 unexpected error occurred

    Ich kann keine neuen Optionen hinzufügen.

    Auf der Artikel erstellen Seite Artikeloptionen zuweisen sind beide Fenster leer, oben Rechts kommt die Meldung GetALLOptions

    In den Logs unter api findet sich folgender log Eintrag:


    2021-09-08 16:48:34 ERROR: An unexpected error occurred while handling an incoming request.

    context:

    error:

    class:

    Webmozart\Assert\InvalidArgumentException

    message:

    Label can not be whitespace only.

    code:

    0

    file:

    /usr/www/users/dtrshop/test1/vendor/webmozart/assert/src/Assert.php

    line:

    2060

    trace:

    0:

    /usr/www/users/dtrshop/test1/vendor/webmozart/assert/src/Assert.php:1036

    │ static::reportInvalidArgument(\sprintf(

    │ $message ?: 'Expected a non-whitespace string. Got: %s',

    ├─ static::valueToString($value)

    │ ));

    │ }

    1:

    /usr/www/users/dtrshop/test1/GambioAdmin/Modules/Option/Model/ValueObjects/OptionValueDetail.php:69

    │ '/^[a-zA-Z]{2}$/',

    │ 'Given language code does not match two digit ISO format. Got: %s');

    ├─ Assert::notWhitespaceOnly($label, 'Label can not be whitespace only.');



    │ return new self($languageCode, $label, $description);

    2:

    /usr/www/users/dtrshop/test1/GambioAdmin/Modules/Option/Services/OptionFactory.php:201

    │ public function createOptionValueDetail(string $languageCode, string $label, string $description): OptionValueDetail

    │ {

    ├─ return OptionValueDetail::create($languageCode, $label, $description);

    │ }



    3:

    /usr/www/users/dtrshop/test1/GambioAdmin/Modules/Option/App/Data/OptionMapper.php:175

    │ return $this->factory->createOptionValueDetail($optionValueDetailData['languageCode'],

    │ $optionValueDetailData['label'],

    ├─ $optionValueDetailData['description']);

    │ },

    │ array_values($optionValueDetailsData));

    4:

    Gambio\Admin\Modules\Option\App\Data\OptionMapper::Gambio\Admin\Modules\Option\App\Data\{closure}

    5:

    /usr/www/users/dtrshop/test1/GambioAdmin/Modules/Option/App/Data/OptionMapper.php:177

    │ $optionValueDetailData['description']);

    │ },

    ├─ array_values($optionValueDetailsData));



    │ return $this->factory->createOptionValueDetails(...$optionValues);

    6:

    /usr/www/users/dtrshop/test1/GambioAdmin/Modules/Option/App/Data/OptionMapper.php:136

    │ $optionValues = array_map(function (array $optionValueData): OptionValue {

    │ $id = $this->factory->createOptionValueId($optionValueData['id']);

    ├─ $details = $this->mapOptionValueDetails($optionValueData['details']);

    │ $productDetails = $this->factory->createOptionValuesProductDetails($optionValueData['productDetails']['modelNumber'],

    │ $optionValueData['productDetails']['weight'],

    7:

    Gambio\Admin\Modules\Option\App\Data\OptionMapper::Gambio\Admin\Modules\Option\App\Data\{closure}

    8:

    /usr/www/users/dtrshop/test1/GambioAdmin/Modules/Option/App/Data/OptionMapper.php:134

    │ private function mapOptionValues(array $optionValuesData): OptionValues

    │ {

    ├─ $optionValues = array_map(function (array $optionValueData): OptionValue {

    │ $id = $this->factory->createOptionValueId($optionValueData['id']);

    │ $details = $this->mapOptionValueDetails($optionValueData['details']);

    9:

    /usr/www/users/dtrshop/test1/GambioAdmin/Modules/Option/App/Data/OptionMapper.php:99

    │ $id = $this->factory->createOptionId($optionData['id']);

    │ $details = $this->mapOptionDetails($optionData['details']);

    ├─ $optionValues = $this->mapOptionValues($optionData['values']);

    │ $newOptionValues = $this->mapNewOptionValues($optionData['newValues']);

    │ $type = $this->factory->createOptionType($optionData['type']);

    10:

    Gambio\Admin\Modules\Option\App\Data\OptionMapper::mapOption

    11:

    /usr/www/users/dtrshop/test1/GambioAdmin/Modules/Option/App/Data/OptionMapper.php:84

    │ public function mapOptions(array $optionsData): Options

    │ {

    ├─ $options = array_map([$this, 'mapOption'], $optionsData);



    │ return Options::create(...$options);

    12:

    /usr/www/users/dtrshop/test1/GambioAdmin/Modules/Option/App/OptionRepository.php:94

    │ public function filterOptions(Filters $filters, Sorting $sorting, Pagination $pagination): Options

    │ {

    ├─ return $this->mapper->mapOptions($this->reader->getFilteredOptionsData($filters, $sorting, $pagination));

    │ }



    13:

    /usr/www/users/dtrshop/test1/GambioAdmin/Modules/Option/App/OptionFilterService.php:59

    │ return $this->repository->filterOptions($this->filterFactory->createFilters($filters),

    │ $this->filterFactory->createSorting($sorting),

    ├─ $this->filterFactory->createPagination($limit, $offset));

    │ }



    14:

    /usr/www/users/dtrshop/test1/GambioApi/Modules/Option/App/Actions/FetchAllOptionsAction.php:73

    │ $offset = $limit * ($page - 1);



    ├─ $options = $this->service->filterOptions($filters, $sorting, $limit, $offset);

    │ $totalItems = $this->service->getOptionsTotalCount($filters);

    │ $metaData = $this->createApiCollectionMetaData($page,

    15:

    /usr/www/users/dtrshop/test1/vendor/slim/slim/Slim/Handlers/Strategies/RequestResponse.php:43

    │ }



    ├─ return $callable($request, $response, $routeArguments);

    │ }

    │ }

    16:

    /usr/www/users/dtrshop/test1/vendor/slim/slim/Slim/Routing/Route.php:384



    │ $response = $this->responseFactory->createResponse();

    ├─ return $strategy($callable, $request, $response, $this->arguments);

    │ }

    │ }

    17:

    /usr/www/users/dtrshop/test1/vendor/slim/slim/Slim/MiddlewareDispatcher.php:81

    │ public function handle(ServerRequestInterface $request): ResponseInterface

    │ {

    ├─ return $this->tip->handle($request);

    │ }



    18:

    /usr/www/users/dtrshop/test1/vendor/slim/slim/Slim/MiddlewareDispatcher.php:81

    │ public function handle(ServerRequestInterface $request): ResponseInterface

    │ {

    ├─ return $this->tip->handle($request);

    │ }



    19:

    /usr/www/users/dtrshop/test1/vendor/slim/slim/Slim/Routing/Route.php:341

    │ }



    ├─ return $this->middlewareDispatcher->handle($request);

    │ }



    20:

    /usr/www/users/dtrshop/test1/vendor/slim/slim/Slim/Routing/RouteRunner.php:84

    │ /** @var Route $route */

    │ $route = $request->getAttribute(RouteContext::ROUTE);

    ├─ return $route->run($request);

    │ }

    │ }

    21:

    /usr/www/users/dtrshop/test1/vendor/slim/slim/Slim/Middleware/RoutingMiddleware.php:59

    │ {

    │ $request = $this->performRouting($request);

    ├─ return $handler->handle($request);

    │ }



    22:

    /usr/www/users/dtrshop/test1/vendor/slim/slim/Slim/MiddlewareDispatcher.php:147

    │ public function handle(ServerRequestInterface $request): ResponseInterface

    │ {

    ├─ return $this->middleware->process($request, $this->next);

    │ }

    │ };

    23:

    /usr/www/users/dtrshop/test1/vendor/slim/slim/Slim/Middleware/ErrorMiddleware.php:107

    │ {

    │ try {

    ├─ return $handler->handle($request);

    │ } catch (Throwable $e) {

    │ return $this->handleException($request, $e);

    24:

    /usr/www/users/dtrshop/test1/vendor/slim/slim/Slim/MiddlewareDispatcher.php:147

    │ public function handle(ServerRequestInterface $request): ResponseInterface

    │ {

    ├─ return $this->middleware->process($request, $this->next);

    │ }

    │ };

    25:

    /usr/www/users/dtrshop/test1/GambioApi/Application/Middleware/RateLimitMiddleware.php:85



    │ if ($this->checkRateLimit($sessionIdentifier)) {

    ├─ $response = $handler->handle($request);



    │ return $response->withHeader('X-Rate-Limit-Limit', (string)$this->rateLimit['limit'])

    26:

    /usr/www/users/dtrshop/test1/vendor/slim/slim/Slim/MiddlewareDispatcher.php:209

    │ if ($this->callableResolver instanceof AdvancedCallableResolverInterface) {

    │ $callable = $this->callableResolver->resolveMiddleware($this->middleware);

    ├─ return $callable($request, $this->next);

    │ }



    27:

    /usr/www/users/dtrshop/test1/GambioApi/Application/Middleware/AuthenticationMiddleware.php:71

    │ }



    ├─ return $handler->handle($request);

    │ }

    │ }

    28:

    /usr/www/users/dtrshop/test1/vendor/slim/slim/Slim/MiddlewareDispatcher.php:209

    │ if ($this->callableResolver instanceof AdvancedCallableResolverInterface) {

    │ $callable = $this->callableResolver->resolveMiddleware($this->middleware);

    ├─ return $callable($request, $this->next);

    │ }



    29:

    /usr/www/users/dtrshop/test1/GambioApi/Application/Middleware/VersionsMiddleware.php:38

    │ public function process(ServerRequestInterface $request, RequestHandlerInterface $handler): ResponseInterface

    │ {

    ├─ $response = $handler->handle($request);



    │ return $response->withHeader('X-Shop-Version', 'v' . ltrim(Application::VERSION, 'v'))

    30:

    /usr/www/users/dtrshop/test1/vendor/slim/slim/Slim/MiddlewareDispatcher.php:209

    │ if ($this->callableResolver instanceof AdvancedCallableResolverInterface) {

    │ $callable = $this->callableResolver->resolveMiddleware($this->middleware);

    ├─ return $callable($request, $this->next);

    │ }



    31:

    /usr/www/users/dtrshop/test1/vendor/slim/slim/Slim/MiddlewareDispatcher.php:81

    │ public function handle(ServerRequestInterface $request): ResponseInterface

    │ {

    ├─ return $this->tip->handle($request);

    │ }



    32:

    /usr/www/users/dtrshop/test1/vendor/slim/slim/Slim/App.php:215

    │ public function handle(ServerRequestInterface $request): ResponseInterface

    │ {

    ├─ $response = $this->middlewareDispatcher->handle($request);



    │ /**

    33:

    /usr/www/users/dtrshop/test1/vendor/slim/slim/Slim/App.php:199

    │ }



    ├─ $response = $this->handle($request);

    │ $responseEmitter = new ResponseEmitter();

    │ $responseEmitter->emit($response);

    34:

    /usr/www/users/dtrshop/test1/GambioCore/Application/Kernel/HttpKernel.php:67

    │ /** @var SlimApp $slim */

    │ $slim = $this->application->get(SlimApp::class);

    ├─ $slim->run(new HttpRequest($slimRequest));

    │ }

    │ }

    35:

    /usr/www/users/dtrshop/test1/GambioCore/Application/Application.php:70

    │ $kernel->bootstrap($app, $bootstrapper);



    ├─ $kernel->run();

    │ }



    36:

    /usr/www/users/dtrshop/test1/api_v3.php:24

    │ require_once __DIR__ . '/vendor/autoload.php';



    ├─ Application::main(new HttpKernel(), new GambioApiBootstrapper());

    37:

    /usr/www/users/dtrshop/test1/api.php:13



    │ if (strpos($_SERVER['REQUEST_URI'], '/api.php/v3') !== false) {

    ├─ require __DIR__ . '/api_v3.php';

    │ exit;

    │ }

    extra:

    ...



    Als Fremdmodule sind nur Mailbeez und ZAWU installiert.


    Diese Problem haben auch 4 andere Händler, die nicht genannt werden wollen.
     
  2. Wilken (Gambio)

    Wilken (Gambio) Administrator
    Mitarbeiter

    Registriert seit:
    7. November 2012
    Beiträge:
    17.775
    Danke erhalten:
    6.757
    Danke vergeben:
    2.046
    Sorry, aber das wird eher nix. Mit Ticket immer gern, da kann man sich die Umstände anschauen, wie die Datenbank aussieht, was da zusammenkommt... Aber ohne das alles,..