Scrapy, a fast high-level web crawling & scraping framework for Python.
scrapy deploy: retry setup.py bdist_egg on EINTR. closes #9
Pablo Hoffman1e2efe566445
diff --git a/scrapy/commands/deploy.py b/scrapy/commands/deploy.pyindex ce9cb3f42..082c46455 100644--- a/scrapy/commands/deploy.py+++ b/scrapy/commands/deploy.py@@ -15,6 +15,7 @@ from w3lib.form import encode_multipartfrom scrapy.command import ScrapyCommandfrom scrapy.exceptions import UsageErrorfrom scrapy.utils.http import basic_auth_header+from scrapy.utils.python import retry_on_eintrfrom scrapy.utils.conf import get_config, closest_scrapy_cfg_SETUP_PY_TEMPLATE = \@@ -206,7 +207,7 @@ def _build_egg():_create_default_setup_py(settings=settings)d = tempfile.mkdtemp()f = tempfile.TemporaryFile(dir=d)- check_call([sys.executable, 'setup.py', 'clean', '-a', 'bdist_egg', '-d', d], stdout=f)+ retry_on_eintr(check_call, [sys.executable, 'setup.py', 'clean', '-a', 'bdist_egg', '-d', d], stdout=f)egg = glob.glob(os.path.join(d, '*.egg'))[0]return egg, d