Is it dangerous to call a function that deletes nodes based on criteria while a cron job is running that imports them
Depends on the way you import:


If you delete the nodes on some criteria and import the nodes as new nodes ($node-&gt;is_new = TRUE), this shouldn't be a problem.
If you are updating the existing nodes while importing and deleting the nodes at the same time, then there could be issues.


This is because the node_save() function internally calls drupal_write_record, which creates a node with an incremental nid value if the $node-&gt;is_new is set to TRUE. Or updates the exiting nodes if you are importing.