removed noisy comment and moved import to the top

This commit is contained in:
Pablo Hoffman 2009-06-15 18:55:09 -03:00
parent 1d8cec63d1
commit ff76f46d5a
1 changed files with 2 additions and 2 deletions

View File

@ -3,6 +3,7 @@ from __future__ import with_statement
import sys
import os
import optparse
import cProfile
import scrapy
from scrapy import log
@ -134,10 +135,9 @@ def execute_with_args(argv):
cmd.process_options(args, opts)
spiders.load()
log.start() # start logging
log.start()
if opts.profile:
log.msg("Profiling enabled. Analyze later with: python -m pstats %s" % opts.profile)
import cProfile
loc = locals()
p = cProfile.Profile()
p.runctx('ret = cmd.run(args, opts)', globals(), loc)