Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
I have a node import feed using a standalone form and a CSV file. The feed imports well but always adds an extra blank node. So if I import 10 nodes an 11th empty node is created. Is this normal? Or does this reflect an error in one of my import fields?
Comments
Comment #1
amaisano CreditAttribution: amaisano commentedI just ran into this issue. As soon as I started using a Feeds Tamper plugin (Keyword Filter -> Only Import when Title contains a word), it imported only the nodes that matched my filter (good!) but added an extra, completely blank node w/o a title or anything (bad).
Strange! It wasn't doing that before I added the Tamper settings. Were you using Feeds Tamper at all?
Comment #2
gscerb CreditAttribution: gscerb commentedYes, I'm using feeds tamper.
Comment #3
amaisano CreditAttribution: amaisano commentedI was able to work around this, but it is just a temp fix. Not sure what the real problem could be, but probably related to Tamper plugins.
Since this only happened when I used certain Tamper plugins on a field - in my case, "Keyword Filter," I added another plugin to that field following the Filter called "Required Field" which skips importing that item if the field is blank after the previous filter runs.
This seems to cancel out those empty nodes, at least for me.
UPDATE
I had to add other filters to other fields on my importer, and the empty node issue came back with a vengeance. Now not only is it importing an empty node, but is filling that empty node with the values of the last item on the XML feed - even if that last item was supposed to be filtered out by other rules.
Comment #4
MegaChriz CreditAttribution: MegaChriz commented@amaisano, @gscerb,
It's hard with the current information to try to reproduce the issue. Can you try to reproduce the issue on a clean install (with dummy config & data) and attach the importer, the feeds tamper configuration and the data source here?
The Feeds importer and Feeds Tamper configuration can also be exported with the Features module. (The advantage of that is that you can bundle all the configuration in one so called feature module.)
Comment #5
gscerb CreditAttribution: gscerb commentedSolved. For me the problem was an extra, incomplete row in the spreadsheet I was importing. When I deleted the row the problem went away.
Comment #6
amaisano CreditAttribution: amaisano commentedMegaChriz,
Sorry for the poor information. Since my post I deleted several Tamper plugins on various fields, and the problem went away.
At the moment I'm rushing to get the site launched, so I won't have time to recreate the problem configuration, export and share here, but hopefully after launch I can do this.
Thanks.