Download & Extend

Files get duplicated when using cck storage or complete

Project:Media Mover
Version:6.x-1.0-beta4
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:closed (fixed)

Issue Summary

I have set up a filefield with filefield_paths so that when uploading a file it gets stored in audio/[token-album]

When I create the node by hand, it works as expected, but when I use media mover to harvest from a local directory and store the file to a filefield cck I get two files, one in the file root directory and the other one in audio/[token-album] but with the "_0" appended to the file name (before the extension).

The configuration is the following:

<?php
$configuration
= new stdClass;
$configuration->required = array('mm_dir', 'media_mover_api', 'media_mover_api', 'mm_cck');
$configuration->name = 'songs3';
$configuration->cid = '8';
$configuration->description = 'My configuration description';
$configuration->start_time = '1255534077';
$configuration->last_start_time = '1255534077';
$configuration->status = 'stopped';
$configuration->settings->mma_file_perm = '0';
$configuration->settings->mma_file_mask = '0644';
$configuration->settings->mma_node_edit_item_show = '0';
$configuration->settings->mma_node_item_delete = '1';
$configuration->settings->mma_node_config_rss = '0';
$configuration->settings->mma_cron_notify = '0';
$configuration->settings->mma_cron_notify_email = '';
$configuration->settings->mma_cron_notify_time = '10';
$configuration->settings->mma_process_num = '0';
$configuration->settings->mma_storage_num = '0';
$configuration->settings->mma_complete_num = '0';
$configuration->harvest->module = 'mm_dir';
$configuration->harvest->action = '1';
$configuration->harvest->configuration =  array(
 
'path' => 'sites/default/files/import',
 
'file_types' => 'mp3',
 
'cid' => '8',
 
'module' => 'mm_dir',
 
'action' => '1',
 
'verb' => 'harvest'
);
$configuration->harvest->cid = '8';
$configuration->process->module = 'media_mover_api';
$configuration->process->action = '1';
$configuration->process->configuration =  array(
 
'cid' => '8',
 
'module' => 'media_mover_api',
 
'action' => '1',
 
'verb' => 'process'
);
$configuration->process->cid = '8';
$configuration->storage->module = 'media_mover_api';
$configuration->storage->action = '1';
$configuration->storage->configuration =  array(
 
'cid' => '8',
 
'module' => 'media_mover_api',
 
'action' => '1',
 
'verb' => 'storage'
);
$configuration->storage->cid = '8';
$configuration->complete->module = 'mm_cck';
$configuration->complete->action = '3';
$configuration->complete->configuration =  array(
 
'mm_cck_field_save_complete' => 'field_songtest',
 
'mm_cck_new_node_complete' => '1',
 
'mm_cck_save_type_complete' => 'song',
 
'mm_cck_save_author_complete' => 'Anonymous',
 
'mm_cck_title_default_complete' => '',
 
'mm_cck_body_default_complete' => '',
 
'mm_cck_save_options_complete' =>  array(
   
'comment' => '0',
   
'status' => '0',
   
'promoted' => '0',
   
'sticky' => '0'
 
),
 
'mm_cck_file_replace_complete' => '1',
 
'mm_cck_file_source_delete_complete' => '0',
 
'field_save_list_complete' => '0',
 
'cid' => '8',
 
'module' => 'mm_cck',
 
'action' => '3',
 
'verb' => 'complete'
);
$configuration->complete->cid = '8';
$configuration->hierarchy->parent = '0';
?>

Thanks for the help, and by the way, fantastic module!

Comments

#1

Which version of filefield are you using?
For clarification, when you run media mover you have something like:
/local_dir/myfile.mp3
Media Mover runs and you get:

sites/default/files/myfile.mp3
sites/default/files/audio/myfile_0.mp3

This doesn't really make sense to me, but let's try to figure it out. Can you take one of your files that has been created by this media mover configuration and look at it in media mover? admin/build/media_mover/config/X/files, choose a file that is doing this. Can you dump that information out here?

#2

Status:active» closed (fixed)

Closing....

#3

Oh I am sorry I skip this issue for a long time. I will try to re-work in this issue and reopen if still occurs.

nobody click here