Download & Extend

Cannot drop Google as provider after upgrade to 6.x-2.3

Project:Embedded Media Field
Version:6.x-2.3
Component:Providers
Category:bug report
Priority:normal
Assigned:Unassigned
Status:active
Issue tags:emfield, google

Issue Summary

I've upgraded my Emfield module from a 6.x-1.x to the newest release of 6.x-2.3. I had one field enabled to handle any of four providers: Blip, Youtube, Vimeo and Google.

I've installed three of the provider modules (Blip, Youtube and Vimeo), but there is no provider module for Google videos. There are no Google videos in use on this site, so I don't care about the not-yet supported provider. The trouble is that I can't find a way to disable the non-existent support for Google videos, and hence cannot clear the warning nag from the Drupal status report.

Have I missed something or is this a bug?

Screenshot from issue report

Screenshot from comment #4

AttachmentSize
Picture 2.png63.06 KB

Comments

#1

Status:active» fixed

Here's where it's currently maintained: http://drupal.org/project/media_video_flotsam

I don't even know if it works anymore- feel free to create a media_google module if you're using it! ;-)

#2

Status:fixed» closed (fixed)

Thanks, Alex. That's the tip I needed.

Notes for anyone else with this problem. I installed the Flotsam module, enabled Google video support for my embedded media field. I then disabled the support for the field and disabled and uninstalled Flotsam. My missing provider notice has been cleared. I bet this would work for any of the providers covered in the flotsam pile.

#3

Status:closed (fixed)» active

oddly, the nag should only appear if a provider exists in a field as an embedded media object, as the query is against the field content, rather than the allowed providers. this and another similar issue tells me something else might be going on. re-opening to remind myself to look into this more closely.

thanks, sean!

#4

Status:active» closed (fixed)

Aaron, good point. I went back to look at my work just now and I found that the nag has reappeared but does not list the missing provider. See the attachment.

I browsed my content_ tables and found one or two bad nodes with broken emfields. I deleted those bad nodes so I am now positive that the all the videos embedded have the appropriate provider module enabled. Disabling the flotsam module continues to show me the status report nag, despite my conviction that all the embedded videos are supported.

AttachmentSize
Picture 3.png 86.79 KB

#5

Status:closed (fixed)» active

#6

Sorry, dunno why that got switched to closed.

#7

This is because hook_requirement runs sql scanning all node revisions.

Using the SQL below I can make the err away by deleting the particular node revisions.

SELECT n.nid, n.vid "N.latest vid", v.vid, v.field_videos_provider FROM node n INNER JOIN content_field_videos v ON n.nid = v.nid WHERE v.nid in (165, 5463, 5466) AND v.field_videos_provider = '' ORDER BY n.nid, v.vid;
+------+--------------+------+-----------------------+
| nid  | N.latest vid | vid  | field_videos_provider |
+------+--------------+------+-----------------------+
|  165 |         9208 |  667 |                       |
| 5463 |         9210 | 7277 |                       |
| 5466 |         8641 | 7422 |                       |
+------+--------------+------+-----------------------+

<?php
function _emfield_audit() {
...
   
$sql = "SELECT $provider_column FROM {{$table}} WHERE $provider_column IS NOT NULL GROUP BY $provider_column";
   
$results = db_query($sql);
    while (
$result = db_fetch_object($results)) {
     
$provider = emfield_system_list($module, $result->$provider_column);
      if (empty(
$provider)) {
       
$audit[$result->$provider_column] = $result->$provider_column;
      }
    }
...
?>

runs SQL below giving (in my case) empty provider from the past.

SELECT field_videos_provider FROM {content_field_videos} WHERE field_videos_provider IS NOT NULL GROUP BY field_videos_provider

My 2cnts