I installed the module and the version 1.8.0 of the PHPExcel library.
I'm importing a quite simple XLS file, with one sheet, I trimmed it for testing purpose to just 3 rows.
I didn't change any default settings of the importer,
while importing, the feed keeps looping, creating a number of equal rows until I don't unlock the feed.
Note that there is no unique row.
Anybody had such issue?

Comments

artsakenos created an issue. See original summary.

mrromios’s picture

Hi
Can you send me your XLS file?
I will be happy to help)

artsakenos’s picture

Thank you Darth, the file can be downloaded here, togheter with the export of the feed importer.
The feed I created is pure new, I stopped all the running cron processes before trying again, I removed any tamper, the GUID reference you see in the file lead to a non recursive importer.

netmachina’s picture

Yes, in 7.x-2.2 there is infinite import issue (random xlsx file, unfortunately - I cannot share it :( ). It is not happening in version before - 7.x-2.1.

I have downgraded, and it works fine.

netmachina’s picture

Little fix, the getTotal() count returns wrong value (count of all cells, not only rows)

diff --git a/sites/all/modules/feeds_excel/FeedsExcelParserIReadFilter.inc b/sites/all/modules/feeds_excel/FeedsExcelParserIReadFilter.inc
index 018d615..7373f8a 100644
--- a/sites/all/modules/feeds_excel/FeedsExcelParserIReadFilter.inc
+++ b/sites/all/modules/feeds_excel/FeedsExcelParserIReadFilter.inc
@@ -13,18 +13,24 @@
   private $startRow;
   private $endRow;
   private $rowCounter;
+  private $lastRow;
 
   public function __construct($startRow = 0, $chunkSize = 0) {
     $this->startRow   = $startRow;
     $this->endRow     = $startRow + $chunkSize;
     $this->rowCounter = &drupal_static('feeds_excel_parser_row_counter');
-    if (!isset($this->rowCounter)) {
+    $this->lastRow = array();
+    if (!isset($this->rowCounter) ) {
       $this->rowCounter = 0;
     }
   }
 
   public function readCell($column, $row, $worksheetName = '') {
-    $this->rowCounter++;
+    if ($this->lastRow != $row) {
+      $this->rowCounter++;
+      $this->lastRow = $row;
+    }
+      
     return ($row >= $this->startRow && $row < $this->endRow);
   }
 }

mrromios’s picture

Hi all!
Thanks for activity)

@netmachina, yep you are totally right! It was issue with total counter (cells instead of rows (doh))
Fixed and pushed into 7.x-2.x.
Please, try to use 7.x-2.x-dev version and if all is OK I will make release with fix.

mrromios’s picture

Status: Active » Fixed

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.

daveX99’s picture

I see that the last message in this thread indicates a fix for the bug discovered by @netmachina was added to the 7.x-2.x-dev version by @darth romios back in December of 2016.

There wasn't any feedback and the issue was closed 2 weeks later.

After experiencing this problem, I noticed that the last update to the DEV version is more recent than that of the 'official' versions. I switched from 'official' to 'dev' version of the module in my project and it solved my problem.

The fix added to the DEV module back in 2016 should be pushed to the 'official' version.

Thanks.

-dave.