- 🇳🇱Netherlands arantxio Dordrecht
🐛 Multiple issues when PostgreSQL is used with non-public schema Fixed has landed.
- Status changed to Needs review
over 1 year ago 10:58am 1 May 2023 - last update
over 1 year ago Build Successful - 🇳🇱Netherlands arantxio Dordrecht
I've just created the change record and here is a patch that seems to be working correctly and also tests if it works during installation.
- last update
over 1 year ago 29,368 pass - last update
over 1 year ago 29,368 pass - last update
over 1 year ago 29,368 pass - Status changed to RTBC
over 1 year ago 12:12pm 1 May 2023 - 🇳🇱Netherlands daffie
All code changes look good to me.
The option has been added to the installer.
Testing has been added.
The default.settings.php have been updated.
The CR and Is are in order.
For me it is RTBC. - last update
over 1 year ago 29,375 pass - last update
over 1 year ago 29,379 pass - last update
over 1 year ago 29,380 pass - last update
over 1 year ago 29,381 pass - last update
over 1 year ago 29,384 pass - last update
over 1 year ago 29,389 pass 9:25 7:43 RunningThe last submitted patch, 5: 3328215-5.patch, failed testing. View results →
- last update
over 1 year ago 29,389 pass - last update
over 1 year ago 29,389 pass - last update
over 1 year ago 29,389 pass - last update
over 1 year ago 29,389 pass - 🇳🇱Netherlands arantxio Dordrecht
There was a issue with the test bot, but that seems to be resolved. Patch still applies and also tests are still succeeding. Back to RTBC.
- last update
over 1 year ago Build Successful - last update
over 1 year ago 29,396 pass, 1 fail - last update
over 1 year ago 29,400 pass - last update
over 1 year ago 29,400 pass - last update
over 1 year ago 29,399 pass, 1 fail - last update
over 1 year ago 29,401 pass - last update
over 1 year ago 29,405 pass, 4 fail - last update
over 1 year ago 29,415 pass, 1 fail - last update
over 1 year ago 29,419 pass - last update
over 1 year ago 29,421 pass - last update
over 1 year ago 29,421 pass 9:25 8:15 Running- last update
over 1 year ago 29,430 pass - last update
over 1 year ago 29,431 pass - last update
over 1 year ago 29,431 pass - last update
over 1 year ago 29,437 pass - last update
over 1 year ago 29,437 pass - last update
over 1 year ago 29,437 pass - last update
over 1 year ago 29,442 pass - last update
over 1 year ago 29,444 pass - last update
over 1 year ago 29,444 pass - last update
over 1 year ago 29,444 pass - last update
over 1 year ago 29,440 pass - last update
over 1 year ago 29,438 pass, 2 fail - last update
over 1 year ago 29,443 pass - last update
over 1 year ago 29,445 pass - last update
over 1 year ago 29,447 pass - last update
over 1 year ago 29,447 pass - last update
over 1 year ago 29,447 pass - last update
over 1 year ago 29,447 pass - Status changed to Needs work
over 1 year ago 1:29pm 21 July 2023 - 🇬🇧United Kingdom longwave UK
I was confused about where this is actually used, and why we were adding this to the documentation here, but 🐛 Multiple issues when PostgreSQL is used with non-public schema Fixed added this feature without documenting it.
-
+++ b/core/modules/pgsql/src/Driver/Database/pgsql/Install/Tasks.php @@ -313,6 +313,15 @@ public function getFormOptions(array $database) { + // PostgreSQL's Max Identifier Length Is 63 Bytes.
Title case is not appropriate here:
// PostgreSQL's maximum identifier length is 63 characters.
-
+++ b/core/modules/pgsql/tests/src/Functional/InstallerNonDefaultSchemaTest.php @@ -0,0 +1,63 @@ + if ($connection_info['default']['driver'] !== 'pgsql') { + // The schema option is only available for PostgreSQL. + $this->markTestSkipped("This test does not support the {$connection_info['default']['driver']} database driver."); + }
Is this necessary now we have per-driver tests? Why would the MySQL tests run at all if we are in a Postgres CI environment?
-
- last update
over 1 year ago 29,458 pass - 🇸🇰Slovakia poker10
Thanks for working on this.
In addition to points from @longwave, there is at least one additional issue with the patch.
The new schema input field is not required. Therefore it could be left blank. In case you left that input blank, Drupal will not install, but throws an error:
Failed to CREATE a test table on your database server with the command CREATE TABLE {drupal_install_test} (id int NOT NULL PRIMARY KEY). The server reports the following message: SQLSTATE[42601]: Syntax error: 7 ERROR: zero-length delimited identifier at or near """" LINE 1: CREATE TABLE ""."drupal_install_test" (id int NOT NULL PRIMA... ^: CREATE TABLE ""."drupal_install_test" (id int NOT NULL PRIMARY KEY); Array ( ) .
When we compare it with the port input field, which is not required as well, Drupal will install in case you leave the port field empty. Therefore we need to either mark the schema field as required, or fix the additional handling of the value in case it is left empty (and use
public
instead).I have not tested this further with empty schema in settings.php (whether the default
public
is used in this case as well), but will do it after the installation process will be working.Not sure about the "Needs backport to D7" tag - I think, that the D7 is not working 100% correctly on schema different from public (it was not fixed unlike the D10), so probably there is no point in addressing this in D7 unless the schema usage has been fixed.