Forwarded to ErrorController (fda29c)

Exceptions

EasyCorp\Bundle\EasyAdminBundle\Dto\BatchActionDto::__construct(): Argument #1 ($name) must be of type string, null given, called in /var/www/vhosts/classic-rent.fr/admin.classic-rent.fr/vendor/easycorp/easyadmin-bundle/src/ArgumentResolver/BatchActionDtoResolver.php on line 39

Exception

TypeError

  1. private array $entityIds;
  2. private string $entityFqcn;
  3. private string $referrerUrl;
  4. private string $csrfToken;
  5. public function __construct(string $name, array $entityIds, string $entityFqcn, string $referrerUrl, string $csrfToken /* , bool $triggerDeprecation = true */)
  6. {
  7. $this->name = $name;
  8. $this->entityIds = $entityIds;
  9. $this->entityFqcn = $entityFqcn;
  1. if (null === $context = $this->adminContextProvider->getContext()) {
  2. throw new \RuntimeException(sprintf('Some of your controller actions have type-hinted an argument with the "%s" class but that\'s only available for actions run to serve EasyAdmin requests. Remove the type-hint or make sure the action is part of an EasyAdmin request.', BatchActionDto::class));
  3. }
  4. yield new BatchActionDto(
  5. $context->getRequest()->request->get(EA::BATCH_ACTION_NAME),
  6. $context->getRequest()->request->all()[EA::BATCH_ACTION_ENTITY_IDS] ?? [],
  7. $context->getRequest()->request->get(EA::ENTITY_FQCN),
  8. $this->getReferrerUrl($context, $request),
  9. $context->getRequest()->request->get(EA::BATCH_ACTION_CSRF_TOKEN),
  1. public function resolve(Request $request, ArgumentMetadata $argument): iterable
  2. {
  3. $method = $this->inner::class.'::'.__FUNCTION__;
  4. $this->stopwatch->start($method, 'controller.argument_value_resolver');
  5. yield from $this->inner->resolve($request, $argument);
  6. $this->stopwatch->stop($method);
  7. }
  8. }
  1. continue;
  2. }
  3. try {
  4. $count = 0;
  5. foreach ($resolver->resolve($request, $metadata) as $argument) {
  6. ++$count;
  7. $arguments[] = $argument;
  8. }
  9. } catch (NearMissValueResolverException $e) {
  10. $valueResolverExceptions[] = $e;
  1. public function getArguments(Request $request, callable $controller, ?\ReflectionFunctionAbstract $reflector = null): array
  2. {
  3. $e = $this->stopwatch->start('controller.get_arguments');
  4. try {
  5. return $this->resolver->getArguments($request, $controller, $reflector);
  6. } finally {
  7. $e->stop();
  8. }
  9. }
  10. }
in vendor/symfony/http-kernel/HttpKernel.php -> getArguments (line 175)
  1. $event = new ControllerEvent($this, $controller, $request, $type);
  2. $this->dispatcher->dispatch($event, KernelEvents::CONTROLLER);
  3. $controller = $event->getController();
  4. // controller arguments
  5. $arguments = $this->argumentResolver->getArguments($request, $controller, $event->getControllerReflector());
  6. $event = new ControllerArgumentsEvent($this, $event, $arguments, $request, $type);
  7. $this->dispatcher->dispatch($event, KernelEvents::CONTROLLER_ARGUMENTS);
  8. $controller = $event->getController();
  9. $arguments = $event->getArguments();
  1. $request->headers->set('X-Php-Ob-Level', (string) ob_get_level());
  2. $this->requestStack->push($request);
  3. $response = null;
  4. try {
  5. return $response = $this->handleRaw($request, $type);
  6. } catch (\Throwable $e) {
  7. if ($e instanceof \Error && !$this->handleAllThrowables) {
  8. throw $e;
  9. }
  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. ) {
  2. }
  3. public function run(): int
  4. {
  5. $response = $this->kernel->handle($this->request);
  6. if (Kernel::VERSION_ID >= 60400) {
  7. $response->send(false);
  8. if (\function_exists('fastcgi_finish_request') && !$this->debug) {
in vendor/autoload_runtime.php -> run (line 29)
  1. $app = $app(...$args);
  2. exit(
  3. $runtime
  4. ->getRunner($app)
  5. ->run()
  6. );
require_once('/var/www/vhosts/classic-rent.fr/admin.classic-rent.fr/vendor/autoload_runtime.php') in public/index.php (line 5)
  1. <?php
  2. use App\Kernel;
  3. require_once dirname(__DIR__).'/vendor/autoload_runtime.php';
  4. return function (array $context) {
  5. return new Kernel($context['APP_ENV'], (bool) $context['APP_DEBUG']);
  6. };

Logs

No log messages

Stack Trace

TypeError
TypeError:
EasyCorp\Bundle\EasyAdminBundle\Dto\BatchActionDto::__construct(): Argument #1 ($name) must be of type string, null given, called in /var/www/vhosts/classic-rent.fr/admin.classic-rent.fr/vendor/easycorp/easyadmin-bundle/src/ArgumentResolver/BatchActionDtoResolver.php on line 39

  at vendor/easycorp/easyadmin-bundle/src/Dto/BatchActionDto.php:16
  at EasyCorp\Bundle\EasyAdminBundle\Dto\BatchActionDto->__construct()
     (vendor/easycorp/easyadmin-bundle/src/ArgumentResolver/BatchActionDtoResolver.php:39)
  at EasyCorp\Bundle\EasyAdminBundle\ArgumentResolver\BatchActionDtoResolver->resolve()
     (vendor/symfony/http-kernel/Controller/ArgumentResolver/TraceableValueResolver.php:37)
  at Symfony\Component\HttpKernel\Controller\ArgumentResolver\TraceableValueResolver->resolve()
     (vendor/symfony/http-kernel/Controller/ArgumentResolver.php:90)
  at Symfony\Component\HttpKernel\Controller\ArgumentResolver->getArguments()
     (vendor/symfony/http-kernel/Controller/TraceableArgumentResolver.php:33)
  at Symfony\Component\HttpKernel\Controller\TraceableArgumentResolver->getArguments()
     (vendor/symfony/http-kernel/HttpKernel.php:175)
  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/symfony/runtime/Runner/Symfony/HttpKernelRunner.php:35)
  at Symfony\Component\Runtime\Runner\Symfony\HttpKernelRunner->run()
     (vendor/autoload_runtime.php:29)
  at require_once('/var/www/vhosts/classic-rent.fr/admin.classic-rent.fr/vendor/autoload_runtime.php')
     (public/index.php:5)