Skip to content

Commit 82ccb6b

Browse files
committed
Fixing issue 2, psyco in __main__
1 parent 7ce95c0 commit 82ccb6b

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

PyCrawler.py

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,7 @@
66
import sqlite3 as sqlite
77
import robotparser
88
# Try to import psyco for JIT compilation
9-
try:
10-
import psyco
11-
psyco.full()
12-
except ImportError:
13-
print "Continuing without psyco JIT compilation!"
9+
1410

1511
"""
1612
The program should take arguments
@@ -203,5 +199,10 @@ def queue_links(self, url, links, cid, curdepth):
203199
else:
204200
pass
205201
if __name__ == '__main__':
202+
try:
203+
import psyco
204+
psyco.full()
205+
except ImportError:
206+
print "Continuing without psyco JIT compilation!"
206207
# Run main loop
207208
threader().run()

0 commit comments

Comments
 (0)