VersioncontrolOperation class is not handling correctly this. That class have also a list of labels that needs to be updated in nested way as the items are handled.

Comments

marvil07’s picture

Status: Active » Fixed
StatusFileSize
new1.06 KB

Here the patch I am committing

sdboyer’s picture

Priority: Normal » Critical
Status: Fixed » Needs work
Issue tags: +git sprint 10

This fix broke the build. There's some improper detection happening somewhere, as we now see this lovely output quite a bit while parsing in d.o repos, and we only have ~18000 labels instead of the expected ~44000. Plus, it leaves all repositories locked - fail all around.

WD php: PDOException: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry '1535594-94839' for key 'PRIMARY': INSERT INTO {versioncontrol_operation_labels} (vc_op_id, label_id,     [error]
action) VALUES (:db_insert_placeholder_0, :db_insert_placeholder_1, :db_insert_placeholder_2), (:db_insert_placeholder_3, :db_insert_placeholder_4, :db_insert_placeholder_5),
(:db_insert_placeholder_6, :db_insert_placeholder_7, :db_insert_placeholder_8), (:db_insert_placeholder_9, :db_insert_placeholder_10, :db_insert_placeholder_11), (:db_insert_placeholder_12,
:db_insert_placeholder_13, :db_insert_placeholder_14), (:db_insert_placeholder_15, :db_insert_placeholder_16, :db_insert_placeholder_17); Array
(
    [:db_insert_placeholder_0] => 1535594
    [:db_insert_placeholder_1] => 94839
    [:db_insert_placeholder_2] => 2
    [:db_insert_placeholder_3] => 1535594
    [:db_insert_placeholder_4] => 94844
    [:db_insert_placeholder_5] => 2
    [:db_insert_placeholder_6] => 1535594
    [:db_insert_placeholder_7] => 94849
    [:db_insert_placeholder_8] => 2
    [:db_insert_placeholder_9] => 1535594
    [:db_insert_placeholder_10] => 94854
    [:db_insert_placeholder_11] => 2
    [:db_insert_placeholder_12] => 1535594
    [:db_insert_placeholder_13] => 94859
    [:db_insert_placeholder_14] => 2
    [:db_insert_placeholder_15] => 1535594
    [:db_insert_placeholder_16] => 94839
    [:db_insert_placeholder_17] => 2
)
 in VersioncontrolOperation->updateLabels() (line 275 of /home/sdboyer/gd/sites/all/modules/versioncontrol/includes/VersioncontrolOperation.php).

Looking at that output it seems like it ought to be dead-simple to fix, but I have other work to focus on - please take care of the problem ASAP?

marvil07’s picture

Status: Needs work » Needs review
StatusFileSize
new1.36 KB

Ok, here a patch that just revert the revert one :-p

The real problem is at git backend: #1048210: Parse commit/label relation correctly

But I also found a bug in the middle of this that is actually required too: #1048204: Avoid non-recognizing the label type on operation load at operation controller

sdboyer’s picture

Status: Needs review » Reviewed & tested by the community

Yup, with the other ones, this outta be fine now. Local tests make it look like it is.

marvil07’s picture

Status: Reviewed & tested by the community » Fixed

After committing the related issues, I committed this too!

Status: Fixed » Closed (fixed)
Issue tags: -git phase 2, -git sprint 10

Automatically closed -- issue fixed for 2 weeks with no activity.

  • Commit 88f330f on repository-families, drush-vc-sync-unlock by marvil07:
    bug #1044192 by marvil07: Update labels on nested operation entity...
  • Commit 921e6af on repository-families, drush-vc-sync-unlock by sdboyer:
    Revert "bug #1044192 by marvil07: Update labels on nested operation...
  • Commit a233257 on repository-families, drush-vc-sync-unlock by marvil07:
    Revert "Revert "bug #1044192 by marvil07: Update labels on nested...

  • Commit 88f330f on repository-families by marvil07:
    bug #1044192 by marvil07: Update labels on nested operation entity...
  • Commit 921e6af on repository-families by sdboyer:
    Revert "bug #1044192 by marvil07: Update labels on nested operation...
  • Commit a233257 on repository-families by marvil07:
    Revert "Revert "bug #1044192 by marvil07: Update labels on nested...