Skip to content

Scrapy, a fast high-level web crawling & scraping framework for Python.

Merge remote-tracking branch 'origin/master' into asyncio-parse-asyncgen-proper-rebased

Andrey Rakhmatullinecfc924ca88d
diff --cc pytest.ini
index 15ebbafed,6de08c78d..fa5d6b34f
--- a/pytest.ini
+++ b/pytest.ini
@@@ -20,21 -20,5 +20,6 @@@ addopts
--ignore=docs/utils
markers =
only_asyncio: marks tests as only enabled when --reactor=asyncio is passed
+ only_not_asyncio: marks tests as only enabled when --reactor=asyncio is not passed
- flake8-max-line-length = 119
- flake8-ignore =
- W503
-
- # Exclude files that are meant to provide top-level imports
- # E402: Module level import not at top of file
- # F401: Module imported but unused
- scrapy/__init__.py E402
- scrapy/core/downloader/handlers/http.py F401
- scrapy/http/__init__.py F401
- scrapy/linkextractors/__init__.py E402 F401
- scrapy/selector/__init__.py F401
- scrapy/spiders/__init__.py E402 F401
-
- # Issues pending a review:
- scrapy/utils/url.py F403 F405
- tests/test_loader.py E741
+ filterwarnings=
+ ignore::DeprecationWarning:twisted.web.test.test_webclient
diff --cc tests/test_utils_python.py
index 58b384591,4b3964154..19143b31f
--- a/tests/test_utils_python.py
+++ b/tests/test_utils_python.py
@@@ -2,14 -2,12 +2,15 @@@ import functool
import gc
import operator
import platform
-import unittest
from datetime import datetime
from itertools import count
- from warnings import catch_warnings
+ from warnings import catch_warnings, filterwarnings
+from twisted.trial import unittest
+
+ from scrapy.exceptions import ScrapyDeprecationWarning
+from scrapy.utils.asyncgen import as_async_generator, collect_asyncgen
+from scrapy.utils.defer import deferred_f_from_coro_f, aiter_errback
from scrapy.utils.python import (
memoizemethod_noargs, binary_is_text, equal_attributes,
WeakKeyCache, get_func_args, to_bytes, to_unicode,