summaryrefslogtreecommitdiff
path: root/indexer.py
diff options
context:
space:
mode:
Diffstat (limited to 'indexer.py')
-rw-r--r--indexer.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/indexer.py b/indexer.py
index 8ab4cdf..3f1ecd6 100644
--- a/indexer.py
+++ b/indexer.py
@@ -7,7 +7,6 @@ import pyPdf
import whoosh.index as index
import whoosh.writing as writing
import whoosh.fields as fields
-import multiprocessing as mp
schema_book = fields.Schema(
pagenumber=fields.NUMERIC(stored=True),
@@ -97,6 +96,7 @@ def process_file(filepath):
print u"{0} failed at {1}: {2}".format(os.getpid(), filepath, e)
try:
+ import multiprocessing as mp
pool = mp.Pool()
jobs = []
for filepath in filepaths: