mirror of https://github.com/scrapy/scrapy.git
added deprecation messages to queue and runserver commands
This commit is contained in:
parent
b19ff21acd
commit
6f2cea4775
|
|
@ -33,6 +33,10 @@ class Command(runserver.Command):
|
|||
raise UsageError()
|
||||
cmd = args[0]
|
||||
|
||||
import warnings
|
||||
warnings.warn("Scrapy queue command is deprecated - use Scrapyd instead.", \
|
||||
DeprecationWarning)
|
||||
|
||||
q = self.crawler.queue._queue
|
||||
|
||||
if cmd == 'add' and len(args) < 2:
|
||||
|
|
|
|||
|
|
@ -10,4 +10,7 @@ class Command(ScrapyCommand):
|
|||
return "Deprecated command. Use 'server' command instead"
|
||||
|
||||
def run(self, args, opts):
|
||||
import warnings
|
||||
warnings.warn("Scrapy queue command is deprecated - use 'server' command instead.", \
|
||||
DeprecationWarning)
|
||||
self.crawler.start()
|
||||
|
|
|
|||
Loading…
Reference in New Issue