A deadlock occurs for all fields in that group that somehow gets an empty string defined for the group name.
When this deadlock happens, somehow fields that are caught inside the deadlock have two instances of themselves defined within the content_group_fields database table.
One of these contains the group they are in and the other contains an empty string for the group they are in.
Example:
content_group_fields:

     type_name     |  group_name   |  field_name        
-------------------+---------------+-----------------
 example_node_type |               | field_example
 example_node_type | group_example | field_example

This produces the following message when saving while at the overview_manage form:

pg_query(): Query failed: ERROR: duplicate key value violates unique constraint "content_group_fields_pkey" in /includes/database.pgsql.inc on line 139.

query: INSERT INTO content_group_fields (type_name, group_name, field_name) VALUES ('example_node_type', 'group_example','field_example') in /sites/all/modules/cck-3/modules/fieldgroup/fieldgroup.module on line 1064.

While I do not know how that empty string made it into the database table, I have noticed the following in fielgroup.module on line #661:

<?php
      // TODO: check the parent group does exist ?
      fieldgroup_update_fields(array('field_name' => $key, 'group' => $parent, 'type_name' => $type_name));
?>

The TODO stands out here.
I suspect that somehow $parent becomes an empty string.
Perhaps the update fieldgroup_update_fields should be wrapped in a function like the following:

<?php
      if (!empty($parent)){
            fieldgroup_update_fields(array('field_name' => $key, 'group' => $parent, 'type_name' => $type_name));
      }
      else {
            // produce some sort of error here?
      }
?>

I do have the nested_fieldgroups patch and multigroups patch applied.
The groups that locked up in this way were not multigroups.
I have searched through the nested_fieldgroups patch and did not find any added inserts to the database table content_group_fields or changes to fieldgroup_update_fields.

Comments

Vote_Sizing_Steve’s picture

Subscribing.