Fatal error: Cannot use string offset as an array in /var/www/drupal.monster/sites/all/modules/modified/media_mover/mm_node/mm_node.module on line 321
function mm_node_attach_file($file, $configuration) {
// get drupal file path
if ($file['data']['file']['drupal_path']) {
$drupal_path = $file['data']['file']['drupal_path'];
}
Still just trying to get this working.
I created a process profile to convert uploaded mpegs to FLVs.
I enabled the normal video.module content type.
Attached an mpeg to it and tested.
I added a media mover process to :
- harvest attachments from nodes of type video
- convert to flv
- re-attach to the node.
Sounded sensible. I ran the test and got the above error.
Debugging, the $file variable passed in to the mm_node_attach_file() func is
Array
(
[mmfid] => 2
[nid] => 48
[fid] => 194
[cid] => 2
[harvest_file] => /var/www/resourcedb/files/videos/the_annoying_thing_320x256.mpeg
[process_file] =>
[storage_file] =>
[complete_file] =>
[url] =>
[status] => 3
[date] => 1203233683
[data] => a:20:{s:3:"fid";s:3:"194";s:3:"nid";s:2:"48";s:8:"filename";s:38:"videos/the_annoying_thing_320x256.mpeg";s:8:"filepath";s:64:"/var/www/resourcedb/files/videos/the_annoying_thing_320x256.mpeg";s:8:"filemime";s:10:"video/mpeg";s:8:"filesize";s:7:"2906116";s:3:"vid";s:2:"48";s:4:"type";s:5:"video";s:5:"title";s:13:"Annoying Frog";s:3:"uid";s:1:"1";s:6:"status";s:1:"1";s:7:"created";s:10:"1203232958";s:7:"changed";s:10:"1203232958";s:7:"comment";s:1:"0";s:7:"promote";s:1:"1";s:8:"moderate";s:1:"0";s:6:"sticky";s:1:"0";s:12:"harvest_file";s:64:"/var/www/resourcedb/files/videos/the_annoying_thing_320x256.mpeg";s:14:"harvest_module";s:7:"mm_node";s:14:"harvest_action";s:1:"2";}
)
So it looks like the 'data' is serialized, but hasn't been unpacked properly.
... investigating :-( .
PS. You might want to add some 'components' to this project so we can identify issues against the various sub-modules.
Comments
Comment #1
dman commentedadditional.
Watchdog tells me that
so it may be that the mm_node_attach_file() failed because of invalid input.
That's understandable, but needs better error-checking and recovery then.
Still looking.
Comment #2
dman commented... turns out that the ACTUAL command that got run was
So it looks like a problem with the acodec parameter. Without it it works fine!
... it may be my build or install. No MP3 support (!) I'll see if an upgrade is needed :-/
Comment #3
dman commentedYeah, my problem was really LAME :-{
... and after an hour of trying to recompile ffmpeg with mp3 on ubuntu it still breaks.
I've gotta use a different -acodec from mp3 (I've now found the setting you've given to allow that to be changed ... but am trying to find an alternative that works)
This is a killer for Ubuntu.
Still, better error-catching is needed further down the track ;-)
Comment #4
arthurf commentedSorry that you had a such a rough experience dealing with FFmpeg. It's a bit of a bear to figure out how to parse what codecs are actually usable for FFmpeg and make those into options that a admin can choose and then hand those back to FFmpeg when it comes time to convert. The way I did it is messy, and really could use some improvement. I'll make lamemp3 the default (which works on Ubuntu pretty well from my experience) which hopefully work better. FYI, you may want to check out my hints for installing FFmpeg on Ubuntu/Debian - there are some file types that won't work with version you posted above
http://www.24b6.net/?p=188
Good luck, and thanks for posting your experiences.
Comment #5
dman commentedI can't see lamemp3 listed in the big chart [About FFmpeg installation] either ... yet.
I can't think of a tidier way of handling those hundred weird codecs either. It's impressive you've gone as far as you did to expose the ffmpeg diagnostics. But all those choices just confuse me :-)
This issue has incidentally sent me off into dpkg-hell. Trying to upgrade one utility has now caused me to open my system to the Debian universe instead of / as well as the Ubuntu one.
This in turn has just caused my machine to no longer know who or what it is ... and it's spent the last three hours downloading various competing updates (big stuff like X11, GCC, and a million other libs I never knew I had) from non-synchronous repositories, no longer has a working desktop GUI, and still complains about something new every time I try to trigger apt-get or dselect !!!
I think I said 'Yes, use the unverified update' at the wrong time somewhere in history :-/
I'll sort it out eventually. But what bugs me is that a conflict in the TTF fonts for Urdu or WTF will cause a whole 20 minute upgrade to roll back... *sigh*. All to get sound into my FLVs. ... And I didn't even want to be doing videos!
Comment #6
arthurf commentedUgh, sorry you're in package hell. Looking at what's configured in your FFmpeg output, it looks like you don't have lame support. When I query ffmpeg, I get:
note that libmp3lame is included in the list. If you'd like a static binary of ffmpeg that does support it, please download it here:
ffmpeg.static.tgz
This is a static (meaning the libraries are compiled in) version of ffmpeg.
Comment #7
arthurf commented