I've the following errors while reverting my features:

Do you really want to revert node_export_features? (y/n): y
WD node: PDOException: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry '' for key 'uri': INSERT INTO {file_managed}          [error]
(filesize, status, timestamp, type, uuid) VALUES (:db_insert_placeholder_0, :db_insert_placeholder_1, :db_insert_placeholder_2,
:db_insert_placeholder_3, :db_insert_placeholder_4); Array
(
    [:db_insert_placeholder_0] => 0
    [:db_insert_placeholder_1] => 1
    [:db_insert_placeholder_2] => 1376301148
    [:db_insert_placeholder_3] => default
    [:db_insert_placeholder_4] => 7443aa8a-62fc-421d-b129-16d2f81810bd
)
 in drupal_write_record() (line 7166 of includes/common.inc).
WD php: PDOException: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry '' for key 'uri': INSERT INTO {file_managed} (filesize,[error]
status, timestamp, type, uuid) VALUES (:db_insert_placeholder_0, :db_insert_placeholder_1, :db_insert_placeholder_2, :db_insert_placeholder_3,
:db_insert_placeholder_4); Array
(
    [:db_insert_placeholder_0] => 0
    [:db_insert_placeholder_1] => 1
    [:db_insert_placeholder_2] => 1376301148
    [:db_insert_placeholder_3] => default
    [:db_insert_placeholder_4] => 7443aa8a-62fc-421d-b129-16d2f81810bd
)
 in drupal_write_record() (line 7166 of includes/common.inc).
Cannot modify header information - headers already sent by (output started at /usr/local/Cellar/drush/5.8/libexec/includes/output.inc:37)          [warning]
bootstrap.inc:1216
Drush command terminated abnormally due to an unrecoverable error.                                                                                 [error]
Error: Xdebug MUST be loaded as a Zend extension in Unknown, line 0
PDOException: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry '' for key 'uri': INSERT INTO {file_managed} (filesize, status, timestamp, type, uuid) VALUES (:db_insert_placeholder_0, :db_insert_placeholder_1, :db_insert_placeholder_2, :db_insert_placeholder_3, :db_insert_placeholder_4); Array
(
    [:db_insert_placeholder_0] => 0
    [:db_insert_placeholder_1] => 1
    [:db_insert_placeholder_2] => 1376301148
    [:db_insert_placeholder_3] => default
    [:db_insert_placeholder_4] => 7443aa8a-62fc-421d-b129-16d2f81810bd
)
 in drupal_write_record() (line 7166 of includes/common.inc).

But in my case, patch didn't fix the problem.

Info file:

features[node_export_features][] = 5ecc61e3-82d6-4e15-b21d-fc5d3b0b6f10

foo.features.node_export_features.inc

function foo_node_export_features_default() {
  $node_export = array(
  'code_string' => 'array(
  (object) array(
      \'vid\' => \'164\',
      \'uid\' => \'0\',
      \'title\' => \'Title.\',
      \'log\' => \'\',
      \'status\' => \'1\',
      \'comment\' => \'1\',
      \'promote\' => \'0\',
      \'sticky\' => \'0\',
      \'vuuid\' => \'caf18b04-b05f-44ba-9a0e-891fb853be9f\',
      \'nid\' => \'132\',
      \'type\' => \'homepage_feature_panel\',
      \'language\' => \'en\',
      \'created\' => \'1376274814\',
      \'changed\' => \'1376274814\',
      \'tnid\' => \'0\',
      \'translate\' => \'0\',
      \'uuid\' => \'5ecc61e3-82d6-4e15-b21d-fc5d3b0b6f10\',
      \'revision_timestamp\' => \'1376274814\',
      \'revision_uid\' => \'0\',
      \'field_hpp_image\' => array(
        \'und\' => array(
          array(
            \'fid\' => \'12\',
            \'alt\' => NULL,
            \'title\' => NULL,
            \'width\' => \'1600\',
            \'height\' => \'719\',
            \'uid\' => \'1\',
            \'filename\' => \'masthead.jpg\',
            \'uri\' => \'public://masthead_0.jpg\',
            \'filemime\' => \'image/jpeg\',
            \'filesize\' => \'212217\',
            \'status\' => \'1\',
            \'timestamp\' => \'1376274814\',
            \'type\' => \'image\',
            \'language\' => \'und\',
            \'i18n_tsid\' => \'0\',
            \'uuid\' => \'bfc074a6-3132-4dff-b845-e9cb7daa29a5\',
            \'field_file_image_alt_text\' => array(),
            \'field_file_image_title_text\' => array(),
            \'field_folder\' => array(),
            \'rdf_mapping\' => array(),
          ),
        ),
      ),
      \'field_link\' => array(
        \'und\' => array(
          array(
            \'value\' => \'http://\',
            \'format\' => NULL,
            \'safe_value\' => \'http://\',
          ),
        ),
...
      \'name\' => \'\',
      \'picture\' => \'0\',
      \'data\' => NULL,
      \'num_revisions\' => \'2\',
      \'current_revision_id\' => \'164\',
      \'is_current\' => TRUE,
      \'is_pending\' => FALSE,
      \'revision_moderation\' => FALSE,
      \'path\' => array(
        \'pid\' => \'156\',
        \'source\' => \'node/132\',
        \'alias\' => \'content/perfect-duo-0\',
        \'language\' => \'en\',
      ),
      \'menu\' => NULL,
      \'node_export_drupal_version\' => \'7\',
    ),
)',
);^M
  return $node_export;
}

Comments

danielb’s picture

Status: Active » Closed (outdated)

Let me know if this is still a relevant issue.