πŸ‡ͺπŸ‡ΈSpain @tahiche

Account created on 14 May 2010, almost 15 years ago
#

Recent comments

πŸ‡ͺπŸ‡ΈSpain tahiche

I'm getting the same database connection errors as pointed above:

Fatal error: Uncaught TypeError: Drupal\Core\Database\StatementWrapperIterator::__construct(): Argument #2 ($clientConnection) must b  
  e of type object, null given, called in /var/www/site/web/core/lib/Drupal/Core/Database/Connection.php on line 557 and defined in /va  
  r/www/site/web/core/lib/Drupal/Core/Database/StatementWrapperIterator.php on line 54                                                   
                                                                                                                                         
  TypeError: Drupal\Core\Database\StatementWrapperIterator::__construct(): Argument #2 ($clientConnection) must be of type object, null  
   given, called in /var/www/site/web/core/lib/Drupal/Core/Database/Connection.php on line 557 in /var/www/site/web/core/lib/Drupal/Cor  
  e/Database/StatementWrapperIterator.php on line 54 

As far as i can tell, this error started happening at some point and i canΓ±t get it go go away.
I've tried downgrading to purge 3.4 from 3.6 but i'm still getting te error. Also applying patches in this post has not solved the issue.
The error comes up during config-import or any operation invlving my processor, which in my case is varnish_purger.
If i disabel the Varnish Purger processor i get no error. As soon as i enable it via UI or config import i get the error.

I'm clearing the purge cache on node update via a node_update hook, so in fact this is blocking content editing.

Step debugging the code everything seems normal, i can't find the exact spot where this exception happens.
It also happens on drush cr.

Seems to be some query on cache_config table that is passing a null connection. I guess it has to do with the purge_drush module as it seems very similar. But I'm lost here.

protected readonly Drupal\Core\Database\Connection $connection = ... }; protected $needsCleanup = FALSE; private $serverVersion = NULL }, $clientConnection = NULL, $query = 'SELECT "cid", "data", "created", "expire", "serialized", "tags", "checksum" FROM "SITE-PREXIX_cache_config" WHERE "cid" IN ( :cids__0 ) ORDER BY "cid"', $options = [], $rowCountEnabled = FALSE) /var/www/site/web/core/lib/Drupal/Core/Database/Connection.php:557

πŸ‡ͺπŸ‡ΈSpain tahiche

Hi,
After noticing the module didn't work with Drush 12 i went ahead and did a quick test to see if i could fix it.
It seems to be working now. basically changed it to extend DrushCommands isntead of DeployHookCommands which seemed to be the breaking issue with Drush 12.

πŸ‡ͺπŸ‡ΈSpain tahiche

IΒ΄m a total contributing noob, but i wanted to share a patch based on the above fork, in cas it helps anyone...
It applies to the "8.x-1.5" version.

Production build 0.71.5 2024