When someone tries to use "Regenerate all", a database exception appears, because:

$q3 = db_select('maesto_queue_from','a');
$q3->addField('a','from_queue_id');
$q3->condition("a.queue_id = {$active_queue_record->id}");
$queue_reporting_result = $q3->execute();
foreach ($queue_reporting_result as $queue_reporting_record) {
  $record = new stdClass();
  $record->id = $queue_reporting_record->from_queue_id;
  $record->process_id = $new_processid;
  drupal_write_record('maestro_queue',$record);
}

in maestro_engine_version1.class.php, line 160, inside MaestroEngineVersion1::newProcess();
1) It has a typo: "maesto_queue_from" instead of "maesto_queue_from". It raises an exception.
2) The drupal_write_record tries to include the ->id, which is primary key, without specifying that it's an update. It raises an exception (at least in some cases).

Comments

imaizumi’s picture

I am using the maesrto module in my drupal system.
Thank you for creating the useful module.

I read following article.

Maestro Module: To Regenerate or Not To Regenerate...
http://www.nextide.ca/maestro-regeneration

And, I tried a workflow checked Regenerate All In Production Tasks flag.
But, It did not work because of this reported bugs.

If possible, please fix it.
Thank you.

_randy’s picture

Status: Active » Needs review

Fixed the typo in git.

imaizumi’s picture

Thank you for fixing typo.

But, the following report is reproduced.

>2) The drupal_write_record tries to include the ->id, which is primary key, without specifying that it's an
update. It raises an exception (at least in some cases).

_randy’s picture

Committed a fix to dev.

_randy’s picture

Issue summary: View changes

added details on the code quote, where to find it

  • Commit 2317de9 on master, 8.x-1.x by _randy:
    Fixed typo in regenerate for issue #1281178
    
    
  • Commit b69c69b on master, 8.x-1.x by _randy:
    Fix for issue #1281178. Fix for issue with installation of Technical...
blainelang’s picture

Issue summary: View changes
Status: Needs review » Closed (fixed)