When the File Entity module (required by the Media project) is enabled, the following exception is raised after you create an import:

EntityMalformedException: Missing bundle property on entity of type file. in entity_extract_ids() (line 7647 of /var/www/drupal-7.x-dev/includes/common.inc).

Steps to reproduce:

  1. Install standard Drupal 7.x-dev
  2. Download and install media + user_import
  3. Enable file_entity + user_import
  4. Go to People > Import > New Import and create a first import
  5. Go to People > List Imports

Quick and dirty workaround : define the file "type" in function _user_import_file_deletion of user_import.admin.inc by adding at line 672:
$file->type = 'user_import';

But a better integration with File Entity (using entity_get_info('file') ?) should be implemented.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

GaxZE’s picture

Version: 7.x-1.0-beta4 » 7.x-1.0-beta5
Status: Active » Needs review
FileSize
682 bytes

Thought i'd pop this fix into a patch - for me this was done on 7.x-1.0-beta5.

Excuse my patch name - trying to follow the naming conventions from: http://drupal.org/patch/submit

ace11’s picture

Works like a charm. Thanks!

FAAREIA’s picture

Tested, works fine.
Using 7.x-1.0-beta6

Thanks

gisle’s picture

Version: 7.x-1.0-beta5 » 7.x-3.x-dev
Issue summary: View changes
Status: Needs review » Postponed (maintainer needs more info)

I am unable to reproduce this bug with the lastest snapshot of User Import 7.x-3.x-dev in combination with Media 7.x-2.21 and File Entity 7.x-2.25, following the five steps outlined in the issue summary.

Can anybody confirm that this bug is still in the latest version of User Import 7.x-3.x-dev? And if "yes", please update the steps required to reproduce.

The patch in comment #1 does not apply (the code it patches has been moved from user_import.admin.inc to user_import.module). However, as noted in the issue summary, this should be resolved by better integration with File Entity.

gisle’s picture

Status: Postponed (maintainer needs more info) » Closed (cannot reproduce)

Six year old issue that cannot be reproduced. Time to close.