See my previous issue Upload succeeds, but "File copy failed" for my drupal system configuration, which has not changed.

Problem:
When using image_import to upload multiple images, the resulting image nodes are visible only to the administrator account. Upon editing the image node and re-saving, the image becomes visible.

A possible cause is interaction with the user group (og) module, active in my configuration. My og module version is:

// $Id: og.module,v 1.53.2.30 2005/07/16 00:43:28 weitzman Exp $

When I call up the newly-uploaded "invisible" image node for edit, the "Public" option is already checked, but I suspect that this is not really true.

Looking directly at my drupal database, the only field in the node table that changes when the node is re-saved is the "format" field. I believe the issue is somewhere in the interaction between the og, image, and image_import modules, and possibly the taxonomy module. I am continuing to troubleshoot, but so far I am limited by my evolving but rudimentary knowledge of Drupal's data structures and internal workflow.

Any thoughts as to the cause of this?

Comments

rxfelix’s picture

Update:

There are no records in the node_access table for the "invisible" image nodes that have been added using image_import. By manually creating an entry, the image becomes visible:

mysql> insert into node_access (gid, realm, grant_view, grant_update, grant_delete, nid) values (0, 'og_group', 1,0,0,17064);

Why this record is created when a single image node is added but is not created by image_upload remains a mystery.

cornfed’s picture

any update on this? I just ran into the issue using the 4.6 version.

hirstpf1’s picture

I also have this issue with 4.6. Has anyone created a patch for it? Presumably its as simple as writing the relevant entries for each image node into the node access table in the image_import module? (Maybe reusing / adapting the code from any other content creation process that does wrtie correct values to this table?).

I'm sure there are lots of us who will be with 4.6 for a while longer due to upgrade paths etc., so getting this working in 4.6 would help a lot of people.

I guess I'll try to hack a solution myself but if someone is already on it ...

Thanks

Peter