--- cdli/cdliSplitter.py 2007/08/31 14:22:52 1.7 +++ cdli/cdliSplitter.py 2007/10/06 13:44:46 1.7.2.1 @@ -79,6 +79,7 @@ class cdliSplitter: def process(self, lst): + logging.debug("cdliSplitter") result = [] pNum=None lineNum=None @@ -93,7 +94,8 @@ class cdliSplitter: if (s!="") and (s[0]=="&"): # store pNum pNum=s[1:8] - logging.debug("storing: %s"%pNum) + logging.debug("cdliSplitter processing: %s"%pNum) + elif (s!="") and (not (s[0] in ignoreLines)): splitted=s.split(".") @@ -115,18 +117,15 @@ class cdliSplitter: IndexLine("/tmp/index",analyser,pNum,lineNum,analyse) else: splitted = analyse.split(" ") - - for w in splitted: w=w.lstrip().rstrip() if not (w==''): - if pNum: #only whe pnum is found (first call of the splitter, is always called twice in the pipeline + #if pNum: #only whe pnum is found (first call of the splitter, is always called twice in the pipeline + # Zope2.app().cdliRoot.storeInLineIndex(self.indexName,w.lstrip().strip(),(pNum,lineNum)) + # transaction.get().commit() - Zope2.app().cdliRoot.storeInLineIndex(self.indexName,w.lstrip().strip(),(pNum,lineNum)) - transaction.get().commit() - - result.append(w.lstrip().rstrip()) + result.append(w) return result