Closed (fixed)
Project:
Node import
Version:
5.x-1.8
Component:
Code
Priority:
Critical
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
6 Nov 2008 at 10:07 UTC
Updated:
25 Nov 2008 at 09:02 UTC
Jump to comment: Most recent file
Comments
Comment #1
Robrecht Jacques commentedCan you attach a sample CSV file you are trying to import (a couple of rows)?
What is your Drupal version?
What is your PHP version?
I do not understand the Access control problem. It seems hook_perm() is not being called ?? Have you tried to completely uninstall the node_import module (go to Administer >> Site building >> Modules, unselect node_import and Save configuration, then go to the Uninstall tab on the same page and uninstall node_import, then reinstall it)? Or alternatively, if you have devel module installed, have you tried to clear the cache?
Thanks.
Comment #2
diego.paroni commentedDrupal version: 5.10
Php version: 4.4.7
Uninstalled completely node_import module (also Uninstall tab);
cleared cache with Devel...
I attach "node_import_access_control.jpg" screen of my Access Control Page without checkboxes for Node Import module;
I attach "node_import_test.zip": a sample CSV and the screens of my import try.
I created new type "test_type" with a CCK field "field_test_nomecompleto" (TEXTFIELD)(not reference...), and imported data from CSV ("title", "body" and "nome_completo") mapping in title, body and field.
After import success, the nodes created are with field empty and published, author, ecc empty (I set "published" and "sticky" as default options during import, if not specified by CSV...).
How I can test if hook_perm() is called?
Thanx!
diego
Comment #3
Robrecht Jacques commentedI'll look into the import problem tomorrow (or this evening if I can find the time). Thanks for the images... they help a lot.
The perm problem puzzles me as I have never seen that before. Looking at the code in
modules/user/user.module(function user_admin_perm($rid = NULL) andfunction theme_user_admin_perm($form)) where the permission page is constructed I see no real reason why exactly the node_import permission would disappear. Strange... Any help in debugging (probably in the functions above) would be appreciated.UPDATE: you could easily test if
node_import_perm()is called by changing (in node_import.module):into
and then going to
admin/user/access. If you see a message things should work ?!Comment #4
diego.paroni commentednode_import permissions is called: I can see the message on admin/user/access page.
On new drupal basic installation (same server), the Node Import module not have problems, showing the checkboxes for roles in control access page.
Now I try duplicate my installation and remove step by step other modules: I think it's an incompatible module the problem source...
If success, I will post the information.
Many many thanx.
diego
Comment #5
diego.paroni commentedFirst result:
now checkboxes are visible in Access Control Page,
after uninstalled the module "Node Export".
But the import data fails on test (CCK text field empty, published/author/sticky... empty)... also reinstalling Node Import.
Comment #6
Robrecht Jacques commentedYes! Node export is the problem. That module also defines a permission called "import nodes", the same Node import uses. Probably because node_export comes before node_import alphabetically, the permission shows under Node export and disappears under Node import.
You can just check the permission under Node export and the checked roles will be able to use Node import too.
I can't really fix this permission problem. As far as I'm concerned it is a bug in Node export as that module was created later then Node import. It should not have used the same permission.
As far as the failing import... first thing tomorrow.
Comment #7
diego.paroni commentedThanx!
I can confirm that also on the plain installation the import fails on CCK text field and date/author/published/etc info are reset to Thu, 01/01/1970 - 00:00 — Anonymous, not published.
Windows XP,
Drupal version: 5.10
Php version: 4.4.7
MySql 5.045
Node import 5x.1.8
Comment #8
Robrecht Jacques commentedWith a clean install of Drupal 5.12, Node import 5.x-1.8 and CCK Text 5.x-1.9 I can not reproduce this bug using exactly the same steps in configuring the content type and following the same steps as in the images (as admin).
PHP 5.2.4, MySQL 5.0.51a on Ubuntu Linux - not sure if that could be a problem. I'll try to install an exact equal version... What is your CCK Text version?
Comment #9
diego.paroni commentedcck-5.x-1.7
Comment #10
diego.paroni commentedDefinitely solved upgrading PHP:
from PHP 4.4.7 to PHP 5.2.6.
Now all is ok;
this is my configuration:
- Windows XP
- Php version: 5.2.6
- MySql 5.045
- Apache 2.2.4
- Drupal version: 5.10
- cck-5.x-1.7
- Node import 5x.1.8
Thanx for your support
and many congratulations for the Node Import module:
fundamental.
Diego
Comment #11
Robrecht Jacques commentedOK, this seems to be a PHP 4.x problem, maybe only on Windows (pass by value instead of pass by reference). A fix will be included in 5.x-1.9, released later today.
Thanks for the versions information.