DBAL 3 - #8964
Conversation
0c70104 to
f788f6f
Compare
|
I don't understand the failure on Postgres. The test passes locally. 🤔 |
|
I do reproduce the failure locally. I use php 7.4 |
|
This might be a new issue introduced in doctrine/dbal#4082 … I don't understand why it only affects PostgreSQL though. public function getDatabase(Connection $conn)
{
$params = $conn->getParams();
return $params['dbname'] ?? $conn->query('SELECT CURRENT_DATABASE()')->fetchOne();
}Now it results in
|
|
I'm currently working on a fix, we have the database name in |
1c59511 to
baafb1a
Compare
|
Pushed the fix :) |
baafb1a to
dd5ca3f
Compare
|
We're green. The PR is ready, but because I've added a new parameter to various PHPUnit jobs, GitHub is waiting for jobs that don't exist anymore. |
|
Yes. We will have to tweak the settings, and it's going to be a bit complicated because we will have to do so for 2.10.x and 3.x but not for 2.9.x . |
|
Shall I add |
Getting the database name from a connection object results in a PDO object being created, which might in turn result in an error message if the database does not exist. For instance it does with PostgreSQL. In some other situations, like when using sqlite, there is no database name though, so we still have to fallback on the previous behavior.
dd5ca3f to
efbcca3
Compare
|
see #8965 |
|
Thanks @derrabus ! That was impressive! |
Fixes #8884, #8885.