Download & Extend

update youtube video if node is updated

Project:Video Upload
Version:6.x-2.x-dev
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:closed (fixed)

Issue Summary

I've created a node with a video. The cron job uploaded it to YouTube correctly.
But... If I edit the node and change the video file (delete the existing and upload a new) or node title (=video title) youtube doesn't follow this changes because the module doesn't hit the cron to do it.
Are you plan to solve this problem?
Anyway I like this module, it's great work!! respect :)

Comments

#1

I saw this message after I tried to update the title/body of the successful uploaded video node.

Referencing to the file used in the Myvideofile field is not allowed.

But I can change the Video Title & Description of the successful uploaded video from Youtube, it didn't sync back to the title/body of the original video node.

It seems that there's no sync between the Video node of Drupal and Video in the Youtube. Looks like I have to check the setting very carefully and thoroughly!

Also, the video in the drupal files directory will not be erased after the successful upload, is this true?

#2

For updating the video node................

After checking the setting of the video field, I did set the following three to Synchronize (overwrite default)

1) Default Video Title Synchronization
2) Default Video Description Synchronization
3) Default Video Keyword Synchronization

However, I can not update the title/description of the video, nor delete the video node. Any clue??

Thanks in advance.

#3

Just curious....Does the Video Upload really support title/body field and video modify/update and sync between Drupal and Youtube after the video node had been created and original video uploaded to the Youtube???

Anyone has the answer?? Thanks again.

#4

@happydrupal, this should all theoretically work, but I've never deployed this module to a site where the actual video file changes on a node. What would actually happen in this case is that the module would delete the old video from youtube, and upload the new one. Since this may be undesireable, I haven't spent a lot of time working on that functionality. Changes to the title and body are more straightforward and should work. I'll look into this the next chance I get to work on this module (or will gladly commit patches addressing this issue).

#5

dear jhedstrom, looking forward to your patch. Let me know if you want ot test the upload on my site, thanks.

#6

The _video_upload_update_all_videos function checks for all files that have VIDEO_UPLOAD_STATUS_OK but there doesn't seem to be anywhere in the module where the status is set to VIDEO_UPLOAD_STATUS_OK so these updates would never run.
Is this correct?

Shouldn't there be a hook_nodeapi or something that checks if these fields have been altered and if they have, updates the status so that when cron runs these updates are done?

Unless I misunderstand the way it is working this update functionality doesn't look like it would work at all.

#7

I am looking at making a patch that changes video_upload_field so that it updates the status if the other fields change.

#8

Assigned to:Anonymous» Agileware

#9

Status:active» needs review

Here is a patch that checks the title and body fields for changes when a node is updated and sets the video status accordingly.

Cron will then pick up the changes when it next runs.

You will want to apply the patch in #611380: Call to undefined function _video_upload_node_set_video_status() in video_upload.admin.inc on line 421
when you apply this patch or you will get that error when cron runs the updates.

AttachmentSize
video_upload-439170-9.patch 1.06 KB

#10

Found a slight problem with the patch in #9
Here is a better one.

AttachmentSize
video_upload-439170-10.patch 1.24 KB

#11

I'd like to get this in soon, but it's going to need re-working in the context of #656494: Towards removing the Strong Coupling to FileField.

#12

Status:needs review» needs work

#13

Status:needs work» needs review

Since I'm guessing #656494: Towards removing the Strong Coupling to FileField will only go into 2.x-dev, you can commit this patch to 1.x-dev,
and I will port the patch to 2.x-dev.

#14

Assigned to:Agileware» Anonymous

I haven't got time to do any more work on this sorry

#15

Is updating 6.x 1.x-dev still necessary when 2.x-dev is released? Will there be no upgrade path or why?

Bojanz, I'm looking forward to this patch in 2.x dev!

Cheers & thanks so much!

#16

Status:needs review» patch (to be ported)

Commited to 6.x-1.x.
Needs to be ported to 6.x- 2.x (and to 7.x-1.x eventually)

#17

Kullerkeks, 6.x 1.x-dev will probably have a new release sooner than 6.x 2.x-dev.
Bugfixes go in all branches.

I'm out of time now, but I hope to have this patch ported in the next few weeks.

#18

Status:patch (to be ported)» needs review

Here's a patch for 2.x.
Should work fine. Needs testing. So, please test :)

AttachmentSize
439170.patch 1.78 KB

#19

Version:6.x-1.x-dev» 6.x-2.x-dev

Changing version.

#20

Also, here's a patched archive, for easier testing.
If you already installed 2.x then just replace old files with the new ones.

AttachmentSize
video_upload-DRUPAL-6--2.zip 458.43 KB

#21

Status:needs review» fixed

Fixed in CVS.

#22

Status:fixed» closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.