Exceptions
Exceptions 2
App\Infrastructure\Exception\ LogicException
in
src/Infrastructure/Api/ApiClient.php
(line 79)
}throw new ApiBadRequest($message['message']);}throw new LogicException('Unknown API exception', 0, $exception);} catch (RedirectionExceptionInterface|ServerExceptionInterface|TransportExceptionInterface|MappingError|InvalidSource $exception) {throw new LogicException($exception->getMessage(), 0, $exception);}}}
#[MapQueryParameter] string|null $search,#[MapQueryParameter] string|null $sort,#[MapQueryParameter] int|null $page,): Response {try {$products = $this->apiClient->request(new ProductListApiRequest(new ProductListApiInput($page ?? 1,20,$sort,$tag,$category,
in
vendor/symfony/http-kernel/HttpKernel.php
->
__invoke
(line 183)
$this->dispatcher->dispatch($event, KernelEvents::CONTROLLER_ARGUMENTS);$controller = $event->getController();$arguments = $event->getArguments();// call controller$response = $controller(...$arguments);// viewif (!$response instanceof Response) {$event = new ViewEvent($this, $request, $type, $response, $event);$this->dispatcher->dispatch($event, KernelEvents::VIEW);
in
vendor/symfony/http-kernel/HttpKernel.php
->
handleRaw
(line 76)
$request->headers->set('X-Php-Ob-Level', (string) ob_get_level());$this->requestStack->push($request);$response = null;try {return $response = $this->handleRaw($request, $type);} catch (\Throwable $e) {if ($e instanceof \Error && !$this->handleAllThrowables) {throw $e;}
in
vendor/symfony/http-kernel/Kernel.php
->
handle
(line 182)
$this->boot();++$this->requestStackSize;$this->resetServices = true;try {return $this->getHttpKernel()->handle($request, $type, $catch);} finally {--$this->requestStackSize;}}
in
vendor/fluffydiscord/roadrunner-symfony-bundle/src/Worker/HttpWorker.php
->
handle
(line 76)
while ($request = $worker->waitRequest()) {$this->sentryHubInterface?->pushScope();try {$symfonyRequest = $this->httpFoundationFactory->createRequest($request);$symfonyResponse = $this->kernel->handle($symfonyRequest);$content = match (true) {$symfonyResponse instanceof StreamedJsonResponse => StreamedJsonResponseWrapper::wrap($symfonyResponse),$symfonyResponse instanceof StreamedResponse => StreamedResponseWrapper::wrap($symfonyResponse),$symfonyResponse instanceof BinaryFileResponse => BinaryFileResponseWrapper::wrap($symfonyResponse, $symfonyRequest),
in
vendor/fluffydiscord/roadrunner-symfony-bundle/src/Runtime/Runner.php
->
start
(line 33)
error_log(sprintf('Missing RR worker implementation for %s mode', $this->mode));return 1;}$worker->start();return 0;}}
in
vendor/autoload_runtime.php
->
run
(line 29)
$app = $app(...$args);exit($runtime->getRunner($app)->run());
declare(strict_types=1);use App\Infrastructure\Kernel;require_once dirname(__DIR__) . '/vendor/autoload_runtime.php';return function (array $context): Kernel {return new Kernel($context['APP_ENV'], (bool) $context['APP_DEBUG']); // @phpstan-ignore argument.type};
Symfony\Component\HttpClient\Exception\ ClientException
if (500 <= $code) {throw new ServerException($this);}if (400 <= $code) {throw new ClientException($this);}if (300 <= $code) {throw new RedirectionException($this);}
in
vendor/symfony/http-client/Response/TraceableResponse.php
->
checkStatusCode
(line 100)
} finally {if ($this->event?->isStarted()) {$this->event->stop();}if ($throw) {$this->checkStatusCode($this->response->getStatusCode());}}}public function toArray(bool $throw = true): array
'Content-Type' => 'application/json','Authorization' => 'Bearer ' . $account?->getAccessToken()->getValue(),],]);return $this->mapper->map($apiEndpoint->getOutputClass(), new JsonSource($response->getContent()));} catch (ClientExceptionInterface $exception) {if ($exception->getCode() === Response::HTTP_UNAUTHORIZED) {throw new UnauthorizedHttpException($exception->getMessage(), previous: $exception);}
#[MapQueryParameter] string|null $search,#[MapQueryParameter] string|null $sort,#[MapQueryParameter] int|null $page,): Response {try {$products = $this->apiClient->request(new ProductListApiRequest(new ProductListApiInput($page ?? 1,20,$sort,$tag,$category,
in
vendor/symfony/http-kernel/HttpKernel.php
->
__invoke
(line 183)
$this->dispatcher->dispatch($event, KernelEvents::CONTROLLER_ARGUMENTS);$controller = $event->getController();$arguments = $event->getArguments();// call controller$response = $controller(...$arguments);// viewif (!$response instanceof Response) {$event = new ViewEvent($this, $request, $type, $response, $event);$this->dispatcher->dispatch($event, KernelEvents::VIEW);
in
vendor/symfony/http-kernel/HttpKernel.php
->
handleRaw
(line 76)
$request->headers->set('X-Php-Ob-Level', (string) ob_get_level());$this->requestStack->push($request);$response = null;try {return $response = $this->handleRaw($request, $type);} catch (\Throwable $e) {if ($e instanceof \Error && !$this->handleAllThrowables) {throw $e;}
in
vendor/symfony/http-kernel/Kernel.php
->
handle
(line 182)
$this->boot();++$this->requestStackSize;$this->resetServices = true;try {return $this->getHttpKernel()->handle($request, $type, $catch);} finally {--$this->requestStackSize;}}
in
vendor/fluffydiscord/roadrunner-symfony-bundle/src/Worker/HttpWorker.php
->
handle
(line 76)
while ($request = $worker->waitRequest()) {$this->sentryHubInterface?->pushScope();try {$symfonyRequest = $this->httpFoundationFactory->createRequest($request);$symfonyResponse = $this->kernel->handle($symfonyRequest);$content = match (true) {$symfonyResponse instanceof StreamedJsonResponse => StreamedJsonResponseWrapper::wrap($symfonyResponse),$symfonyResponse instanceof StreamedResponse => StreamedResponseWrapper::wrap($symfonyResponse),$symfonyResponse instanceof BinaryFileResponse => BinaryFileResponseWrapper::wrap($symfonyResponse, $symfonyRequest),
in
vendor/fluffydiscord/roadrunner-symfony-bundle/src/Runtime/Runner.php
->
start
(line 33)
error_log(sprintf('Missing RR worker implementation for %s mode', $this->mode));return 1;}$worker->start();return 0;}}
in
vendor/autoload_runtime.php
->
run
(line 29)
$app = $app(...$args);exit($runtime->getRunner($app)->run());
declare(strict_types=1);use App\Infrastructure\Kernel;require_once dirname(__DIR__) . '/vendor/autoload_runtime.php';return function (array $context): Kernel {return new Kernel($context['APP_ENV'], (bool) $context['APP_DEBUG']); // @phpstan-ignore argument.type};
Stack Traces 2
|
[2/2]
LogicException
|
|---|
App\Infrastructure\Exception\LogicException:
Unknown API exception
at src/Infrastructure/Api/ApiClient.php:79
at App\Infrastructure\Api\ApiClient->request()
(src/Domain/Product/Action/ProductList/ProductListAction.php:45)
at App\Domain\Product\Action\ProductList\ProductListAction->__invoke()
(vendor/symfony/http-kernel/HttpKernel.php:183)
at Symfony\Component\HttpKernel\HttpKernel->handleRaw()
(vendor/symfony/http-kernel/HttpKernel.php:76)
at Symfony\Component\HttpKernel\HttpKernel->handle()
(vendor/symfony/http-kernel/Kernel.php:182)
at Symfony\Component\HttpKernel\Kernel->handle()
(vendor/fluffydiscord/roadrunner-symfony-bundle/src/Worker/HttpWorker.php:76)
at FluffyDiscord\RoadRunnerBundle\Worker\HttpWorker->start()
(vendor/fluffydiscord/roadrunner-symfony-bundle/src/Runtime/Runner.php:33)
at FluffyDiscord\RoadRunnerBundle\Runtime\Runner->run()
(vendor/autoload_runtime.php:29)
at require_once('/app/vendor/autoload_runtime.php')
(public/index.php:7)
|
|
[1/2]
ClientException
|
|---|
Symfony\Component\HttpClient\Exception\ClientException:
HTTP/1.1 422 Unprocessable Entity returned for "https://is.stage.glomex.cz/api/v1/product".
at vendor/symfony/http-client/Response/TraceableResponse.php:209
at Symfony\Component\HttpClient\Response\TraceableResponse->checkStatusCode()
(vendor/symfony/http-client/Response/TraceableResponse.php:100)
at Symfony\Component\HttpClient\Response\TraceableResponse->getContent()
(src/Infrastructure/Api/ApiClient.php:62)
at App\Infrastructure\Api\ApiClient->request()
(src/Domain/Product/Action/ProductList/ProductListAction.php:45)
at App\Domain\Product\Action\ProductList\ProductListAction->__invoke()
(vendor/symfony/http-kernel/HttpKernel.php:183)
at Symfony\Component\HttpKernel\HttpKernel->handleRaw()
(vendor/symfony/http-kernel/HttpKernel.php:76)
at Symfony\Component\HttpKernel\HttpKernel->handle()
(vendor/symfony/http-kernel/Kernel.php:182)
at Symfony\Component\HttpKernel\Kernel->handle()
(vendor/fluffydiscord/roadrunner-symfony-bundle/src/Worker/HttpWorker.php:76)
at FluffyDiscord\RoadRunnerBundle\Worker\HttpWorker->start()
(vendor/fluffydiscord/roadrunner-symfony-bundle/src/Runtime/Runner.php:33)
at FluffyDiscord\RoadRunnerBundle\Runtime\Runner->run()
(vendor/autoload_runtime.php:29)
at require_once('/app/vendor/autoload_runtime.php')
(public/index.php:7)
|