Closed lsli8888 closed 2 years ago
Done in e3a9ec10d3ca3e63548a2592117f7f634ab63423
Does Scrapy Cloud still need to be updated or is it something else? I get the following error when deploying to Scrapy Cloud using shub deploy:
Packing version 752a3bb-master
Deploying to Scrapy Cloud project "******"
Deploy log last 30 lines:
File "/usr/local/lib/python3.9/site-packages/sh_scrapy/crawl.py", line 148, in _run_usercode
_run(args, settings)
File "/usr/local/lib/python3.9/site-packages/sh_scrapy/crawl.py", line 103, in _run
_run_scrapy(args, settings)
File "/usr/local/lib/python3.9/site-packages/sh_scrapy/crawl.py", line 111, in _run_scrapy
execute(settings=settings)
File "/app/python/lib/python3.9/site-packages/scrapy/cmdline.py", line 140, in execute
cmd.add_options(parser)
File "/usr/local/lib/python3.9/site-packages/sh_scrapy/commands/shub_image_info.py", line 23, in add_options
parser.add_option("--debug", action="store_true",
AttributeError: 'ArgumentParser' object has no attribute 'add_option'
Traceback (most recent call last):
File "/usr/local/bin/shub-image-info", line 8, in <module>
sys.exit(shub_image_info())
File "/usr/local/lib/python3.9/site-packages/sh_scrapy/crawl.py", line 209, in shub_image_info
_run_usercode(None, ['scrapy', 'shub_image_info'] + sys.argv[1:],
File "/usr/local/lib/python3.9/site-packages/sh_scrapy/crawl.py", line 148, in _run_usercode
_run(args, settings)
File "/usr/local/lib/python3.9/site-packages/sh_scrapy/crawl.py", line 103, in _run
_run_scrapy(args, settings)
File "/usr/local/lib/python3.9/site-packages/sh_scrapy/crawl.py", line 111, in _run_scrapy
execute(settings=settings)
File "/app/python/lib/python3.9/site-packages/scrapy/cmdline.py", line 140, in execute
cmd.add_options(parser)
File "/usr/local/lib/python3.9/site-packages/sh_scrapy/commands/shub_image_info.py", line 23, in add_options
parser.add_option("--debug", action="store_true",
AttributeError: 'ArgumentParser' object has no attribute 'add_option'
{"message": "shub-image-info exit code: 1", "details": null, "error": "image_info_error"}
{"status": "error", "message": "Internal error"}
Deploy log location: /tmp/shub_deploy_30aihql1.log
Error: Deploy failed: b'{"status": "error", "message": "Internal error"}
From the /app/python/lib/python3.9/
messages, I think you might still be using an older image. Could you share your scrapinghub.yml
file?
Oh darn, you're correct I forgot to update my scrapinghub.yml scrapy stack version:
stack: scrapy:2.6
Once I did that, the deploy worked. Thanks!
https://github.com/scrapy/scrapy/releases/tag/2.6.1