I have a problem with new source media field (images) not being associated to a destination node. Whereas, new images embedded in the body HTML do copy across to the destination node.

Any suggestions on how to fix this issue?

Details as follows.

Have installed as per these instructions:
https://www.drupal.org/node/1406134

Have also installed Deploy Plus, Views Bulk Operations, Admin Views and am able to deploy files (images) by themselves.

When it comes to copying nodes, these scenarios work fine:

  • If there is a source image in the node *body* that never existed in the destination site it gets deployed to destination site and *does* appear in the body destination node.
  • If there is a source image in the node *media field* that existed prior to copy/creation of destination site it *does* appear in the media field destination node.

What won't work is:

  • If there is a source image in the media field, that *never* existed in the destination site it does *not* get deployed to destination field.
  • If there is a source image in the media field that has *just* been deployed across to the destination site it still does *not* appear in the destination node's media field. Note: checked with SQL and the fid might be different, but the uuid is exactly the same on both source & destination image

I am using the latest 7.x dev versions of all modules mentioned in the 7.x installation instructions.

Also, if I review a node's file dependencies in the plan, I can see the image referenced in the body HTML, but not in the media field. That leads me to suspect the problem is on the source side.

Incidentally, there is no spaces in the test image name plus I have debug enabled on both source and destination and am not seeing any errors.

Any suggestions?

Thanks

Regards

Brett Sh

Comments

BrettSh created an issue. See original summary.

BrettSh’s picture

Issue summary: View changes
BrettSh’s picture

Issue summary: View changes
BrettSh’s picture

Issue summary: View changes
BrettSh’s picture

From further experimentation, I have determined that the problem seems to be related to the media field.

I created a simple test content type where I used an image field rather than a media field. When I created a node with a *new* managed image file (on the source server), the file *did* so up in the plan as a file dependency. Furthermore, said file was subsequently copied across to the destination server.

Unfortunately, we usually use the media field and not the image field. Swapping media field for image is just not practical :-(

Any suggestions?

Thanks.

BrettSh’s picture

Have spent more time on this issue, but to no avail. I just can't get Media images added to the node dependencies in the deployment plan.

Just to confirm an assumption, Deploy does support Media 7.2.x right?

Had a quick scan thru the code, but couldn't pinpoint where exactly where images should be added to dependencies. Can anyone suggest a function to inspect?

Is there anything I can do with a bit of custom code to force the dependency?

Thanks

Regards Brett

BrettSh’s picture

Could the issue be something to do with a lack of UUID as described here:
https://www.drupal.org/project/media/issues/1515788

Incidentally, I've tried installing the patch, but that didn't help either.