Hi all,

I am trying to install commerce kickstart 2.49 (drupal core 7.56) with Mysql (Mariadb).
I always stuck with batch install when try to install Commerce Product UI.
There error is Internal Server Error with error log:

PHP Fatal error:  Uncaught PDOException: There is no active transaction in /home/andreas/workspace-php/ckickstart/includes/database/mysql/database.inc:183
Stack trace:
#0 /home/andreas/workspace-php/ckickstart/includes/database/mysql/database.inc(183): PDO->commit()
#1 /home/andreas/workspace-php/ckickstart/includes/database/database.inc(1154): DatabaseConnection_mysql->popCommittableTransactions()
#2 /home/andreas/workspace-php/ckickstart/includes/database/database.inc(1964): DatabaseConnection->popTransaction('savepoint_7')
#3 [internal function]: DatabaseTransaction->__destruct()
#4 {main}
  thrown in /home/andreas/workspace-php/ckickstart/includes/database/mysql/database.inc on line 183

When I look at the code on line 183 at includes/database/mysql/database.inc, there is this line:

if (!PDO::commit()) {
  throw new DatabaseTransactionCommitFailedException();

There is this simple improvement that make the installation work again.

if (PDO::inTransaction() && !PDO::commit()) {
  throw new DatabaseTransactionCommitFailedException();

Why the additional code PDO::inTransaction() works, because when try to commit the transaction, code always check for active transaction.

What are the steps required to reproduce the bug?
- Install commerce kickstart 2.49 in Ubuntu 16.04.1 using Zend Server Nginx PHP 7.1 version 9.1.1+b119 and MariaDB 10.1.26.
What behavior were you expecting?
- Able to install commerce kickstart without internal server error.
What happened instead?
- When install.php try to install commerce product ui, batch gives internal server error with php error above.

Hope this helps.

Members fund testing for the Drupal project. Drupal Association Learn more


andre4s_y created an issue. See original summary.

andre4s_y’s picture

Status: Needs review » Needs work

The last submitted patch, 2: 2908341-3.patch, failed testing. View results
- codesniffer_fixes.patch Interdiff of automated coding standards fixes only.

andre4s_y’s picture

Status: Needs work » Needs review

Update status. All tests passed.