https://dev.m-medientechnik.de/api/_action/paypal/webhook/execute?sw-token=EUWivgmpYE2ZtS1BI5Pk7or9dXmLGITG

Exceptions

An error occurred during execution of webhook

Exception

Symfony\Component\HttpKernel\Exception\ BadRequestHttpException

  1.         } catch (WebhookException $webhookException) {
  2.             $logMessage \sprintf('[PayPal Webhook] %s'$webhookException->getMessage());
  3.             $logContext = ['type' => $webhookException->getEventType(), 'webhook' => \json_encode($webhook)];
  4.             $this->logger->error($logMessage$logContext);
  5.             throw new BadRequestHttpException('An error occurred during execution of webhook');
  6.         } catch (\Exception $e) {
  7.             $this->logger->error($e->getMessage(), ['error' => $e]);
  8.             throw new BadRequestHttpException('An error occurred during execution of webhook');
  9.         }
WebhookController->tryToExecuteWebhook() in custom/plugins/SwagPayPal/src/Webhook/WebhookController.php (line 104)
  1.     {
  2.         $token $this->getShopwareToken($request);
  3.         $this->validateShopwareToken($token$context);
  4.         $webhook $this->createWebhookFromPostData($request);
  5.         $this->tryToExecuteWebhook($context$webhook);
  6.         return new Response();
  7.     }
  8.     /**
in vendor/symfony/http-kernel/HttpKernel.php -> executeWebhook (line 163)
  1.         $this->dispatcher->dispatch($eventKernelEvents::CONTROLLER_ARGUMENTS);
  2.         $controller $event->getController();
  3.         $arguments $event->getArguments();
  4.         // call controller
  5.         $response $controller(...$arguments);
  6.         // view
  7.         if (!$response instanceof Response) {
  8.             $event = new ViewEvent($this$request$type$response);
  9.             $this->dispatcher->dispatch($eventKernelEvents::VIEW);
  1.     {
  2.         $request->headers->set('X-Php-Ob-Level', (string) ob_get_level());
  3.         $this->requestStack->push($request);
  4.         try {
  5.             return $this->handleRaw($request$type);
  6.         } catch (\Exception $e) {
  7.             if ($e instanceof RequestExceptionInterface) {
  8.                 $e = new BadRequestHttpException($e->getMessage(), $e);
  9.             }
  10.             if (false === $catch) {
  1.         $this->boot();
  2.         ++$this->requestStackSize;
  3.         $this->resetServices true;
  4.         try {
  5.             return $this->getHttpKernel()->handle($request$type$catch);
  6.         } finally {
  7.             --$this->requestStackSize;
  8.         }
  9.     }
  1.         if (!IpUtils::checkIp('127.0.0.1'$trustedProxies)) {
  2.             Request::setTrustedProxies(array_merge($trustedProxies, ['127.0.0.1']), Request::getTrustedHeaderSet());
  3.         }
  4.         try {
  5.             return $kernel->handle($request$type$catch);
  6.         } finally {
  7.             // restore global state
  8.             Request::setTrustedProxies($trustedProxies$trustedHeaderSet);
  9.         }
  10.     }
  1.         if ($this->surrogate) {
  2.             $this->surrogate->addSurrogateCapability($request);
  3.         }
  4.         // always a "master" request (as the real master request can be in cache)
  5.         $response SubRequestHandler::handle($this->kernel$requestHttpKernelInterface::MAIN_REQUEST$catch);
  6.         /*
  7.          * Support stale-if-error given on Responses or as a config option.
  8.          * RFC 7234 summarizes in Section 4.2.4 (but also mentions with the individual
  9.          * Cache-Control directives) that
  1.      */
  2.     protected function pass(Request $requestbool $catch false)
  3.     {
  4.         $this->record($request'pass');
  5.         return $this->forward($request$catch);
  6.     }
  7.     /**
  8.      * Invalidates non-safe methods (like POST, PUT, and DELETE).
  9.      *
  1.      *
  2.      * @see RFC2616 13.10
  3.      */
  4.     protected function invalidate(Request $requestbool $catch false)
  5.     {
  6.         $response $this->pass($request$catch);
  7.         // invalidate only when the response is successful
  8.         if ($response->isSuccessful() || $response->isRedirect()) {
  9.             try {
  10.                 $this->store->invalidate($request);
  1.         }
  2.         $this->traces[$this->getTraceKey($request)] = [];
  3.         if (!$request->isMethodSafe()) {
  4.             $response $this->invalidate($request$catch);
  5.         } elseif ($request->headers->has('expect') || !$request->isMethodCacheable()) {
  6.             $response $this->pass($request$catch);
  7.         } elseif ($this->options['allow_reload'] && $request->isNoCache()) {
  8.             /*
  9.                 If allow_reload is configured and the client requests "Cache-Control: no-cache",
  1.             && $container->getParameter('shopware.http.cache.enabled');
  2.         if ($enabled && $container->has(CacheStore::class)) {
  3.             $kernel = new static::$httpCacheClass($kernel$container->get(CacheStore::class), null, ['debug' => $this->debug]);
  4.         }
  5.         $response $kernel->handle($transformed$type$catch);
  6.         // fire event to trigger runtime events like seo url headers
  7.         $event = new BeforeSendResponseEvent($transformed$response);
  8.         $container->get('event_dispatcher')->dispatch($event);
in vendor/shopware/core/HttpKernel.php -> doHandle (line 81)
  1.         if (!\is_bool($catch)) {
  2.             Feature::triggerDeprecationOrThrow('v6.5.0.0''The third parameter `$catch` of `HttpKernel->handle()` will be typed to `bool`');
  3.         }
  4.         try {
  5.             return $this->doHandle($request, (int) $type, (bool) $catch);
  6.         } catch (Exception $e) {
  7.             /** @var Params|array{url?: string} $connectionParams */
  8.             $connectionParams self::getConnection()->getParams();
  9.             $message str_replace([$connectionParams['url'] ?? null$connectionParams['password'] ?? null$connectionParams['user'] ?? null], '******'$e->getMessage());
HttpKernel->handle() in public/index.php (line 85)
  1.     }
  2. } else {
  3.     $kernel = new InstallerKernel($appEnv$debug);
  4. }
  5. $result $kernel->handle($request);
  6. if ($result instanceof Response) {
  7.     $result->send();
  8.     $kernel->terminate($request$result);
  9. } else {

Logs

Level Channel Message
INFO 23:52:25 php Deprecated: Constant NumberFormatter::TYPE_CURRENCY is deprecated
{
    "exception": {}
}
INFO 23:52:25 request Matched route "_profiler".
{
    "route": "_profiler",
    "route_parameters": {
        "_route": "_profiler",
        "_controller": "web_profiler.controller.profiler::panelAction",
        "token": "633f34"
    },
    "request_uri": "https://dev.m-medientechnik.de/_profiler/633f34?panel=exception",
    "method": "GET"
}
INFO 23:52:25 php User Deprecated: Since shopware/core : Class "Shopware\Storefront\Framework\Csrf\CsrfRouteListener" is deprecated and will be removed in v6.5.0.0.
{
    "exception": {}
}
INFO 23:52:25 php User Deprecated: Since shopware/core : Class "Shopware\Storefront\Framework\Csrf\CsrfRouteListener" is deprecated and will be removed in v6.5.0.0.
{
    "exception": {}
}
INFO 23:52:25 php User Deprecated: Since shopware/core : Class "Shopware\Core\Content\Mail\Service\MailerTransportFactory" is deprecated and will be removed in v6.5.0.0.
{
    "exception": {}
}
INFO 23:52:25 php User Deprecated: Since shopware/core : Class "Shopware\Core\Content\Mail\Service\MailerTransportFactory" is deprecated and will be removed in v6.5.0.0.
{
    "exception": {}
}
INFO 23:52:25 php User Deprecated: Since shopware/core : Class "Shopware\Storefront\Framework\Csrf\CsrfRouteListener" is deprecated and will be removed in v6.5.0.0.
{
    "exception": {}
}
INFO 23:52:25 php User Deprecated: Since shopware/core : Class "Shopware\Storefront\Framework\Csrf\CsrfRouteListener" is deprecated and will be removed in v6.5.0.0.
{
    "exception": {}
}

Stack Trace

BadRequestHttpException
Symfony\Component\HttpKernel\Exception\BadRequestHttpException:
An error occurred during execution of webhook

  at custom/plugins/SwagPayPal/src/Webhook/WebhookController.php:150
  at Swag\PayPal\Webhook\WebhookController->tryToExecuteWebhook()
     (custom/plugins/SwagPayPal/src/Webhook/WebhookController.php:104)
  at Swag\PayPal\Webhook\WebhookController->executeWebhook()
     (vendor/symfony/http-kernel/HttpKernel.php:163)
  at Symfony\Component\HttpKernel\HttpKernel->handleRaw()
     (vendor/symfony/http-kernel/HttpKernel.php:75)
  at Symfony\Component\HttpKernel\HttpKernel->handle()
     (vendor/symfony/http-kernel/Kernel.php:202)
  at Symfony\Component\HttpKernel\Kernel->handle()
     (vendor/symfony/http-kernel/HttpCache/SubRequestHandler.php:86)
  at Symfony\Component\HttpKernel\HttpCache\SubRequestHandler::handle()
     (vendor/symfony/http-kernel/HttpCache/HttpCache.php:481)
  at Symfony\Component\HttpKernel\HttpCache\HttpCache->forward()
     (vendor/symfony/http-kernel/HttpCache/HttpCache.php:271)
  at Symfony\Component\HttpKernel\HttpCache\HttpCache->pass()
     (vendor/symfony/http-kernel/HttpCache/HttpCache.php:287)
  at Symfony\Component\HttpKernel\HttpCache\HttpCache->invalidate()
     (vendor/symfony/http-kernel/HttpCache/HttpCache.php:215)
  at Symfony\Component\HttpKernel\HttpCache\HttpCache->handle()
     (vendor/shopware/core/HttpKernel.php:156)
  at Shopware\Core\HttpKernel->doHandle()
     (vendor/shopware/core/HttpKernel.php:81)
  at Shopware\Core\HttpKernel->handle()
     (public/index.php:85)