Exceptions
Exceptions 3
Doctrine\DBAL\Exception\ ConnectionException
case 1370:
case 1429:
case 2002:
case 2005:
case 2054:
return new ConnectionException($exception, $query);
case 2006:
return new ConnectionLost($exception, $query);
case 1048:
in
vendor/doctrine/dbal/src/Connection.php
->
convert
(line 1813)
): DriverException {
if ($this->exceptionConverter === null) {
$this->exceptionConverter = $this->_driver->getExceptionConverter();
}
$exception = $this->exceptionConverter->convert($driverException, $query);
if ($exception instanceof ConnectionLost) {
$this->close();
}
in
vendor/doctrine/dbal/src/Connection.php
->
handleDriverException
(line 1756)
/**
* @internal
*/
final public function convertException(Driver\Exception $e): DriverException
{
return $this->handleDriverException($e, null);
}
/**
* @param array<int, mixed>|array<string, mixed> $params
* @param array<int, int|string|Type|null>|array<string, int|string|Type|null> $types
in
vendor/doctrine/dbal/src/Connection.php
->
convertException
(line 342)
}
try {
$this->_conn = $this->_driver->connect($this->params);
} catch (Driver\Exception $e) {
throw $this->convertException($e);
}
if ($this->autoCommit === false) {
$this->beginTransaction();
}
in
vendor/doctrine/dbal/src/Connection.php
->
connect
(line 1530)
'https://github.com/doctrine/dbal/issues/4966',
'Connection::getWrappedConnection() is deprecated.'
. ' Use Connection::getNativeConnection() to access the native connection.'
);
$this->connect();
assert($this->_conn !== null);
return $this->_conn;
}
in
vendor/doctrine/dbal/src/Connection.php
->
getWrappedConnection
(line 1028)
): Result {
if ($qcp !== null) {
return $this->executeCacheQuery($sql, $params, $types, $qcp);
}
$connection = $this->getWrappedConnection();
$logger = $this->_config->getSQLLogger();
if ($logger !== null) {
$logger->startQuery($sql, $params, $types);
}
in
vendor/doctrine/orm/lib/Doctrine/ORM/Persisters/Entity/BasicEntityPersister.php
->
executeQuery
(line 913)
{
$this->switchPersisterContext($offset, $limit);
$sql = $this->getSelectSQL($criteria, null, null, $limit, $offset, $orderBy);
[$params, $types] = $this->expandParameters($criteria);
$stmt = $this->conn->executeQuery($sql, $params, $types);
$hydrator = $this->em->newHydrator($this->currentPersisterContext->selectJoinSql ? Query::HYDRATE_OBJECT : Query::HYDRATE_SIMPLEOBJECT);
return $hydrator->hydrateAll($stmt, $this->currentPersisterContext->rsm, [UnitOfWork::HINT_DEFEREAGERLOAD => true]);
}
in
vendor/doctrine/orm/lib/Doctrine/ORM/EntityRepository.php
->
loadAll
(line 203)
*/
public function findBy(array $criteria, ?array $orderBy = null, $limit = null, $offset = null)
{
$persister = $this->_em->getUnitOfWork()->getEntityPersister($this->_entityName);
return $persister->loadAll($criteria, $orderBy, $limit, $offset);
}
/**
* Finds a single entity by a set of criteria.
*
/**
* @Route("/", name="home")
*/
public function index(Request $request): Response
{
$panels = $this->panelRepository->findBy(['free' => true]);
$images = Array();
$default = "assets/images/panels/default.png";
$type = $request->query->get("type");
foreach($panels as $key=>$panel)
{
in
vendor/symfony/http-kernel/HttpKernel.php
->
index
(line 152)
$this->dispatcher->dispatch($event, KernelEvents::CONTROLLER_ARGUMENTS);
$controller = $event->getController();
$arguments = $event->getArguments();
// call controller
$response = $controller(...$arguments);
// view
if (!$response instanceof Response) {
$event = new ViewEvent($this, $request, $type, $response);
$this->dispatcher->dispatch($event, KernelEvents::VIEW);
in
vendor/symfony/http-kernel/HttpKernel.php
->
handleRaw
(line 74)
public function handle(Request $request, int $type = HttpKernelInterface::MAIN_REQUEST, bool $catch = true): Response
{
$request->headers->set('X-Php-Ob-Level', (string) ob_get_level());
try {
return $this->handleRaw($request, $type);
} catch (\Exception $e) {
if ($e instanceof RequestExceptionInterface) {
$e = new BadRequestHttpException($e->getMessage(), $e);
}
if (false === $catch) {
in
vendor/symfony/http-kernel/Kernel.php
->
handle
(line 202)
$this->boot();
++$this->requestStackSize;
$this->resetServices = true;
try {
return $this->getHttpKernel()->handle($request, $type, $catch);
} finally {
--$this->requestStackSize;
}
}
in
vendor/symfony/runtime/Runner/Symfony/HttpKernelRunner.php
->
handle
(line 35)
$this->request = $request;
}
public function run(): int
{
$response = $this->kernel->handle($this->request);
$response->send();
if ($this->kernel instanceof TerminableInterface) {
$this->kernel->terminate($this->request, $response);
}
in
vendor/autoload_runtime.php
->
run
(line 29)
$app = $app(...$args);
exit(
$runtime
->getRunner($app)
->run()
);
require_once('/var/www/sites/wecodx/pubup/vendor/autoload_runtime.php')
in
public/index.php
(line 5)
<?php
use App\Kernel;
require_once dirname(__DIR__).'/vendor/autoload_runtime.php';
return function (array $context) {
return new Kernel($context['APP_ENV'], (bool) $context['APP_DEBUG']);
};
Doctrine\DBAL\Driver\PDO\ Exception
in
vendor/doctrine/dbal/src/Driver/PDO/Exception.php
(line 30)
} else {
$code = $exception->getCode();
$sqlState = null;
}
return new self($exception->getMessage(), $sqlState, $code, $exception);
}
}
in
vendor/doctrine/dbal/src/Driver/PDO/MySQL/Driver.php
::
new
(line 34)
$params['user'] ?? '',
$params['password'] ?? '',
$driverOptions
);
} catch (PDOException $exception) {
throw Exception::new($exception);
}
return new Connection($pdo);
}
in
vendor/doctrine/dbal/src/Connection.php
->
connect
(line 340)
if ($this->_conn !== null) {
return false;
}
try {
$this->_conn = $this->_driver->connect($this->params);
} catch (Driver\Exception $e) {
throw $this->convertException($e);
}
if ($this->autoCommit === false) {
in
vendor/doctrine/dbal/src/Connection.php
->
connect
(line 1530)
'https://github.com/doctrine/dbal/issues/4966',
'Connection::getWrappedConnection() is deprecated.'
. ' Use Connection::getNativeConnection() to access the native connection.'
);
$this->connect();
assert($this->_conn !== null);
return $this->_conn;
}
in
vendor/doctrine/dbal/src/Connection.php
->
getWrappedConnection
(line 1028)
): Result {
if ($qcp !== null) {
return $this->executeCacheQuery($sql, $params, $types, $qcp);
}
$connection = $this->getWrappedConnection();
$logger = $this->_config->getSQLLogger();
if ($logger !== null) {
$logger->startQuery($sql, $params, $types);
}
in
vendor/doctrine/orm/lib/Doctrine/ORM/Persisters/Entity/BasicEntityPersister.php
->
executeQuery
(line 913)
{
$this->switchPersisterContext($offset, $limit);
$sql = $this->getSelectSQL($criteria, null, null, $limit, $offset, $orderBy);
[$params, $types] = $this->expandParameters($criteria);
$stmt = $this->conn->executeQuery($sql, $params, $types);
$hydrator = $this->em->newHydrator($this->currentPersisterContext->selectJoinSql ? Query::HYDRATE_OBJECT : Query::HYDRATE_SIMPLEOBJECT);
return $hydrator->hydrateAll($stmt, $this->currentPersisterContext->rsm, [UnitOfWork::HINT_DEFEREAGERLOAD => true]);
}
in
vendor/doctrine/orm/lib/Doctrine/ORM/EntityRepository.php
->
loadAll
(line 203)
*/
public function findBy(array $criteria, ?array $orderBy = null, $limit = null, $offset = null)
{
$persister = $this->_em->getUnitOfWork()->getEntityPersister($this->_entityName);
return $persister->loadAll($criteria, $orderBy, $limit, $offset);
}
/**
* Finds a single entity by a set of criteria.
*
/**
* @Route("/", name="home")
*/
public function index(Request $request): Response
{
$panels = $this->panelRepository->findBy(['free' => true]);
$images = Array();
$default = "assets/images/panels/default.png";
$type = $request->query->get("type");
foreach($panels as $key=>$panel)
{
in
vendor/symfony/http-kernel/HttpKernel.php
->
index
(line 152)
$this->dispatcher->dispatch($event, KernelEvents::CONTROLLER_ARGUMENTS);
$controller = $event->getController();
$arguments = $event->getArguments();
// call controller
$response = $controller(...$arguments);
// view
if (!$response instanceof Response) {
$event = new ViewEvent($this, $request, $type, $response);
$this->dispatcher->dispatch($event, KernelEvents::VIEW);
in
vendor/symfony/http-kernel/HttpKernel.php
->
handleRaw
(line 74)
public function handle(Request $request, int $type = HttpKernelInterface::MAIN_REQUEST, bool $catch = true): Response
{
$request->headers->set('X-Php-Ob-Level', (string) ob_get_level());
try {
return $this->handleRaw($request, $type);
} catch (\Exception $e) {
if ($e instanceof RequestExceptionInterface) {
$e = new BadRequestHttpException($e->getMessage(), $e);
}
if (false === $catch) {
in
vendor/symfony/http-kernel/Kernel.php
->
handle
(line 202)
$this->boot();
++$this->requestStackSize;
$this->resetServices = true;
try {
return $this->getHttpKernel()->handle($request, $type, $catch);
} finally {
--$this->requestStackSize;
}
}
in
vendor/symfony/runtime/Runner/Symfony/HttpKernelRunner.php
->
handle
(line 35)
$this->request = $request;
}
public function run(): int
{
$response = $this->kernel->handle($this->request);
$response->send();
if ($this->kernel instanceof TerminableInterface) {
$this->kernel->terminate($this->request, $response);
}
in
vendor/autoload_runtime.php
->
run
(line 29)
$app = $app(...$args);
exit(
$runtime
->getRunner($app)
->run()
);
require_once('/var/www/sites/wecodx/pubup/vendor/autoload_runtime.php')
in
public/index.php
(line 5)
<?php
use App\Kernel;
require_once dirname(__DIR__).'/vendor/autoload_runtime.php';
return function (array $context) {
return new Kernel($context['APP_ENV'], (bool) $context['APP_DEBUG']);
};
PDOException
in
vendor/doctrine/dbal/src/Driver/PDO/MySQL/Driver.php
(line 27)
if (! empty($params['persistent'])) {
$driverOptions[PDO::ATTR_PERSISTENT] = true;
}
try {
$pdo = new PDO(
$this->constructPdoDsn($params),
$params['user'] ?? '',
$params['password'] ?? '',
$driverOptions
);
in
vendor/doctrine/dbal/src/Driver/PDO/MySQL/Driver.php
->
__construct
(line 27)
if (! empty($params['persistent'])) {
$driverOptions[PDO::ATTR_PERSISTENT] = true;
}
try {
$pdo = new PDO(
$this->constructPdoDsn($params),
$params['user'] ?? '',
$params['password'] ?? '',
$driverOptions
);
in
vendor/doctrine/dbal/src/Connection.php
->
connect
(line 340)
if ($this->_conn !== null) {
return false;
}
try {
$this->_conn = $this->_driver->connect($this->params);
} catch (Driver\Exception $e) {
throw $this->convertException($e);
}
if ($this->autoCommit === false) {
in
vendor/doctrine/dbal/src/Connection.php
->
connect
(line 1530)
'https://github.com/doctrine/dbal/issues/4966',
'Connection::getWrappedConnection() is deprecated.'
. ' Use Connection::getNativeConnection() to access the native connection.'
);
$this->connect();
assert($this->_conn !== null);
return $this->_conn;
}
in
vendor/doctrine/dbal/src/Connection.php
->
getWrappedConnection
(line 1028)
): Result {
if ($qcp !== null) {
return $this->executeCacheQuery($sql, $params, $types, $qcp);
}
$connection = $this->getWrappedConnection();
$logger = $this->_config->getSQLLogger();
if ($logger !== null) {
$logger->startQuery($sql, $params, $types);
}
in
vendor/doctrine/orm/lib/Doctrine/ORM/Persisters/Entity/BasicEntityPersister.php
->
executeQuery
(line 913)
{
$this->switchPersisterContext($offset, $limit);
$sql = $this->getSelectSQL($criteria, null, null, $limit, $offset, $orderBy);
[$params, $types] = $this->expandParameters($criteria);
$stmt = $this->conn->executeQuery($sql, $params, $types);
$hydrator = $this->em->newHydrator($this->currentPersisterContext->selectJoinSql ? Query::HYDRATE_OBJECT : Query::HYDRATE_SIMPLEOBJECT);
return $hydrator->hydrateAll($stmt, $this->currentPersisterContext->rsm, [UnitOfWork::HINT_DEFEREAGERLOAD => true]);
}
in
vendor/doctrine/orm/lib/Doctrine/ORM/EntityRepository.php
->
loadAll
(line 203)
*/
public function findBy(array $criteria, ?array $orderBy = null, $limit = null, $offset = null)
{
$persister = $this->_em->getUnitOfWork()->getEntityPersister($this->_entityName);
return $persister->loadAll($criteria, $orderBy, $limit, $offset);
}
/**
* Finds a single entity by a set of criteria.
*
/**
* @Route("/", name="home")
*/
public function index(Request $request): Response
{
$panels = $this->panelRepository->findBy(['free' => true]);
$images = Array();
$default = "assets/images/panels/default.png";
$type = $request->query->get("type");
foreach($panels as $key=>$panel)
{
in
vendor/symfony/http-kernel/HttpKernel.php
->
index
(line 152)
$this->dispatcher->dispatch($event, KernelEvents::CONTROLLER_ARGUMENTS);
$controller = $event->getController();
$arguments = $event->getArguments();
// call controller
$response = $controller(...$arguments);
// view
if (!$response instanceof Response) {
$event = new ViewEvent($this, $request, $type, $response);
$this->dispatcher->dispatch($event, KernelEvents::VIEW);
in
vendor/symfony/http-kernel/HttpKernel.php
->
handleRaw
(line 74)
public function handle(Request $request, int $type = HttpKernelInterface::MAIN_REQUEST, bool $catch = true): Response
{
$request->headers->set('X-Php-Ob-Level', (string) ob_get_level());
try {
return $this->handleRaw($request, $type);
} catch (\Exception $e) {
if ($e instanceof RequestExceptionInterface) {
$e = new BadRequestHttpException($e->getMessage(), $e);
}
if (false === $catch) {
in
vendor/symfony/http-kernel/Kernel.php
->
handle
(line 202)
$this->boot();
++$this->requestStackSize;
$this->resetServices = true;
try {
return $this->getHttpKernel()->handle($request, $type, $catch);
} finally {
--$this->requestStackSize;
}
}
in
vendor/symfony/runtime/Runner/Symfony/HttpKernelRunner.php
->
handle
(line 35)
$this->request = $request;
}
public function run(): int
{
$response = $this->kernel->handle($this->request);
$response->send();
if ($this->kernel instanceof TerminableInterface) {
$this->kernel->terminate($this->request, $response);
}
in
vendor/autoload_runtime.php
->
run
(line 29)
$app = $app(...$args);
exit(
$runtime
->getRunner($app)
->run()
);
require_once('/var/www/sites/wecodx/pubup/vendor/autoload_runtime.php')
in
public/index.php
(line 5)
<?php
use App\Kernel;
require_once dirname(__DIR__).'/vendor/autoload_runtime.php';
return function (array $context) {
return new Kernel($context['APP_ENV'], (bool) $context['APP_DEBUG']);
};
Stack Traces 3
[3/3]
ConnectionException
|
---|
Doctrine\DBAL\Exception\ConnectionException: An exception occurred in the driver: SQLSTATE[HY000] [1045] Access denied for user 'wecodx-aws'@'localhost' (using password: YES) at vendor/doctrine/dbal/src/Driver/API/MySQL/ExceptionConverter.php:103 at Doctrine\DBAL\Driver\API\MySQL\ExceptionConverter->convert() (vendor/doctrine/dbal/src/Connection.php:1813) at Doctrine\DBAL\Connection->handleDriverException() (vendor/doctrine/dbal/src/Connection.php:1756) at Doctrine\DBAL\Connection->convertException() (vendor/doctrine/dbal/src/Connection.php:342) at Doctrine\DBAL\Connection->connect() (vendor/doctrine/dbal/src/Connection.php:1530) at Doctrine\DBAL\Connection->getWrappedConnection() (vendor/doctrine/dbal/src/Connection.php:1028) at Doctrine\DBAL\Connection->executeQuery() (vendor/doctrine/orm/lib/Doctrine/ORM/Persisters/Entity/BasicEntityPersister.php:913) at Doctrine\ORM\Persisters\Entity\BasicEntityPersister->loadAll() (vendor/doctrine/orm/lib/Doctrine/ORM/EntityRepository.php:203) at Doctrine\ORM\EntityRepository->findBy() (src/Controller/HomeController.php:64) at App\Controller\HomeController->index() (vendor/symfony/http-kernel/HttpKernel.php:152) at Symfony\Component\HttpKernel\HttpKernel->handleRaw() (vendor/symfony/http-kernel/HttpKernel.php:74) at Symfony\Component\HttpKernel\HttpKernel->handle() (vendor/symfony/http-kernel/Kernel.php:202) 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/sites/wecodx/pubup/vendor/autoload_runtime.php') (public/index.php:5) |
[2/3]
Exception
|
---|
Doctrine\DBAL\Driver\PDO\Exception: SQLSTATE[HY000] [1045] Access denied for user 'wecodx-aws'@'localhost' (using password: YES) at vendor/doctrine/dbal/src/Driver/PDO/Exception.php:30 at Doctrine\DBAL\Driver\PDO\Exception::new() (vendor/doctrine/dbal/src/Driver/PDO/MySQL/Driver.php:34) at Doctrine\DBAL\Driver\PDO\MySQL\Driver->connect() (vendor/doctrine/dbal/src/Connection.php:340) at Doctrine\DBAL\Connection->connect() (vendor/doctrine/dbal/src/Connection.php:1530) at Doctrine\DBAL\Connection->getWrappedConnection() (vendor/doctrine/dbal/src/Connection.php:1028) at Doctrine\DBAL\Connection->executeQuery() (vendor/doctrine/orm/lib/Doctrine/ORM/Persisters/Entity/BasicEntityPersister.php:913) at Doctrine\ORM\Persisters\Entity\BasicEntityPersister->loadAll() (vendor/doctrine/orm/lib/Doctrine/ORM/EntityRepository.php:203) at Doctrine\ORM\EntityRepository->findBy() (src/Controller/HomeController.php:64) at App\Controller\HomeController->index() (vendor/symfony/http-kernel/HttpKernel.php:152) at Symfony\Component\HttpKernel\HttpKernel->handleRaw() (vendor/symfony/http-kernel/HttpKernel.php:74) at Symfony\Component\HttpKernel\HttpKernel->handle() (vendor/symfony/http-kernel/Kernel.php:202) 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/sites/wecodx/pubup/vendor/autoload_runtime.php') (public/index.php:5) |
[1/3]
PDOException
|
---|
PDOException: SQLSTATE[HY000] [1045] Access denied for user 'wecodx-aws'@'localhost' (using password: YES) at vendor/doctrine/dbal/src/Driver/PDO/MySQL/Driver.php:27 at PDO->__construct() (vendor/doctrine/dbal/src/Driver/PDO/MySQL/Driver.php:27) at Doctrine\DBAL\Driver\PDO\MySQL\Driver->connect() (vendor/doctrine/dbal/src/Connection.php:340) at Doctrine\DBAL\Connection->connect() (vendor/doctrine/dbal/src/Connection.php:1530) at Doctrine\DBAL\Connection->getWrappedConnection() (vendor/doctrine/dbal/src/Connection.php:1028) at Doctrine\DBAL\Connection->executeQuery() (vendor/doctrine/orm/lib/Doctrine/ORM/Persisters/Entity/BasicEntityPersister.php:913) at Doctrine\ORM\Persisters\Entity\BasicEntityPersister->loadAll() (vendor/doctrine/orm/lib/Doctrine/ORM/EntityRepository.php:203) at Doctrine\ORM\EntityRepository->findBy() (src/Controller/HomeController.php:64) at App\Controller\HomeController->index() (vendor/symfony/http-kernel/HttpKernel.php:152) at Symfony\Component\HttpKernel\HttpKernel->handleRaw() (vendor/symfony/http-kernel/HttpKernel.php:74) at Symfony\Component\HttpKernel\HttpKernel->handle() (vendor/symfony/http-kernel/Kernel.php:202) 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/sites/wecodx/pubup/vendor/autoload_runtime.php') (public/index.php:5) |