Commit Graph

2349 Commits

Author SHA1 Message Date
Eugenio Lacuesta 585e4a8aee
Replace local server address 2020-10-15 09:07:34 -03:00
GeorgeA92 872b2e4ce4 testcase added for COMPRESSION_ENABLED setting 2020-10-13 18:41:58 +03:00
GeorgeA92 d32d0d2739 testcase added for HttpCompressionMiddleware with no stats 2020-10-13 18:36:41 +03:00
Eugenio Lacuesta 868826b346
CachingHostnameResolver tests 2020-10-09 10:38:07 -03:00
Andrey Rahmatullin 9f8c3938cc
Merge pull request #4823 from elacuesta/cookies-revert-header
Do not process cookies from headers
2020-10-08 20:20:32 +05:00
Andrey Rahmatullin 45c06cfd80
Merge pull request #4831 from starrify/downloadermw-support-zstd
Adding support for zstd in HttpCompressionMiddleware
2020-10-08 14:08:18 +05:00
Adrián Chaves 269fe35d6d
Merge branch 'master' into http2 2020-10-06 21:05:10 +02:00
P. Chen 156bb0a1d4
Fixing the minor typo on test file path in tests/test_downloadermiddleware_httpcompression.py 2020-10-06 19:53:40 +01:00
Adrián Chaves e40788153c Do not consider about: URLs invalid 2020-10-06 19:13:29 +02:00
GeorgeA92 6050604f62 httocompression/response_bytes tests added 2020-10-06 18:59:57 +03:00
Andrey Rahmatullin b1255b016a
Merge pull request #4746 from Gallaecio/fix_iternodes
Fix iternodes
2020-10-06 20:14:04 +05:00
Andrey Rahmatullin 1aeda66435
Merge pull request #4804 from Gallaecio/mock-s3
Use mocking for S3 tests that currently need server credentials
2020-10-06 18:23:01 +05:00
P. Chen 6032a9a310
Minor adjustment to the test case in tests/test_downloadermiddleware_httpcompression.py 2020-10-05 23:55:48 +01:00
P. Chen 50e1f35d1f
Adding test cases for the zstd content encoding 2020-10-05 23:43:12 +01:00
D R Siddhartha 0c24cdb257 Improved warning messages a little 2020-10-04 02:09:21 +05:30
Eugenio Lacuesta 797a6690c0
Tests: use classes instead of paths in settings (#4817) 2020-10-01 23:11:11 -03:00
Mikhail Korobov 4f27c5f82b
Merge pull request #4768 from maranqz/feature/4606-exporter-from-FEEDS
Pass info from FEEDS to ItemExporter
2020-10-02 00:10:05 +05:00
Mikhail Korobov f173af6b9d
Merge pull request #4778 from drs-11/unparseable-no-proxy-fix
Check for unparseable no_proxy values
2020-10-01 23:57:00 +05:00
Akshay Sharma 159e2b2e2f
allowing to run .pyw files (#4646)
* allow .pyw in scrapy/commands/runspider.py

* aesthetics

* added tests for '.pyw'

* created class for testing .pyw files

* name=None parameter in get_log

* small fix

* .pyw tests for non-windows

* used @skipIf for tests

* two more tests skipped
2020-10-01 23:53:08 +05:00
Eugenio Lacuesta 744f352d09
Do not process cookies from headers 2020-10-01 14:52:23 -03:00
Eugenio Lacuesta 894b509d7a
Crawl rule: remove deprecated code
Remove the compatibility layer that handles 'process_request'
methods that do not receive a 'response' parameter
2020-09-29 23:37:28 -03:00
Adrián Chaves 6ef7c44061 Fix timezone test issue 2020-09-22 12:45:21 +02:00
GeorgeA92 c22e810658 httocompression tests added 2020-09-22 07:47:37 +03:00
Adrián Chaves 8f46e84519 Fix style issues 2020-09-21 23:28:16 +02:00
Adrián Chaves c3b740f078 Use mocking for tests/test_pipeline_files.py::TestS3FilesStore::test_persist 2020-09-21 23:25:37 +02:00
Adrián Chaves 35726da434 tests/test_feedexport.py: remove unused import 2020-09-21 22:55:25 +02:00
Adrián Chaves 17e135377a Use mocking for tests/test_feedexport.py::BatchDeliveriesTest::test_s3_export 2020-09-21 22:54:39 +02:00
Adrián Chaves 56f05fb164 Use mocking for tests/test_feedexport.py::S3FeedStorageTest::test_store 2020-09-21 22:01:09 +02:00
Adrián Chaves 008cf1c75e Remove a test that has never been executed in Python 3 2020-09-21 20:45:21 +02:00
Andrey Rahmatullin 5e997587d9
Remove dead boto2 code, deprecate is_botocore() (#4776) 2020-09-20 15:06:46 +02:00
Eugenio Lacuesta 6e8d20a07a
HTTP/2: add some type hints (#4785) 2020-09-16 09:57:07 +02:00
drs-11 82ba7c8b52 created separate test for invalid no-proxy values 2020-09-10 20:56:39 +05:30
drs-11 959222df7e check for unparseable no_proxy values 2020-09-05 21:32:05 +05:30
drs-11 35e2d25689 Merge remote-tracking branch 'upstream/master' into 3689-update 2020-09-02 20:51:09 +05:30
drs-11 6565adc471 added test case for get_images 2020-09-02 20:44:26 +05:30
Andrey Rahmatullin c1cc3f2f42
Merge pull request #4761 from Gallaecio/on-the-fly-certificates
Generate localhost keys for tests on the fly
2020-09-02 13:37:44 +05:00
Adrián Chaves 9731d91f34
Merge branch 'master' into fix_iternodes 2020-09-01 12:38:37 +02:00
Eugenio Lacuesta 307e35c664
Improve check for invalid cookie in CookiesMiddleware (#4772) 2020-09-01 11:04:00 +02:00
Adrián Chaves 8a3ba34a75 Merge remote-tracking branch 'upstream/master' into http2 2020-08-31 16:43:32 +02:00
Aditya eff33a2e79 fix(h2): Mockserver test uses H2DownloadHandler 2020-08-30 23:55:17 +05:30
maranqz 71d2c2f1a3 improve view of dict 2020-08-30 12:43:44 +03:00
maranqz fc3c66ce95 fix tests:
* FeedExportConfigTestCase.test_feed_complete_default_values_from_settings_empty
 * FeedExportConfigTestCase.test_feed_complete_default_values_from_settings_non_empty
2020-08-30 11:44:48 +03:00
maranqz a8e895e684 kwargs for Item exporters classes
test
docs
2020-08-30 10:57:22 +03:00
Mikhail Korobov be655b855d
Merge pull request #4765 from scrapy/simplify-test_crawl
Simplify tests/test_crawl
2020-08-29 13:31:20 +05:00
Andrey Rakhmatullin 8123c42737 Simplify running spiders in CrawlSpiderTestCase. 2020-08-29 12:01:58 +05:00
Ammar Najjar ffdf6fe100
use f-strings for the newly merged code from master
Issue: #4324
2020-08-29 07:21:48 +02:00
Ammar Najjar defeaacbc2 Merge branch 'master' into 4307-use-f-strings
Conflicts resolved:
- delete tests/py36/_test_crawl.py
2020-08-29 07:12:44 +02:00
Mikhail Korobov 7e6476ff0a
Merge pull request #4764 from scrapy/test_crawl-move-py36
Merge back tests/py36/_test_crawl.py.
2020-08-29 00:12:53 +05:00
Andrey Rahmatullin 59a0157ef1
Merge pull request #4722 from Gallaecio/umask
Do not let umask affect the permissions of startproject-generated files
2020-08-28 18:41:02 +05:00
Andrey Rakhmatullin de640f41ec Merge back tests/py36/_test_crawl.py. 2020-08-28 18:27:36 +05:00
Ammar Najjar 0e57918231
test(Slot): cover __repr__
Issue: #4324
2020-08-28 13:58:32 +02:00
Mikhail Korobov 64905e3397
Merge pull request #4691 from elacuesta/typing-spider-attributes
Typing: annotate a few Spider attributes
2020-08-28 00:03:40 +05:00
Adrián Chaves 195f738bba
Update Python version references after dropping support for 3.5 (#4742)
* Update Python version references after dropping support for 3.5

* Remove outdated test

* Undo change affecting collect_asyncgen

* Undo change to be handled by #4743

* Remove unused import

* Remove unused import

* Update tests/requirements-py3.txt

Co-authored-by: Mikhail Korobov <kmike84@gmail.com>

Co-authored-by: Mikhail Korobov <kmike84@gmail.com>
2020-08-27 15:43:43 +05:00
Adrián Chaves dd378b4bb1 Generate localhost keys for tests on the fly 2020-08-27 11:33:18 +02:00
Mikhail Korobov a6b67cf4a1
Merge pull request #4755 from maranqz/csv-item-exporter-errors
Add errors parameter for CsvItemExporter with tests
2020-08-27 12:51:53 +05:00
Ammar Najjar 5ab1a318e8
test: list appears in ValueError Exception message
Issue #4324
2020-08-26 15:11:46 +02:00
Eugenio Lacuesta a8114d3731
Typing: annotate a few Spider attributes 2020-08-26 09:00:36 -03:00
Ammar Najjar 7597193dbe
Merge branch 'master' into 4307-use-f-strings
Resolve Conflicts:
	tests/test_middleware.py
2020-08-26 13:46:46 +02:00
nyov cf50561b86
Allow passing classes directly in Settings (#3873)
Co-authored-by: Adrián Chaves <adrian@chaves.io>
2020-08-26 13:08:14 +02:00
Ammar Najjar 58ca8bbf6d Use f-strings (#4307) 2020-08-26 07:11:05 +02:00
Mikhail Korobov 0ccaf89a6f
Merge pull request #4756 from ivanprado/master
Support for delegated methods as callbacks
2020-08-26 00:10:43 +05:00
Adrián Chaves 2f28cee3ce Add a test to cover searching for a missing node name 2020-08-25 17:49:17 +02:00
Adrián Chaves 6eb1fc4ab5 Merge remote-tracking branch 'upstream/master' into fix_iternodes 2020-08-25 17:01:54 +02:00
Andrey Rahmatullin 067125c303
Merge pull request #4752 from drs-11/master
DOWNLOAD_MAXSIZE logger level changed from Error to Warning
2020-08-25 18:35:50 +05:00
Adrián Chaves 39affea93c
Fix style issues 2020-08-25 13:57:48 +02:00
maranqz a2d6fa5adc Add errors parameter for CsvItemExporter with tests 2020-08-25 13:34:43 +03:00
Iván de Prado 3e726b9df7 Support for delegated methods as callbacks
It can be useful to structure the spiders code around some helper classes.
2020-08-25 11:31:20 +01:00
Andrey Rahmatullin 64e0ea4ee5
Merge pull request #4735 from wRAR/ciphers-tests
Re-enable TLS 1.2 in cipher tests.
2020-08-25 11:48:31 +05:00
drs-11 1f9598ada4 Update branch to latest 2020-08-25 02:14:22 +05:30
drs-11 8b84a65a6b cleaned up code relating to issue #3689 2020-08-25 00:30:17 +05:30
WinterComes 2d8ec9d44f Change DOWNLOAD_MAXSIZE logger level from Error to Warning 2020-08-24 20:37:40 +05:30
Aditya 26d344b762 Merge branch 'http2' of https://github.com/scrapy/scrapy into h2-client-protocol 2020-08-24 14:58:23 +05:30
Eugenio Lacuesta f1250177dc
Remove Python 3.5 from CI (#4743) 2020-08-22 09:33:35 +02:00
Adrián Chaves e90be0d8a5 Mark the new test as xfail for xmliter_lxml 2020-08-21 14:09:52 +02:00
Adrián Chaves d711eca4d9 Merge remote-tracking branch 'upstream/master' into fix_iternodes 2020-08-21 13:52:52 +02:00
Grisha Temchenko d68aab992e
Smarter generator check for combined return/yield statements (#4721) 2020-08-20 10:22:07 -03:00
sakshamb2113 42383cc267
Add a setting to customize the asyncio event loop (#4414) 2020-08-19 09:18:14 +02:00
Aditya a87ab71d10 refactor(http2): metadata for Stream
- Add Note about HTTP/2 Cleartext not supported in settings.rst
2020-08-18 05:52:40 +05:30
Andrey Rakhmatullin d9e69bfb51 Re-enable TLS 1.2 in cipher tests. 2020-08-17 19:46:24 +05:00
Adrián Chaves e70975f0bb
Allow overwriting feeds (#4512)
Co-authored-by: Yuval Hager <yhager@yhager.com>
2020-08-17 15:10:08 +02:00
Mikhail Korobov 282a6d4fc1
Merge pull request #4727 from wRAR/mitmproxy-ca
Use a longer key in mitmproxy-ca.pem.
2020-08-17 14:06:58 +05:00
Mikhail Korobov 61459de476
Merge pull request #4688 from ashellunts/obsolete-s3feednokeys
Remove obsolete S3FeedStorage instancing without AWS credentials
2020-08-17 13:58:32 +05:00
Mikhail Korobov 5ac135f036
Merge pull request #4718 from Gallaecio/support-pinned-3.6
Upgrade minimum dependencies for Python 3.6 support
2020-08-17 13:54:45 +05:00
Ajay Mittur a8e08d51cd
Check if file is already present on running `scrapy genspider` and terminate if so (#4623) 2020-08-17 10:45:52 +02:00
Eugenio Lacuesta 2aa4f3cbf9
Conditional request attribute binding for responses (#4632) 2020-08-17 10:39:59 +02:00
adityaa30 75fe3d1365 fix: increase timeout to 0.5 seconds
- In Windows specifically the reactor was left unclean by the
  HostnameEndpoint due to the tearDown method of
  test_downloader_handlers.py::HttpTestCase due to
  which the following 2 tests were failing:
  1. test_timeout_download_from_spider_server_hangs
  2. test_timeout_download_from_spider_nodata_rcvd
- Increasing the timeout fixed the test (in local)
2020-08-17 04:18:03 +05:30
Aditya d97cf973dd Merge branch 'master' of https://github.com/scrapy/scrapy into h2-client-protocol 2020-08-16 11:31:10 +05:30
Aditya af73f141b2 refactor: move all http2 tests in separate files 2020-08-16 11:26:32 +05:30
Andrey Rakhmatullin 756c368a6b Use a longer key in mitmproxy-ca.pem. 2020-08-14 22:09:24 +05:00
Adrián Chaves 24ba5a71ac Maybe the problem is not in the code after all 2020-08-13 06:35:09 +02:00
Adrián Chaves 5f4df622a1 test_utils_iterators.py: support Windows the right way 2020-08-13 05:41:06 +02:00
Adrián Chaves 4c0afb606c Update permission expectations 2020-08-12 17:45:26 +02:00
Adrián Chaves 125a058340 Do not let umask affect the permissions of startproject-generated files 2020-08-12 17:07:21 +02:00
Adrián Chaves b1de55d37d Fix marker syntax 2020-08-12 12:34:40 +02:00
Adrián Chaves 8e393a0b21 Do not change the mitmproxy version for no-3.6 Python versions 2020-08-12 12:29:51 +02:00
Adrián Chaves 394631fc0a Restore 3.5 support for mitmproxy-based tests 2020-08-12 12:08:09 +02:00
Ajay Mittur 1c4b4cc6b0
Support defining file path based on item in media pipelines (#4686) 2020-08-11 14:12:44 +02:00
Adrián Chaves 5138f9a965 Merge remote-tracking branch 'upstream/master' into allow-customizing-export-column-names 2020-08-11 13:42:05 +02:00
Adrián Chaves aefd43a6c6 Upgrade minimum dependencies for Python 3.6 support 2020-08-11 12:52:54 +02:00
Aditya c67d6dea31 fix: H2 docs, NotImplementedError for H2 Tunnel 2020-08-11 04:39:41 +05:30
Andrey Rahmatullin 0cf1340c29
Merge pull request #4663 from ajaymittur28/scrapy-check-test
Add Tests to `scrapy check` command
2020-08-10 16:18:29 +05:00
Aditya e0c3019d90 fix: ScrapyProxyH2Agent
- add required test cases

BREAKING CHANGES
Presently the tests (in test_downloader_handlers.py)
1. test_download_without_proxy
2. test_download_with_proxy_https_timeout

collide with each other when run together. However, if both of the tests
are ran individually then both pass.
2020-08-09 16:19:35 +05:30
Jose Galdos 13181ba788 Improve http status all on http error middleware 2020-08-06 20:43:16 -05:00
Marc Hernández 336f19f5cc
Change super syntax (#4707) 2020-08-04 20:42:01 +02:00
Artur Shellunts 5ec66be4a4
Merge branch 'master' into obsolete-s3feednokeys 2020-07-30 22:18:00 +02:00
Adrián Chaves 890b2138a6 Remove the u prefix from strings 2020-07-30 13:39:30 +02:00
Aditya a3fecaf07f test: fix host-name H2DownloadHandler tests 2020-07-30 15:45:27 +05:30
Mikhail Korobov 5e2d1bd187
Merge pull request #4434 from BroodingKangaroo/ISSUE-4250-add_batch_deliveries
Feed exports: add batch deliveries
2020-07-29 23:03:28 +05:00
Aditya e8342996f6 test: H2DownloadHandler
Following tests are skipped as Content-Length header not matching the
data received is considered as a ProtocolError
- test_download_broken_content_cause_data_loss
- test_download_broken_chunked_content_cause_data_loss
- test_download_broken_content_allow_data_loss
- test_download_broken_chunked_content_allow_data_loss
- test_download_broken_content_allow_data_loss_via_setting
- test_download_broken_chunked_content_allow_data_loss_via_setting

BREAKING CHANGES
The following tests currently fail
- test_content_length_zero_bodyless_post_request_headers
- test_host_header_seted_in_request_headers
- test_download_with_maxsize_very_large_file
2020-07-29 13:51:01 +05:30
Aditya 92bec38591 feat: MethodNotAllowed405, Content-Length header
- add tests to check for Content-Length header
- raise MethodNotAllowed405 when remote send 'HTTP/2.0 405 Method Not
Allowed'
2020-07-29 13:49:14 +05:30
Eugenio Lacuesta 5265853937
Use ItemAdapter.field_names when writing header in CsvItemExporter (#4668) 2020-07-28 11:15:14 +02:00
Aditya 3685e99cca test: http2 connection timeout 2020-07-22 14:47:20 +05:30
Aditya 316620b517 chore: pass spider as argument for request method
- download_maxsize and download_warnsize can now be extracted from the
spider directly and passed to the stream
- remove `partial` flag from the response as per RFC 7540 - Section
8.1.2.6
2020-07-22 13:57:49 +05:30
Artur Shellunts 430d22e46e Remove not used import warnings 2020-07-21 23:39:04 +02:00
nyov 2829cd4268 Allow use without credentials 2020-07-21 23:38:02 +02:00
nyov 98e8086d1b Adapt S3FeedStorage testcase 2020-07-21 23:38:02 +02:00
nyov ece4fa6c7c Fix ignored testcase: boto is never installed 2020-07-21 23:38:01 +02:00
Andrey Rahmatullin f3372a3753
Merge pull request #4254 from elacuesta/spider.parse
Change Scraper API to call internal `_parse` method
2020-07-21 17:37:54 +05:00
Akshay Sharma de297a3a16
enable ANSI color (instead of ANSI color codes) in the Windows terminal #4393 (#4403)
* changed ie. -> i.e.(spelling error) on lines 667, 763 (issue scrapy#4332)

* updated all text files for issue #4332 (ie. -> i.e.)

* Apply ie. → i.e. in source comments

* ie → e.g.

* modified scrapy/utils/display.py to stop ANSI color sequences in the Windows terminal (issue #4393)

* modified scrapy/utils/display.py to stop ANSI color sequences in the Windows terminal (issue #4393)

* enabled virtual terminal processing (pr #4403)

* check for specific windows 10 version (pr #4403)

* fixing flake-8 test (pr #4403)

* added error handling for terminal info (pr #4403)

* corrected stderr (pr #4403)

* changed orientation, removed unwanted spaces (pr #4403)

* no need for style variable (pr #4403)

* fixing trailing whitespaces

* commenting windows check

* Update scrapy/utils/display.py

Co-Authored-By: Adrián Chaves <adrian@chaves.io>

* Update scrapy/utils/display.py

Co-Authored-By: Adrián Chaves <adrian@chaves.io>

* Update scrapy/utils/display.py

Co-Authored-By: Adrián Chaves <adrian@chaves.io>

* Update scrapy/utils/display.py

Co-Authored-By: Adrián Chaves <adrian@chaves.io>

* small fixes

* Shifting _color_support_info() function

* enabled virtual terminal processing (pr #4403)

* check for specific windows 10 version (pr #4403)

* fixing flake-8 test (pr #4403)

* added error handling for terminal info (pr #4403)

* corrected stderr (pr #4403)

* changed orientation, removed unwanted spaces (pr #4403)

* no need for style variable (pr #4403)

* fixing trailing whitespaces

* commenting windows check

* Update scrapy/utils/display.py

Co-Authored-By: Adrián Chaves <adrian@chaves.io>

* Update scrapy/utils/display.py

Co-Authored-By: Adrián Chaves <adrian@chaves.io>

* Update scrapy/utils/display.py

Co-Authored-By: Adrián Chaves <adrian@chaves.io>

* Update scrapy/utils/display.py

Co-Authored-By: Adrián Chaves <adrian@chaves.io>

* small fixes

* Shifting _color_support_info() function

* error handling

* error handlingy

* raise ValueError

* added in-built function for version comparison

* recommit changes

* changed check -> parse

* version comparison -> parse_version

* added scrapy/utils/display.py in pytest.ini

* Trigger

* Add simple test for scrapy.utils.display._colorize

* Flake8: E501 for tests/test_utils_display.py

* assertEquals -> assertEqual

* Normal formatter for all platforms

* separate test for windows

* all curses under try block

* added global TestStr

* more test added

* small fix

* covering exceptions

* windows test failing

* Refactor output color handling

* Fix pprint test

* fix flake8

Co-authored-by: Adrián Chaves <adrian@chaves.io>
Co-authored-by: Eugenio Lacuesta <eugenio.lacuesta@gmail.com>
2020-07-20 17:23:38 +05:00
BroodingKangaroo 3e0492741d Another try to fix test errors on Windows 2020-07-19 00:10:29 +03:00
BroodingKangaroo 86f7ac2f2b Try to fix error at Windows 2020-07-17 18:22:47 +03:00
Artur Shellunts 62a4ede5e9
Remove deprecated classes BaseSgmlLinkExtractor, RegexLinkExtractor and SgmlLinkExtractor (#4356) 2020-07-17 12:40:04 +02:00
Adrián Chaves d29bec60d7
Upgrade PyPy for CI, and test both 3.5 (oldest) and 3.6 (newest) (#4504)
* Upgrade PyPy for CI, and test both 3.5 (oldest) and 3.6 (newest)

* Log a detailed error message to discover why MockServer is not working

* Go for all lines!

* Disable tests based on mitmproxy while running on PyPy

* Fix test_get_func_args for PyPy 3.6+

* Make testPayloadDefaultCiphers work regardless of OpenSSL default ciphers

* Crossing fingers…

* Rename: testPayloadDefaultCiphers → testPayloadDisabledCipher

* Test the PyPy version currently documented as the minimum required version

* Fix the PYPY_VERSION tag

* Update the documentation about supported PyPy versions

* Also test the latest 3.5 Python version with PyPy

* Fix the PYPY_VERSION value for the latest 3.5 version

* Use pinned dependencies for asyncio and PyPy tests against oldest supported Python versions

* Fix PyPy installation for the pypy3-pinned Tox environment

* Try installing Cython

* Maybe PyPy requires lxml 3.6.0?

* install.rst: minor clarification

* lxml 4.0.0 is required on PyPy

* Require setuptools 18.5+

* Revert "Require setuptools 18.5+"

This reverts commit 017ec33ac2.

* Maintain lxml as a dependency if setuptools < 18.5 is used
2020-07-17 02:19:24 +05:00
Mikhail Korobov 9a74a71c63
Merge pull request #4682 from noviluni/remove_python2_reminiscence
remove python 2 reminiscence in cookies
2020-07-16 23:58:58 +05:00
Adrián Chaves c4f9250220
Merge branch 'master' into ISSUE-4250-add_batch_deliveries 2020-07-16 17:44:18 +02:00
Mikhail Korobov 07470e1a3c
Merge pull request #3608 from ejulio/feat-685
[MRG+1] Fix for #685 Add Google Cloud Storage Feed Export
2020-07-16 18:11:19 +05:00
Mikhail Korobov 0f2f1acf04
Merge pull request #4458 from scrapy/azure-pipelines
Set up CI with Azure Pipelines
2020-07-16 18:09:31 +05:00
Marc 0e0d1ad643 remove python 2 reminiscence in cookies 2020-07-16 14:25:46 +02:00
Júlio César Batista 38496a00b7
Use the itemlaoders library (#4516) 2020-07-15 12:08:36 +02:00
Andrey Rahmatullin eb1bc74417
Merge pull request #4674 from ashellunts/delete_deprecated_htmlparserlinkextractor
Remove deprecated class HtmlParserLinkExtractor
2020-07-15 12:51:42 +05:00
Aditya 1dd27a92fa feat: Idle Timeout for H2Connection (240s) 2020-07-14 22:46:32 +05:30
Artur Shellunts ed5247ca4c Remove htmlparser.py from tests/ignore.txt 2020-07-14 18:06:11 +02:00
Adrián Chaves 6e119bd3e3
Merge branch 'master' into azure-pipelines 2020-07-14 11:26:19 +02:00
Aditya aeaeb7385b feat: assert negotiated protocol as h2
- implement IHandshakeListener in H2ClientProtocol to know when
handshake is completed
- implement IProtocolNegotiationFactory in H2ClientFactory to provide
information about the acceptableProtols (h2) during NPN or ALPN protocol
2020-07-14 03:55:14 +05:30
Adrián Chaves 544c1f6e39 Fix the issue 2020-07-13 16:30:34 +02:00
Adrián Chaves 0770961054 Write a test for #4665 2020-07-13 16:05:57 +02:00
Adrián Chaves 53c323b19d _is_path → _is_filesystem_path 2020-07-13 15:29:30 +02:00
Adrián Chaves d54c4496ee Refactor guess_scheme 2020-07-13 14:37:08 +02:00
Andrey Rahmatullin 0ebba175ea
Merge pull request #4666 from Gallaecio/execution-access
Fix permission handling on project generation from template files
2020-07-13 16:01:06 +05:00
Andrey Rahmatullin b6f8693db9
Merge pull request #4673 from elacuesta/remove-backslash
Remove backslash
2020-07-13 11:14:00 +05:00
Aditya 64c6af10e1 refactor: use str instead of to_unicode 2020-07-13 00:57:49 +05:30
Aditya Kumar 3f7e8635f4
Allow the parse command to write data to a file (#4377) 2020-07-11 08:48:24 +02:00
Eugenio Lacuesta 9aea1f0961
Remove backslash (tests) 2020-07-09 11:04:46 -03:00
Eugenio Lacuesta 2be2bdd2df
Merge remote-tracking branch 'upstream/master' into spider.parse 2020-07-08 14:00:54 -03:00
ajaymittur28 75bff7b6d3 Update url contract value 2020-07-08 19:48:42 +05:30
Aditya 2ea7d82534 feat: H2ClientFactory 2020-07-08 18:57:13 +05:30
ajaymittur28 3e98ed24b6 Convert f-string to .format() 2020-07-08 17:13:57 +05:30
Ajay Mittur b6d4f28ea7
Merge branch 'master' into scrapy-check-test 2020-07-08 15:13:37 +05:30
Adrián Chaves 7e38615703 Remove unused import 2020-07-07 15:30:19 +02:00
Adrián Chaves ca77ca1f75 Generate read-only files on the fly 2020-07-07 14:44:03 +02:00
Adrián Chaves e1450799ce Remove debug test case variable 2020-07-07 14:11:37 +02:00
Adrián Chaves a3afff4a0e Fix style issue 2020-07-07 14:11:02 +02:00
Adrián Chaves 79b4dfc53e Fix permission handling on project generation from template files 2020-07-07 14:07:04 +02:00
Aditya 1c40dfa740 fix: handle CONNECTION_LOST & RESET separately 2020-07-07 15:36:41 +05:30
ajaymittur28 770a8127e8 Added basic `scrapy check` tests 2020-07-07 15:23:29 +05:30
Adrián Chaves 17aec5944c
Update tests/CrawlerRunner/ip_address.py
Co-authored-by: Eugenio Lacuesta <1731933+elacuesta@users.noreply.github.com>
2020-07-06 10:47:25 +02:00
Adrián Chaves ec06cf79a6
Update tests/CrawlerRunner/ip_address.py
Co-authored-by: Eugenio Lacuesta <1731933+elacuesta@users.noreply.github.com>
2020-07-06 10:47:11 +02:00
Aditya a94b30342a test: reduce test data size to 1MB 2020-07-06 12:49:12 +05:30
BroodingKangaroo 6454d456d2 Make check of placeholder less strict 2020-07-03 10:24:13 +03:00
Adrián Chaves eb93774256 TrackrefTestCase.test_get_oldest: protect from lack of precision 2020-07-03 01:41:47 +02:00
Adrián Chaves 3199048520 Complete Azure Pipelines CI setup 2020-07-03 00:56:24 +02:00
Adrián Chaves 6e58da1dcd
Merge branch 'master' into azure-pipelines 2020-07-02 17:49:42 +02:00
BroodingKangaroo 1e245046ed Change setting name. Add leading zeroes to batch_id. Minor fixes. 2020-07-02 12:38:08 +03:00
Aditya 4acdc2e5d6 refactor: use __qualname__, () for large strings 2020-07-01 20:15:33 +05:30
Aditya c361fe0d3b feat: check for invalid hostname
- Initiating requests having hostname or (ip_address, port) different
from the peer to which HTTP/2 connection is made can lead to closing the
whole connection and close out all the pending streams.
- This change aims to fix that problem
- Add required tests
- Save hostname & port in H2ConnectionMetadataDict
2020-07-01 18:14:44 +05:30
BroodingKangaroo 7b1d3c35ea Minor updates 2020-07-01 12:24:31 +03:00
ajaymittur28 006a945214 Update schemaless http proxy test 2020-07-01 13:32:58 +05:30
Aditya 7b1ad995a4 test: query params, certificate & ip_address
- refactor from str.format() to f-strings
2020-07-01 10:45:36 +05:30
Aditya 50dd9271b4 fix: disable redundant logs
- while testing the job exceeded the maximum log length
and was terminated
- reduce the number of requests from 20 to 10
2020-06-30 07:36:56 +05:30
Aditya 26ab3e4137 feat: FIFO policy to handle large no. of requests
- add required test -- test by sending 1000 requests
- increase test timeout to 180 seconds to account for tests taking long
time
2020-06-30 06:44:20 +05:30
Aditya d17417b03a Merge branch 'master' of https://github.com/scrapy/scrapy into h2-client-protocol 2020-06-29 18:43:42 +05:30
Aditya Kumar e46b47c365
Renew the localhost certificate for tests (#4650)
Validity
  Not Before: Jun 28 12:54:15 2020 GMT
  Not After : Jun 28 12:54:15 2021 GMT
Subject: C = IE, O = Scrapy, CN = localhost
2020-06-29 15:05:13 +02:00
Aditya 90a7007f88 test: warnsize logs, no content header, dataloss 2020-06-29 18:29:31 +05:30
Marc Hernández 464f24f8c1
Add --data-raw to utils.curl and fix missing method with data (#4612) 2020-06-29 14:20:29 +02:00
Aditya 690dd7f38b test: GET & POST request test for h2 client
- Remove repeated dependency Twisted from setup.py
- Test for both GET & POST when
  - Only 1 request
  - Large number (=20) of requests
and
  - Small Data (10 KB) per request
  - Large Data (10 MB) per request
- Test when request is cancelled by the client'

BREAKING CHANGES
Tests raises OpenSSL.SSL.Error when run using tox. However, all tests
passes when ran using `python -m unittest`.
2020-06-28 16:38:49 +05:30
BroodingKangaroo 05c2587c6a Docs update and tiny fixes 2020-06-28 09:45:45 +03:00
ajaymittur28 f53f06020b Test http schemaless proxy 2020-06-27 23:28:40 +05:30
BroodingKangaroo 88a52198b9 Add batch_item_count support in FEEDS setting 2020-06-27 12:45:08 +03:00
BroodingKangaroo c3cee74fd4 Change default value of FEED_STORAGE_BATCH_ITEM_COUNT to 0 2020-06-26 18:45:21 +03:00
BroodingKangaroo 77333666f1 resolve conflicts 2020-06-26 14:55:46 +03:00
Aditya 065b3153fe Merge branch 'master' of https://github.com/scrapy/scrapy into h2-client-protocol 2020-06-24 07:51:41 +05:30
Aditya a97ac0adf8 test: GET request for HTTP2Client using mockserver 2020-06-24 06:40:20 +05:30
Lukas Anzinger 3672f5f988 Spider constructor expects name as argument, not start_urls.
Fixes #4644
2020-06-23 14:56:12 +02:00
Eugenio Lacuesta c7f1c7e3f3
Merge branch 'master' into feat-685 2020-06-19 21:30:54 -03:00
Stanislau Hluboki a4bfd5ab6f Fix duplicated feed logs 2020-06-19 17:51:56 +03:00
Adrián Chaves f9c63384c0
Merge branch 'master' into allow-customizing-export-column-names 2020-06-18 14:09:20 +02:00
Aditya 700df3eeb7 test: mockserver with h2 protocol for tests
- add Twisted[http2] in setup.py requirements
- add test_protocol.py to test the current implementation

BREAKING CHANGES
test_download times out because of no protocol negotiated between
Mockserver and HTTP/2 client
2020-06-17 21:02:14 +05:30
Stas Glubokiy 3d027fb578
Fix missing storage.store calls in FeedExporter.close_spider (#4626) 2020-06-17 17:08:14 +02:00
Eugenio Lacuesta ec98dabfab
Support for dataclass and attrs items (#3881) 2020-06-14 11:45:27 +02:00
Eugenio Lacuesta 91e505edfe
Return single element from coroutine callback (#4609) 2020-06-02 10:32:14 +02:00
Bulat Khabibullin 5cef927944
Implement TextResponse.json() (#4574) 2020-06-01 06:57:23 +02:00
Mikhail Korobov 13215cfb71
Merge pull request #4559 from elacuesta/cancel-request-download
Stop response download from signal handler
2020-05-27 21:46:00 +05:00
Andrey Rahmatullin ff699eb1f8
Merge pull request #4599 from elacuesta/LocalWeakReferencedCache-getitem-fix
Fix KeyError in LocalWeakReferencedCache
2020-05-27 21:42:04 +05:00
Andrey Rahmatullin 7bf375098e
Merge pull request #2400 from elacuesta/keep_cookie_header
[MRG+1] CookiesMiddleware: keep cookies from 'Cookie' request header, fix encoding
2020-05-27 21:41:43 +05:00
Eugenio Lacuesta 44d5801b05
Fix KeyError in LocalWeakReferencedCache 2020-05-27 11:15:33 -03:00
Eugenio Lacuesta 492197e477
StopDownload: store response in the exception instead of the failure 2020-05-27 10:45:07 -03:00
Eugenio Lacuesta 634ad5ebca
Merge remote-tracking branch 'upstream/master' into cancel-request-download 2020-05-27 10:27:45 -03:00
Kyle Altendorf 5b2af85289
Link to issue describing troublesome pytest versions 2020-05-22 15:09:58 -04:00
Eugenio Lacuesta f6ed5edc31
CookiesMiddleware: keep cookies from 'Cookie' request header 2020-05-21 11:07:41 -03:00
BroodingKangaroo 677e619d37 Fix too long lines 2020-05-21 14:57:03 +03:00
BroodingKangaroo 5f6c1dceb1 Merge remote-tracking branch 'upstream/master' into ISSUE-4250-add_batch_deliveries 2020-05-21 12:43:04 +03:00
Eugenio Lacuesta fbe915d9cb
StopDownload: check partial response contents 2020-05-20 20:20:30 -03:00
Eugenio Lacuesta 276721a5dc
Stop response download 2020-05-20 14:46:26 -03:00
Kyle Altendorf eb8493f09c
Incompatible with pytest 5.4 and 5.4.1 2020-05-20 09:21:34 -04:00
Mikhail Korobov febe82a907
Merge pull request #4486 from ilias-ant/add-file-status-on-media-pipelines-file-info
Add status (downloaded, uptodate) to files information
2020-05-18 22:30:30 +05:00
Mikhail Korobov 314adf6c38
Merge pull request #4237 from elacuesta/flake8-max-line-length
Set flake8-max-line-length to 119
2020-05-16 03:26:45 +05:00
Mikhail Korobov 14612fc3d3
Merge pull request #4534 from elacuesta/deprecate-baseitem
Deprecate scrapy.item.BaseItem
2020-05-16 03:24:06 +05:00
BroodingKangaroo 10ae1a284f Minor fixes 2020-05-15 22:50:54 +03:00
Adrián Chaves 36c3c9713e
Run tests with Python 3.5.0 (#4518)
* Run tests with Python 3.5.0

* Use Ubuntu Trusty 14.04 to test Python 3.5.0

* Use mitmproxy<3.0.0 on Python 3.5.0

* Skip tests requiring mitmproxy in Python 3.5.0

* Change the minimum Python version from 3.5 to 3.5.1

* Do not prevent Scrapy from working with Python 3.5.0

* Force system Python 3.5.1

* Do not install a non-system Python in Python 3.5.1 jobs

* Switch to Trusty to be able to test Xenial’s Python version ¯\_(ツ)_/¯

* Add missing trusty

* Stop breaking old PyPy

* Allow installing Scrapy on Python 3.5.0
2020-05-15 22:37:56 +05:00
Eugenio Lacuesta 3eeecb4273
Merge branch 'master' into flake8-max-line-length 2020-05-15 11:11:20 -03:00
Marc Hernández fffb0a5b6a
replace set constructor with set literals (#4573) 2020-05-15 15:23:09 +02:00
BroodingKangaroo 0627bf476e Merge remote-tracking branch 'upstream/master' into ISSUE-4250-add_batch_deliveries 2020-05-14 20:59:22 +03:00
Eugenio Lacuesta ee13c3e95f
Merge branch 'master' into deprecate-baseitem 2020-05-14 13:31:16 -03:00
Eugenio Lacuesta 89d0c98f7a
Merge remote-tracking branch 'upstream/master' into flake8-remove-e128 2020-05-14 11:35:30 -03:00
Eugenio Lacuesta df8a1d1c01
Flake8: Remove E741 2020-05-14 10:40:50 -03:00
BroodingKangaroo 111a58fe3d Merge remote-tracking branch 'upstream/master' into ISSUE-4250-add_batch_deliveries 2020-05-14 09:53:14 +03:00
Adrián Chaves e31b6ccc45
Merge branch 'master' into flake8-remove-e128 2020-05-13 22:39:45 +02:00
BroodingKangaroo 2327ecead0 Rename FEED_STORAGE_BATCH_SIZE to FEED_STORAGE_BATCH_ITEM_COUNT 2020-05-13 22:50:04 +03:00
Adrián Chaves 7dac99bb12
Merge branch 'master' into deprecate-baseitem 2020-05-13 20:35:03 +02:00
Andrey Rahmatullin 519f752d6d
Merge pull request #4566 from elacuesta/flake8-remove-f841
Flake8: remove F841
2020-05-13 11:46:48 +05:00
Aditya Kumar 97532a9144
test(spiderloader): no duplicate spider names (#4560) 2020-05-12 17:10:09 +02:00
willbeaufoy cf9be5344a
Prevent create_instance() returning None (#4532)
Currently create_instance() can return None if an extension is
incorrectly implemented, but the extension will still show up as
enabled in the logs. This can cause confusion, as in the linked bug.

This change prevents this occurring by throwing an error if
create_instance() will return None.
2020-05-11 20:35:25 +02:00
nsirletti cb8140a42a
Deprecate Response.body_as_unicode() (#4555)
Co-authored-by: Nicolas Sirletti <n.sirletti@gmail.com>
2020-05-11 20:20:31 +02:00
Eugenio Lacuesta 6f8758624c
Flake8: remove F841 2020-05-11 13:50:34 -03:00
Eugenio Lacuesta 25e9bc2d0d
Merge branch 'master' into flake8-remove-e128 2020-05-11 13:23:57 -03:00
Eugenio Lacuesta fb7ba6964d
Merge branch 'master' into deprecate-baseitem 2020-05-11 10:21:56 -03:00
Mikhail Korobov 892467cb8a
Merge pull request #4541 from elacuesta/pickle-adjustments
Pickle: use protocol 4, update tests
2020-05-11 15:16:14 +05:00
Mikhail Korobov b183579564
Merge pull request #4205 from elacuesta/bytes_received_signal
Add bytes_received signal
2020-05-11 15:09:55 +05:00
Eugenio Lacuesta 9485724d98
Merge branch 'master' into deprecate-baseitem 2020-05-08 19:32:47 -03:00
Eugenio Lacuesta be39f274b8
Merge branch 'master' into flake8-remove-e128 2020-05-08 18:33:29 -03:00
Mikhail Korobov 333910f6c8
Merge pull request #4554 from elacuesta/linkextractor-remove-lambdas
Remove lambda attributes in default link extractor
2020-05-09 02:11:59 +05:00
Eugenio Lacuesta c2c3054ac1
Flake8: remove E121 2020-05-08 16:43:47 -03:00
Eugenio Lacuesta 3ebf2a0d82
Remove lambdas in link extractor 2020-05-08 15:24:37 -03:00
Antonio Gordillo Toledo cf09af787e
Remove Python 2 encoding header from files (#4553) 2020-05-08 15:45:19 +02:00
Eugenio Lacuesta 6160370927
Merge remote-tracking branch 'upstream/master' into deprecate-baseitem 2020-05-07 14:38:54 -03:00
Eugenio Lacuesta 5256eae60d
Meta class to handle isinstance checks for BaseItem 2020-05-07 14:37:41 -03:00
Eugenio Lacuesta 8b4485134e
Merge branch 'flake8-remove-e126' into flake8-remove-e128 2020-05-07 12:50:20 -03:00
Eugenio Lacuesta 8659b0d896
Merge remote-tracking branch 'upstream/master' into flake8-remove-e126 2020-05-07 09:24:38 -03:00
Mikhail Korobov a8f61e909f
Merge pull request #4544 from elacuesta/flake8-remove-e129
Flake8: remove E129
2020-05-07 15:08:11 +05:00
Mikhail Korobov a18bfccac2
Merge pull request #4542 from elacuesta/flake8-remove-e122-e124
Flake8: remove E122 and E124
2020-05-07 15:05:01 +05:00
Eugenio Lacuesta 7fd2085725
Merge remote-tracking branch 'upstream/master' into bytes_received_signal 2020-05-06 22:41:16 -03:00
Eugenio Lacuesta d472402a02
Fix pickle test for pypy 2020-05-06 20:30:22 -03:00
Eugenio Lacuesta 881b4f417f
Flake8: Remove E128 (tests, part 3) 2020-05-06 19:33:22 -03:00
Eugenio Lacuesta bf56517abf
Flake8: Remove E128 (tests, part 2) 2020-05-06 19:18:29 -03:00
Mikhail Korobov 2da952b928
Merge pull request #4519 from Gallaecio/test-ubuntu-bionic
Test the latest Ubuntu along the latest Python
2020-05-07 03:12:19 +05:00
Eugenio Lacuesta 9c6d13075a
Flake8: Remove E128 (tests, part 1) 2020-05-06 18:56:14 -03:00
Eugenio Lacuesta 25eeb77ba6
Merge remote-tracking branch 'upstream/master' into flake8-max-line-length 2020-05-06 16:52:17 -03:00
Eugenio Lacuesta 88efc98847
Flake8: remove E129 2020-05-06 16:42:47 -03:00
Eugenio Lacuesta 4c12a234ae
Flake8: Remove E126 2020-05-06 16:10:21 -03:00
Eugenio Lacuesta cc23d1cb58
Flake8: Remove E124 2020-05-06 15:40:37 -03:00
Eugenio Lacuesta d71804ef29
Flake8: Remove E122 2020-05-06 15:23:36 -03:00
Adrián Chaves a859ea0c8b Merge remote-tracking branch 'upstream/master' into allow-customizing-export-column-names 2020-05-06 19:48:32 +02:00
Eugenio Lacuesta 0e382c8160
Remove unused import 2020-05-06 14:09:10 -03:00
Eugenio Lacuesta 93436f9d3a
Chain pickling exception, test_squeues.py updates 2020-05-06 14:05:27 -03:00
Eugenio Lacuesta b1ddd7bd7b
Refactor test_squeues.py 2020-05-06 13:44:02 -03:00
Eugenio Lacuesta 8643e8d355
Flake8: remove E123 (Closing bracket does not match indentation of opening bracket's line) 2020-05-06 12:26:04 -03:00
Eugenio Lacuesta 63600243e0
Flake8: remove E125 (Continuation line with same indent as next logical line)
Also remove E401 from pytest.ini - no occurrences in the codebase
2020-05-06 10:26:52 -03:00
Eugenio Lacuesta fe0c582ee0
Flake8: remove E127 in tests (continuation line over-indented for visual indent) 2020-05-06 09:49:10 -03:00
Adrián Chaves 98835a0d40
Merge branch 'master' into test-ubuntu-bionic 2020-05-06 13:59:01 +02:00
Eugenio Lacuesta 17c0cf64ae
Flake8: remove W504 code (#4525)
Co-authored-by: Mikhail Korobov <kmike84@gmail.com>
2020-05-06 00:14:48 +02:00
Eugenio Lacuesta 7988c676a9
Update Item docstring, update BaseItem occurrences 2020-05-05 13:11:01 -03:00
Eugenio Lacuesta 622ce86066
Test: make sure scrapy.item.Item does not issue a deprecation warning 2020-05-04 16:22:24 -03:00
Eugenio Lacuesta f75941f79d
Deprecate scrapy.item.BaseItem 2020-05-04 08:53:32 -03:00
BroodingKangaroo dad2ea7522 Change time_id to batch_time 2020-05-02 01:21:03 +03:00
Eugenio Lacuesta 4d625afda5
Merge branch 'master' into bytes_received_signal 2020-05-01 16:11:32 -03:00
BroodingKangaroo 3f9874fac9 Add test s3 export 2020-05-01 11:52:16 +03:00
Eugenio Lacuesta f787b8483c IPv6 test: check for the absence of DNSLookupError 2020-04-28 17:50:06 +02:00
BroodingKangaroo a18621552f Merge branch 'master' of https://github.com/BroodingKangaroo/scrapy into ISSUE-4250-add_batch_deliveries 2020-04-27 10:34:36 +03:00
BroodingKangaroo f0f1be76d1 Using time_id instead of time as a timestamp 2020-04-27 09:56:57 +03:00
Eugenio Lacuesta efb6f13deb
Remove assertions from production code (#4440) 2020-04-23 12:40:10 +02:00
Eugenio Lacuesta 1fecacbb1a
IPv6 test: check for the absence of DNSLookupError 2020-04-20 12:05:15 -03:00
ilias-ant 773ddf77ba added more tests to cover the (downloaded, uptodate, cached) status functionality 2020-04-19 14:14:17 +03:00
BroodingKangaroo ec76445dd6 Update tests 2020-04-18 09:29:23 +03:00
Mikhail Korobov 209ab05315
Merge pull request #4500 from victor-torres/reference-callback
Serialize requests with callback references as spider attribute
2020-04-17 18:58:28 +05:00
Victor Torres 1ade3fc723
trying to improve test coverage 2020-04-17 10:34:34 -03:00
Eugenio Lacuesta 7926da4bd0
Merge branch 'master' into flake8-max-line-length 2020-04-16 16:05:09 -03:00
Mikhail Korobov cf39602c30
Merge pull request #4471 from elacuesta/fix-pycodestyle-e731
Fix pycodestyle E731 ("do not assign a lambda expression, use a def")
2020-04-16 23:17:31 +05:00
Adrián Chaves ea3e675801 test_utils_iterators: use os.linesep 2020-04-16 17:10:45 +02:00
Adrián Chaves cf41803089 Skip test_reactor_poll on Windows 2020-04-16 17:07:29 +02:00
Adrián Chaves 7cc9601029 Improve reporting on test_ipv6_alternative_name_resolver 2020-04-16 16:57:48 +02:00
Eugenio Lacuesta c922992277
Tests: Move code inside __main__ block 2020-04-16 11:37:37 -03:00
Eugenio Lacuesta 1f2e2a6006
Merge branch 'master' into response_ip_address 2020-04-16 11:32:37 -03:00
Victor Torres e0921cab66
remove not used code
This code is not needed anymore because we're getting the
already mangled name when matching func with spider attributes.
2020-04-16 11:18:59 -03:00
Adrián Chaves 94ee68695a Mock server: use 127.0.0.1 also for HTTPS
Windows throws an error about 0.0.0.0 being external:
https://stackoverflow.com/a/23857995/939364
2020-04-16 15:37:06 +02:00
Adrián Chaves 1d77eac950 Fix Flake8-reported issues 2020-04-16 14:57:55 +02:00
BroodingKangaroo 5980ae72c6 Some minor fixes and refactoring 2020-04-16 10:13:39 +03:00
Victor Torres 47a992615a
serialize requests with callback references as spider attribute
You could define a spider attribute that references a callback method
but if this method has a different name than your spider attribute,
the request serializer is not able to find it on the spider class.

With this commit we're fixing this behavior as we're searching for
callback references in the spider object itself instead of looking
for attributes with the same function's name, that could be different.
2020-04-15 20:03:58 -03:00
BroodingKangaroo 16836e9e77 Merge branch 'ISSUE-4250-add_batch_deliveries' of https://github.com/BroodingKangaroo/scrapy into ISSUE-4250-add_batch_deliveries 2020-04-16 00:41:21 +03:00
BroodingKangaroo 963580463b Update tests 2020-04-15 23:39:46 +03:00
BroodingKangaroo 39d0d13d3f Add partial deliveries tests 2020-04-15 23:38:27 +03:00
Adrián Chaves 2f510fd47d Fix ShellTest.test_local_file on Windows 2020-04-15 21:10:05 +02:00
Mikhail Korobov 2d46777d0a
Merge pull request #4489 from elacuesta/remove-returnValue-function
Remove twisted.internet.defer.returnValue occurrences
2020-04-15 22:45:52 +05:00
Adrián Chaves c28dd0cedb
Merge branch 'master' into duplicate_key 2020-04-15 16:22:59 +02:00
Eugenio Lacuesta 01d73dd3f0
Merge branch 'master' into flake8-max-line-length 2020-04-15 09:24:33 -03:00
Adrián Chaves d323a57381
Merge branch 'master' into fix-pycodestyle-e731 2020-04-15 14:16:15 +02:00
Eugenio Lacuesta 94d7ad76cb
Fix pycodestyle E2XX (whitespace) (#4468) 2020-04-15 14:11:37 +02:00
Eugenio Lacuesta 4023d5db33
Replace _DefGen_Return exception handling
Handle StopIteration instead
2020-04-13 06:35:26 -03:00
Eugenio Lacuesta 1bd8f392c9
Initial removal of twisted.internet.defer.returnValue 2020-04-13 06:12:30 -03:00
ilias-ant 83a0cc6cdf Add status to files information 2020-04-12 23:22:17 +03:00
Eugenio Lacuesta 950a52468c
Merge branch 'master' into flake8-max-line-length 2020-04-10 15:24:22 -03:00
Eugenio Lacuesta 2265c1fda9
Merge branch 'master' into fix-pycodestyle-e731 2020-04-10 14:32:30 -03:00
Eugenio Lacuesta c4a5e3f0da
Simplify bytes_received signal
Remove "source" parameter
2020-04-06 09:26:13 -03:00
Eugenio Lacuesta e3342669ae
Merge branch 'master' into bytes_received_signal 2020-04-06 09:17:35 -03:00
Eugenio Lacuesta 4270e0a0da
Fix E731: do not assign a lambda expression 2020-04-04 21:54:55 -03:00
Eugenio Lacuesta e2d5d357a7
Fix pycodestyle E502 2020-04-01 14:24:30 -03:00
Adrián Chaves bdb28ac600 Merge remote-tracking branch 'origin/sybil' into azure-pipelines 2020-03-30 20:25:40 +02:00
Adrián Chaves 3fb0027138 Require sybil ≥ 1.3.0 for tests 2020-03-28 17:36:50 +01:00
Daniel Graña 02206e5ffe Run tox 2020-03-27 02:20:39 -03:00
Eugenio Lacuesta 182394bcec
E501 compliance (tests) 2020-03-22 23:29:30 -03:00
Eugenio Lacuesta 34d607194b
Merge branch 'master' into feat-685 2020-03-18 21:24:36 -03:00
elacuesta dfbe1d9507
Remove object base class (#4430) 2020-03-16 20:12:46 +01:00
Andrey Rahmatullin ecd3a976d2
Merge pull request #4398 from nyov/remove-crawler-spiders
Remove deprecated Crawler.spiders property
2020-03-16 17:21:07 +05:00
Eugenio Lacuesta aa6075e08c
Merge branch 'master' into bytes_received_signal 2020-03-15 18:05:04 -03:00
Eugenio Lacuesta bde0384dfd
Merge branch 'master' into spider.parse 2020-03-14 19:53:36 -03:00
Adrián Chaves 3f6cdcabce Restrict pytest to versions prior to 5.4 2020-03-13 13:25:53 +01:00
Lukas Anzinger ccc4d88779
Ignore a domain in allowed_domains with port and issue a warning (#4413) 2020-03-12 20:42:14 +01:00
nyov 3b0820d747
Deprecate Spider.make_requests_from_url, part 2 (#4412) 2020-03-12 20:15:49 +01:00
Mikhail Korobov db9198bc20
Merge pull request #4409 from nyov/remove-deprecation-warning
Remove a 'twisted.test.proto_helpers' deprecation warning
2020-03-12 18:46:47 +05:00
Eugenio Lacuesta 8d30dc0888
Response.follow_all: return empty generators for empty sequences 2020-03-12 09:36:15 -03:00
Andrey Rahmatullin 388f23c30c
Merge pull request #3858 from elacuesta/multiple_feed_export_formats
[MRG+1] Support for exporting to multiple feeds in a single crawl
2020-03-12 14:31:57 +05:00
Eugenio Lacuesta 21f1eddc90
Merge branch 'master' into bytes_received_signal 2020-03-11 21:16:35 -03:00
Eugenio Lacuesta f3bab819ab
Add tests for scrapy.utils.conf.feed_complete_default_values_from_settings 2020-03-11 20:57:31 -03:00
Eugenio Lacuesta ac73bcc79c
Merge branch 'master' into response_ip_address 2020-03-08 22:30:59 -03:00
Lukas Anzinger 9d9dea0d69 Fix handling of None in allowed_domains.
Nones in allowed_domains ought to be ignored and there are also tests
for that scenario. This commit fixes the handling of None and also the
accompanying tests which are now executed again.
2020-03-07 20:34:18 +01:00
nyov 915e363db5 Remove a 'twisted.test.proto_helpers' deprecation warning 2020-03-07 18:03:25 +00:00
Eugenio Lacuesta ada37c5409
Export to multiple formats in a single crawl 2020-03-05 09:33:57 -03:00
nyov b1566a6962 Remove deprecated Crawler.spiders property
Deprecated since 419026615 (2014, Scrapy 0.25)
2020-03-04 21:23:42 +00:00
Eugenio Lacuesta 3aa5eab993
Merge branch 'master' into response_ip_address 2020-03-03 13:53:43 -03:00
nyov 1b591ff061 Obsolete deprecated settings
Obsolete REDIRECT_MAX_METAREFRESH_DELAY
  which has been deprecated since Scrapy 0.18

Obsolete LOG_UNSERIALIZABLE_REQUESTS
  which has been deprecated since Scrapy 1.2.0
  and is replaced by SCHEDULER_DEBUG
2020-03-03 14:03:30 +00:00
Adrián Chaves 6aa0ba4553
Write release notes for Scrapy 2.0.0 (#4329) 2020-03-03 09:11:11 +01:00
sakshamb2113 c411a51f42
Fix random failures from test_fixed_delay in some machines (#4372) 2020-02-28 13:17:02 +01:00
Adrián Chaves 9aae4c0be7 Add tests for envvar setting warnings 2020-02-27 16:31:43 +01:00
gunblues 034e2c31c7
Use a non-zero exit code when a pipeline's open_spider method throws an exception (#4207)
* fix issue 4175 - Scrapy does not use a non-zero exit code when pipeline's open_spider throws the exception

* remove extra blank lines

* remove redundant code

* remove blank line at end of file

* more suitable naming for response and make if-condition shorter

* avoid error - AttributeError: 'Deferred' object has no attribute 'result'

* use getattr to make code concisely

* add test

* remove useless file

* modify test class name

* remove unneccessary files

* Fix Flake8-reported issue

* fix these items which are suggested by Gallaecio
・Sort those imports at tests/test_cmdline_crawl_with_pipeline/__init__.py
・Remove the unused setUp method.
・Remove comments generated by Scrapy’s project generation tool.
・Remove the [deploy] section from the scrapy.cfg file (I don’t think it’s needed here)
・Remove BOT_NAME and NEWSPIDER_MODULE from settings.py (I think there are not needed either, although I’m less sure about NEWSPIDER_MODULE)

* have to reserve BOT_NAME, SPIDER_MODULES in settings.py

* Remove unneeded empty lines

* Empty __init__.py file with unneeded comments

* Remove an unneeded empty line at the end

* Remove unneeed empty line from __init__.py file

* Update __init__.py

* Update __init__.py

* Update exception.py

* Update normal.py

* Update __init__.py

* Update __init__.py

* fix W391 blank line at end of file

Co-authored-by: Adrián Chaves <adrian@chaves.io>
2020-02-26 00:46:05 +05:00
Eugenio Lacuesta 889b471852
Import changes 2020-02-23 18:40:43 -03:00
Eugenio Lacuesta a44942d27d
Merge branch 'master' into response_ip_address 2020-02-23 18:13:52 -03:00
Mikhail Korobov 49480225d7
Merge pull request #4365 from noviluni/fix_flake8_E701_E271
Fix flake8 E131, E211, E251, E271, E701
2020-02-23 15:52:52 +05:00
elacuesta 9d983c1b99
Expose certificate for HTTPS responses (#4054)
* Expose certificate for HTTPS responses

* Fix test (missing inlineCallbacks decorator)

* Note about Response.certificate

* Explicitly cover None as the default value of Response.certificate

Co-authored-by: Adrián Chaves <adrian@chaves.io>
2020-02-22 17:20:31 +05:00
Vostretsov Nikita 67ee0b097f
Remove specifics of downstream request queues from scheduler (#3884)
* move serialization/deserialization logic to downstream queues

* make memory queues conform to common interface

* make ScrapyPriorityQueue conform common interface

* ScrapyPriorityQueue works with disk

* make key as string

* return list instead of dict as earlier

* downloader aware pq works with new interface

* we don`t need these methods anymore

* create directories for files

* remove dummy priority

* remove priority as parameter, let every queue decide for itself

* rename obj to request

* DownloaderAwarePriorityQueue is too thin wrapper around _SlotPriorityQueues, just remove second one

* remove priority as parameter, let every queue decide for itself

* rename argument

* more granular class separation

* python2 compatible

* one more argument for common interface

* more simple downstream queue interface

* single place for easier customization

* rename function

* shorter

* shorter

* use named arguments

* fix typo

* add docstring

* Update scrapy/pqueues.py

Co-Authored-By: Mikhail Korobov <kmike84@gmail.com>

* Update scrapy/pqueues.py

Co-Authored-By: Mikhail Korobov <kmike84@gmail.com>

* 4 spaces indentation

* we ok with existing directories

* remove unused import

* rename method

* remove unused imports

* it has no sense now

* relining

* note about queues

* add value

* Revert "it has no sense now"

This reverts commit b61604275b.

* pep8 E261

* pep8 E303

* pep8 E501

* pep8 E123

* pep8 E123

* use create instance

* remove excessive import

Co-authored-by: Mikhail Korobov <kmike84@gmail.com>
2020-02-22 17:02:57 +05:00
Marc Hernandez Cabot 6e8e117aee fix flake E211 2020-02-22 12:32:38 +01:00
Marc Hernandez Cabot 69a8648bef fix E251 2020-02-22 12:32:38 +01:00
Marc Hernandez Cabot 9ad10bb6f7 fix E131 2020-02-22 12:32:38 +01:00
Marc Hernandez Cabot b49ece0b87 fix E701 and E271 flake8 2020-02-22 12:32:38 +01:00
Mikhail Korobov e551bc5170
Merge pull request #4318 from wRAR/asyncio-parse-asyncgen
Support yield in async def callbacks.
2020-02-21 23:50:01 +05:00
Marc Hernandez Cabot 6fb85951ce fix E22X flake8 2020-02-21 08:39:14 +01:00
Marc Hernández 91bbc70bc1
fix E30X flake8 (#4355) 2020-02-21 06:05:31 +01:00
Andrey Rahmatullin 88179027de
Merge pull request #4331 from Gallaecio/response-cb-kwargs
Implement Response.cb_kwargs
2020-02-19 22:40:14 +05:00
Andrey Rahmatullin f558df2558
Merge pull request #4188 from elacuesta/logformatter-error-formatting
LogFormatter error formatting
2020-02-19 19:05:08 +05:00
Andrey Rahmatullin 528b894f28
Merge pull request #4321 from Gallaecio/link-extractor-encoding
Use safe_url_string in link extraction
2020-02-19 18:19:21 +05:00
Adrián Chaves 5834088e67 Apply feedback 2020-02-18 14:18:15 +01:00
Adrián Chaves 43b43654a1 Add tests for meta and cb_kwargs not being available 2020-02-13 22:39:58 +01:00
Adrián Chaves 5ff9eb90ea Add a test for the copy of cb_kwargs from Request to Response 2020-02-13 22:36:18 +01:00
Adrián Chaves b4958358e8 Update tests to account for link extractors escaping spaces 2020-02-12 19:00:04 +01:00
Adrián Chaves e1be078eaa Fix Flake8-reported issues 2020-02-12 17:38:06 +01:00
Mikhail Korobov a6ef065eb5
Merge pull request #4271 from wRAR/asyncio-signals
async def support for signal handlers that already supported Deferreds
2020-02-11 02:05:45 +05:00
Andrey Rakhmatullin 1f0f52cbf7 Improve async signal tests. 2020-02-11 01:05:45 +05:00
Andrey Rakhmatullin 36dcf90184 Also test non-default async callbacks. 2020-02-11 01:00:16 +05:00
Abhishek Pratap Singh 4626e90df8
Allow updating flags in follow and follow_all (#4279) 2020-02-10 19:48:31 +01:00
Adrián Chaves 96bb3b5144
Merge branch 'master' into feat-685 2020-02-10 19:45:09 +01:00
Eugenio Lacuesta 122ce6d6fb
Check bytes are received in order (bytes_received signal) 2020-02-10 10:20:26 -03:00
Adrián Chaves 35723d76c0 Use canonicalize_url in link extraction 2020-02-07 22:59:53 +01:00
Adrián Chaves c2f484de88
Merge branch 'master' into response_ip_address 2020-02-07 21:49:38 +01:00
Adrián Chaves 4c6993f264
Merge branch 'master' into asyncio-parse-asyncgen 2020-02-07 21:34:54 +01:00
Adrián Chaves aae4935605
Merge branch 'master' into spider.parse 2020-02-07 21:17:56 +01:00
Mikhail Korobov 957681bcfa
Merge pull request #4272 from elacuesta/spider-middleware
Spider middleware: catch spider callback exceptions early
2020-02-07 23:40:50 +05:00
Mikhail Korobov afbaf9d430
Merge pull request #4303 from whalebot-helmsman/request_left_downloader_signal
request_left_downloader signal
2020-02-07 23:33:51 +05:00
Andrey Rakhmatullin 7323780c97 Support yield in async def callbacks. 2020-02-07 21:32:45 +05:00
Andrey Rakhmatullin 31f6c7112f Add a test for an async callbacks that returns requests. 2020-02-07 17:14:52 +05:00
Andrey Rakhmatullin 4a7c7340a0 Merge remote-tracking branch 'origin/master' into asyncio-signals 2020-02-07 16:58:59 +05:00
Eugenio Lacuesta 6c333491a8
Merge branch 'master' into response_ip_address 2020-02-06 18:53:11 -03:00
Eugenio Lacuesta 7f2d3051fe
Fix Flake8 issue 2020-02-06 18:19:40 -03:00
Lane Shaw 3263441fbc
Update RFPDupeFilter line separator for correct universal newlines mode usage (#4283) 2020-02-06 22:14:40 +01:00
Adrián Chaves 24bb9fd5f7
Merge branch 'master' into spider.parse 2020-02-06 21:39:09 +01:00
Mikhail Korobov 042e71e2b8
Merge pull request #4311 from Gallaecio/metarefresh-ignore-tags
Make METAREFRESH_IGNORE_TAGS an empty list by default
2020-02-06 23:40:45 +05:00
elacuesta 35dafef7f1
Specify Twisted reactor (TWISTED_REACTOR setting) (#4294)
* Add the ability to install a specific reactor

* Add docs for the TWISTED_REACTOR setting

* Add tests for the TWISTED_REACTOR setting

* Update asyncio reactor test

* Ignore W503 globally

W503 is not PEP8-compliant:
c59c4376ad

* Line length adjustment

* Adjust asyncio reactor tests

* Merge ASYNCIO_ENABLED and TWISTED_REACTOR settings

* More docs about TWISTED_REACTOR

* Fix asyncio reactor test

* Docs: fix title

* Reword docs

* Check the TWISTED_REACTOR setting outside of the installing function

* Remove unrelated change

* Update scrapy/utils/log.py

Co-Authored-By: Adrián Chaves <adrian@chaves.io>

* Update docs/topics/settings.rst

Co-Authored-By: Adrián Chaves <adrian@chaves.io>

* Update docs/topics/settings.rst

Co-Authored-By: Adrián Chaves <adrian@chaves.io>

Co-authored-by: Adrián Chaves <adrian@chaves.io>
2020-02-06 22:42:34 +05:00
Andrey Rakhmatullin 489ffcda51 Add a test for an async item_scraped handler. 2020-02-06 22:40:11 +05:00
Vostretsov Nikita 4be19e443e name signla catcher in accord with signal name 2020-02-06 13:46:23 +00:00
Vostretsov Nikita 4a91a5427d fix typo 2020-02-06 13:44:51 +00:00
Adrián Chaves 576663e5a7 Make METAREFRESH_IGNORE_TAGS an empty list by default 2020-02-06 10:43:20 +01:00
Vostretsov Nikita 3769f75386 pep8 E302 2020-02-05 12:08:08 +00:00
Vostretsov Nikita 9916f6e556 tests for new signal 2020-02-05 11:32:54 +00:00
Eugenio Lacuesta ad70497416
Remove unnecessary parentheses in class definition 2020-02-04 13:30:13 -03:00
Eugenio Lacuesta e0ef8ad2d6
CrawlerRunner test for Response.ip_address 2020-02-03 15:52:15 -03:00
Eugenio Lacuesta 4851efdfb0
Flake8 adjustments 2020-02-03 14:50:54 -03:00
Eugenio Lacuesta bb8f7dc609
Mock DNS server 2020-02-03 14:50:14 -03:00
Eugenio Lacuesta a2ae380efc
Remove unnecessary commas 2020-02-03 13:23:52 -03:00
Eugenio Lacuesta b9e3a6201b
Merge branch 'master' into response_ip_address 2020-02-03 04:07:44 -03:00
Mikhail Korobov 22f7934fcc
Merge pull request #4269 from wRAR/asyncio-parse
Support for async def callbacks.
2020-01-31 23:50:19 +05:00
Andrey Rakhmatullin 7687564c73 Merge remote-tracking branch 'origin/master' into asyncio-signals 2020-01-30 17:42:03 +05:00
Andrey Rakhmatullin cc825c21de Test returning items from an async def callback. 2020-01-30 16:17:06 +05:00
Eugenio Lacuesta 6f02a8dccb
Add source parameter to bytes_received signal 2020-01-29 15:51:25 -03:00
Eugenio Lacuesta 2c9643d38c
Test: bytes_received signal fired multiple times 2020-01-29 14:17:06 -03:00
Evgeny Dorofeev 4e56571a19 [HttpCompressionMiddleware] fix delimiter for Accept-Encoding header 2020-01-29 15:49:22 +03:00
Eugenio Lacuesta 613fd41f44
bytes_received signal: improve test performance 2020-01-27 13:25:06 -03:00
Eugenio Lacuesta dbe20a863f
bytes_received signal: send spider argument 2020-01-27 12:28:54 -03:00
Adrián Chaves 89483ce9f7
Fix Flake8 issues 2020-01-27 12:08:56 -03:00
Eugenio Lacuesta bda37e38bd
[Tests] bytes_received signal 2020-01-27 12:08:56 -03:00
Eugenio Lacuesta cab449b195
Typo fix 2020-01-27 12:08:34 -03:00
Eugenio Lacuesta e8da7e2966
Test DNS resolution using CrawlerProcess 2020-01-26 17:53:39 -03:00
Eugenio Lacuesta 80925ab845
Get server IP address for HTTP/1.1 responses 2020-01-26 16:57:04 -03:00
Mikhail Korobov 8b8df31961
Merge pull request #4227 from elacuesta/name-resolver
Name resolver with IPv6 support
2020-01-25 05:03:13 +05:00
Mikhail Korobov 5f407cf657
Merge pull request #3961 from OmarFarrag/ftp_files#3928
Add FTPFileStore to FilesPipeline
2020-01-25 04:58:23 +05:00
Mikhail Korobov 7a62bd310c
Merge pull request #4126 from elacuesta/from_crawler_downloader_handlers
Download handlers: from_crawler factory method, take crawler in __init__
2020-01-25 04:52:56 +05:00
OmarFarrag 40e0a11aa8 Fix Flake8 errors 2020-01-24 15:51:48 +02:00
OmarFarrag fc98aa6b67
Merge branch 'master' into ftp_files#3928 2020-01-24 14:52:40 +02:00
Mikhail Korobov f80c7776ae
Merge pull request #4008 from elacuesta/docs_request_errback
Request: remove restriction about errback without callback
2020-01-23 23:12:44 +05:00
Mikhail Korobov c0a7dfbc01
Merge pull request #4057 from elacuesta/response_follow_all
Response.follow_all
2020-01-23 02:15:24 +05:00
Eugenio Lacuesta dee420a69c
Fix name resolvers tests 2020-01-16 23:48:16 -03:00
Eugenio Lacuesta d487498cff
Update name resolvers tests 2020-01-16 22:02:01 -03:00
Eugenio Lacuesta 90e3bd8715
[test] Name resolvers 2020-01-16 20:32:40 -03:00
Eugenio Lacuesta 6ce1ad3107
[test] Spider middleware: catch exceptions right after the spider callback 2020-01-10 04:20:37 -03:00
Andrey Rakhmatullin a91a13b443 Support for async def callbacks. 2020-01-09 15:59:19 +05:00
Andrey Rakhmatullin 3faef2d082 Add async def support to signal handlers that already supported Deferreds. 2020-01-09 15:17:45 +05:00
Andrey Rakhmatullin 7d85984880 Use get_from_asyncio_queue in the pipeline test. 2020-01-09 14:49:16 +05:00
Andrey Rakhmatullin bdef948aae Mark the asyncio pipelines test as only_asyncio. 2020-01-09 14:19:02 +05:00
Andrey Rakhmatullin bfdd552a32 Add a test for pipelines using asyncio. 2020-01-09 14:19:02 +05:00
Andrey Rakhmatullin 1f9cef787d Add async def support to pipelines. 2020-01-09 14:19:02 +05:00
Eugenio Lacuesta 2e405d2d5c
Merge branch 'master' into response_follow_all 2020-01-05 00:33:19 -03:00
Andrey Rakhmatullin 2b9254c2bd Add a test function that uses asyncio.Queue(). 2019-12-31 17:54:41 +05:00
Andrey Rakhmatullin 16787f5bf4 Merge middleware tests back as we don't need to set the setting anymore. 2019-12-30 12:02:19 +05:00
Andrey Rakhmatullin 5cf1ac0005 Move the asyncio downloader mw test to a separate class. 2019-12-30 11:46:45 +05:00
Andrey Rakhmatullin 3603644552 Add a non-asyncio async def middleware test. 2019-12-30 11:46:45 +05:00
Andrey Rakhmatullin 21f50c795a Add async def support to downloader middlewares. 2019-12-30 11:46:45 +05:00
Mikhail Korobov bb991cd303
Merge pull request #4010 from scrapy/asyncio-base
Base support for asyncio
2019-12-30 00:51:28 +05:00
Andrey Rakhmatullin dc1ee09481 Rename ASYNCIO_ENABLED to ASYNCIO_REACTOR, change the logic accordingly. 2019-12-27 21:56:28 +05:00
Eugenio Lacuesta c54df8253a
[test] Handle keyword args in CrawlSpider.parse 2019-12-26 15:12:19 -03:00
Eugenio Lacuesta 8d4948f6ca
[test] Override CrawlSpider.parse 2019-12-26 14:38:11 -03:00
Andrey Rakhmatullin 37ac47ff80 Fix a deprecation warning. 2019-12-26 20:46:54 +05:00
Eugenio Lacuesta 982a66f9fb
[test] Download handler: avoid passing settings if not necessary 2019-12-23 20:28:17 -03:00
nyov b9a58798ee
change Scraper API to call internal `_parse` method
A Spider class using internal pre-processing can have first dibs
at this and then call a public `parse` method for subclass hooking.
2019-12-23 13:55:06 -03:00
Eugenio Lacuesta a6ec89251e
Downloader handlers: crawler=None in __init__ 2019-12-23 10:47:08 -03:00
Eugenio Lacuesta 8a567e98bb
Remove unnecessary __init__ methods in downloader handler tests 2019-12-23 10:36:46 -03:00
Eugenio Lacuesta 7e6387de40
Use create_instance in FTPDownloadHandler/DataURIDownloadHandler tests 2019-12-23 10:02:58 -03:00
Eugenio Lacuesta fa21d8687a
Use create_instance in S3DownloadHandler tests 2019-12-23 10:00:25 -03:00
Eugenio Lacuesta 9e5d945ef2
Use create_instance in downloader handler tests 2019-12-23 09:55:47 -03:00
Eugenio Lacuesta 931b7e68d3
Update FileDownloadHandler test 2019-12-23 09:50:28 -03:00
Eugenio Lacuesta 310cc081d0
Merge branch 'master' into from_crawler_downloader_handlers 2019-12-21 17:24:45 -03:00
Andrey Rakhmatullin 8de80f59db Raise an exception if ASYNCIO_ENABLED but the reactor is wrong. 2019-12-21 13:08:29 +05:00
Mikhail Korobov 5577d4d2be
Merge pull request #3869 from elacuesta/detect_return_in_generator_callbacks
[MRG+1][Py3] Check for 'return' with arguments inside generators
2019-12-20 22:46:46 +05:00
Andrey Rakhmatullin e342de5038 Remove a stray newline. 2019-12-20 19:37:50 +05:00
Andrey Rakhmatullin 20289be810 Merge remote-tracking branch 'origin/master' into asyncio-base 2019-12-20 19:31:20 +05:00
Mikhail Korobov fb3fb17c28
Merge pull request #4045 from Gallaecio/documentation-coverage
Deprecate FilteringLinkExtractor direct usage; add API docs for scrapy.linkextractors
2019-12-20 02:01:45 +05:00
Mikhail Korobov 3bcb14fe4d
Merge pull request #4164 from Gallaecio/speed-up-tests-2
Improve the performance of the DOWNLOAD_DELAY test
2019-12-18 23:56:56 +05:00
Marc Hernandez Cabot a5de2c64e6 fix W291, W292, W293 (whitespaces) 2019-12-18 16:33:46 +01:00
elacuesta 916382e109 Add errback parameter to scrapy.spiders.crawl.Rule (#4000)
* Add errback parameter to scrapy.spiders.crawl.Rule

* CrawlSpider: optimize by reducing iterations

* [test] Rule.errback

* [doc] Rule.errback

* [doc] Use autoclass in docs/topics/spiders.rst

Co-Authored-By: Adrián Chaves <adrian@chaves.io>

* Rule.process_links takes a list

* Fix aesthetic issue reported by Flake8
2019-12-18 20:05:33 +05:00
Andrey Rakhmatullin 7ccb169a27 Split a long test in test_engine.py into three. 2019-12-18 19:41:16 +05:00
Mikhail Korobov e90f276903
Merge pull request #4198 from wRAR/deprecate-noconnect
Deprecate the HTTPS proxy noconnect mode.
2019-12-18 16:11:24 +05:00
Adrián Chaves 1f689b50c6 Merge remote-tracking branch 'origin/documentation-coverage' into documentation-coverage 2019-12-18 12:09:34 +01:00
Adrián Chaves 174769a3f0 Use a better name for the LxmlLinkExtractor subclassing test 2019-12-18 12:09:03 +01:00
Andrey Rakhmatullin ac302c3f61 Fix a flake8 problem. 2019-12-18 15:43:05 +05:00
Andrey Rakhmatullin bb2ff13e4c Skip Http10ProxyTestCase.test_download_with_proxy_https_noconnect 2019-12-18 15:39:08 +05:00
Andrey Rakhmatullin 2d92a39003 Restore test_download_with_proxy_https_noconnect, check for a warning there. 2019-12-18 12:07:08 +05:00
Adrián Chaves 607815dfc2
Merge branch 'master' into documentation-coverage 2019-12-17 16:54:27 +01:00
Andrey Rahmatullin bb3f164280
Merge pull request #4236 from wRAR/pipeline-tests
Add simple tests for pipelines.
2019-12-17 19:38:06 +05:00
Adrián Chaves ab13221b0b Merge remote-tracking branch 'upstream/master' into allow-customizing-export-column-names 2019-12-17 14:06:14 +01:00
Marc Hernández 63cf5c75c8 Fix E502: backslash is redundant between brackets (#4238) 2019-12-17 13:53:15 +01:00
Andrey Rakhmatullin 5980d3bbff Add simple tests for pipelines. 2019-12-16 22:41:28 +05:00
Eugenio Lacuesta 451e7a616e
Scan callbacks/errbacks for return statements with values different than None 2019-12-16 11:30:40 -03:00
Adrián Chaves a4ef9750f9 Fix Flake8-reported issues 2019-12-13 14:32:06 +01:00
Adrián Chaves b5c4c2cae8
Keep 2 spaces between code and inline comments (#4195) 2019-12-13 14:20:48 +01:00
Andrey Rakhmatullin bfb78b8dea Add CrawlerProcess tests for ASYNCIO_ENABLED. 2019-12-13 18:12:07 +05:00
Andrey Rakhmatullin 3560123090 Rename ASYNCIO_SUPPORT to ASYNCIO_ENABLED. 2019-12-13 18:07:47 +05:00
Andrey Rakhmatullin 352ddbb336 Merge remote-tracking branch 'origin/master' into asyncio-base 2019-12-13 18:07:23 +05:00
Andrey Rahmatullin 02cdc53fb8
Add a test for a CrawlerProcess script. (#4218)
* Add a test for a CrawlerProcess script.

* Add tests/CrawlerProcess to collect_ignore.

* Remove an extra line.

* Fix/improve conftest.py.
2019-12-13 18:04:05 +05:00
Eugenio Lacuesta 21a2f8c6f8
Merge branch 'master' into response_follow_all 2019-12-10 17:30:59 -03:00
Adrián Chaves 1fc2b140c1
Merge branch 'master' into documentation-coverage 2019-12-05 14:43:36 +01:00
Andrey Rahmatullin 076f0764b7
Merge pull request #4121 from scrapy/remove-six-code
Remove six-related code and __future__ imports
2019-12-05 18:20:14 +05:00
Mikhail Korobov 250da28952
Merge pull request #4170 from mabelvj/4133-handle-start_url
Raise error when start_url found instead of start_urls.
2019-12-05 17:47:03 +05:00
Andrey Rakhmatullin ed34ce14c0 Add the ASYNCIO_SUPPORT setting, reshuffle other logic accordingly. 2019-12-04 21:32:56 +05:00
Andrey Rakhmatullin cc19ab5439 Add tests that check asyncio support. 2019-12-04 21:32:56 +05:00
Andrey Rakhmatullin b04b541372 Install the asyncio reactor only in scrapy.cmdline. 2019-12-04 21:32:56 +05:00
Andrey Rakhmatullin 8d8fbddbde Switch to the released version of pytest-twisted. 2019-12-04 21:32:56 +05:00
Andrey Rakhmatullin 9777639533 Run tests using the asyncio reactor. 2019-12-04 21:32:56 +05:00
Andrey Rakhmatullin 1b35260625 Add a test for downloader middlewares using Deferreds. 2019-12-04 21:32:56 +05:00
Eugenio Lacuesta 62778cf23f
Request: remove restriction about errback without callback 2019-12-04 08:53:38 -03:00
Eugenio Lacuesta 2a9f5a0aef
Skip invalid links when passing SelectorLists to Response.follow_all 2019-12-03 16:01:42 -03:00
Eugenio Lacuesta e43f37fff3
Pass args/kwargs in S3DownloadHandler.from_crawler, update tests 2019-12-02 17:36:31 -03:00
Eugenio Lacuesta 3d77f74e40
Download handlers: from_crawler factory method, take crawler instead of settings in __init__ 2019-12-02 17:36:31 -03:00
Andrey Rakhmatullin 63546cbf3e Deprecate the HTTPS proxy noconnect mode. 2019-11-27 22:42:52 +05:00
Adrián Chaves 6d9ed6146d
Merge branch 'master' into remove-six-code 2019-11-25 10:34:21 +01:00
Eugenio Lacuesta 03af8885ff
LogFormatter.download_error 2019-11-23 20:02:44 -03:00
Eugenio Lacuesta 4756e7c587
LogFormatter.spider_error 2019-11-23 19:33:29 -03:00
Eugenio Lacuesta facb926542
Remove quotes from item_error message 2019-11-23 19:16:41 -03:00
Eugenio Lacuesta 7a7d13b112
Rename LogFormatter.error to item_error 2019-11-23 19:12:03 -03:00
Eugenio Lacuesta 40b5cfc0a4
Item loaders: allow single-argument processors (unbound methods) 2019-11-22 20:47:22 -03:00
Eugenio Lacuesta 6fa8f06b64
Merge remote-tracking branch 'upstream/master' into response_follow_all 2019-11-22 13:05:06 -03:00
Eugenio Lacuesta 5bab3c0261
Merge remote-tracking branch 'upstream/master' into remove-six-code 2019-11-22 12:12:29 -03:00
Mikhail Korobov 16e0636dcf
Merge pull request #4186 from Gallaecio/lgtm
Remove unused imports
2019-11-22 12:28:29 +05:00
Mabel Villalba 070b3a4e84
Merge branch 'master' into 4133-handle-start_url 2019-11-21 17:10:31 +01:00
Mabel Villalba 1718e450ef [start_url] Fixes #4133: Raise AttributeError error when empty 'start_urls' and 'start_url' found. Added test. 2019-11-21 17:06:47 +01:00
Mikhail Korobov d2b73b8e21
Merge pull request #4114 from scrapy/remove-py2-tests
Remove py2 tests
2019-11-21 18:22:10 +05:00
Adrián Chaves a2bf340bab Remove unused imports 2019-11-21 14:21:17 +01:00
Eugenio Lacuesta 714e0d3ac9
Merge remote-tracking branch 'upstream/master' into remove-six-code 2019-11-20 12:41:38 -03:00
Mikhail Korobov 65e2fb7d89
Merge pull request #4153 from Gallaecio/lgtm
MutableChain: return self from __iter__
2019-11-20 19:46:20 +05:00
Mikhail Korobov e96ca89a1d
Merge pull request #4174 from Gallaecio/flake8
Add missing blank lines between functions and classes
2019-11-20 19:34:04 +05:00
Eugenio Lacuesta 6781d2f5b2
Update sample file references 2019-11-20 09:58:25 -03:00
Eugenio Lacuesta 48223c107a
Merge remote-tracking branch 'upstream/master' into response_follow_all 2019-11-20 09:41:42 -03:00
Eugenio Lacuesta b602c61e1c
[Test] Rename outdated sample files 2019-11-20 09:38:54 -03:00
Eugenio Lacuesta 6f6426559d
Merge remote-tracking branch 'upstream/remove-py2-tests' into remove-six-code 2019-11-19 11:04:46 -03:00
Eugenio Lacuesta 05785c1c17
Merge remote-tracking branch 'upstream/master' into remove-six-code 2019-11-19 11:01:34 -03:00
Andrey Rahmatullin 78ad01632f Fix flake8 problems in PR #3989 (#4176) 2019-11-19 10:43:30 +01:00
Andrey Rakhmatullin beb7d80d6a Add a comment about the noconnect tests. 2019-11-19 13:52:49 +05:00
Andrey Rakhmatullin 922a66cf07 Fix or ignore flake8 problems. 2019-11-19 13:52:49 +05:00
Andrey Rakhmatullin a7b640991d Rename tests/py3-ignores.txt to tests/ignores.txt. 2019-11-19 13:52:49 +05:00
Andrey Rakhmatullin 8b730a3670 Use self.proc.communicate() after killing mitmdump. 2019-11-19 13:52:49 +05:00
Andrey Rakhmatullin 5970d00eb9 Only xfail test_https_connect_tunnel_error on 3.6+. 2019-11-19 13:52:49 +05:00
Andrey Rakhmatullin 5080180c75 Improve the test_https_tunnel_without_leak_proxy_authorization_header change. 2019-11-19 13:52:49 +05:00
Andrey Rakhmatullin c4ef950efd Use an older mitmproxy for py3.5. 2019-11-19 13:52:49 +05:00
Andrey Rakhmatullin 3ec6960732 Fix test_proxy_connect.py for py3.5. 2019-11-19 13:52:49 +05:00
Andrey Rakhmatullin c327ad9ba6 Remove an unused six import. 2019-11-19 13:52:49 +05:00
Andrey Rakhmatullin cbb6d0c6a7 Mark failing proxy tests. 2019-11-19 13:52:49 +05:00
Andrey Rakhmatullin f066257e95 Restore tests/test_proxy_connect.py and update it to modern mitmproxy. 2019-11-19 13:52:49 +05:00
Andrey Rakhmatullin e18014d84d Remove Python 2-only tests. 2019-11-19 13:52:49 +05:00
Andrey Rahmatullin 25cd7ac7ab
Merge pull request #4094 from victor-torres/invalid-url
Improve URL schema validation on scrapy.Request initialization
2019-11-19 13:50:08 +05:00
Andrey Rahmatullin 3408b757c1
Merge pull request #3989 from elacuesta/logformatter_error_method
LogFormatter improvements
2019-11-19 13:44:43 +05:00
Adrián Chaves f261cf65e9 Add missing blank lines between functions and classes
Also fixed 2 unrelated Flake8 issues
2019-11-18 17:16:09 +01:00
Adrián Chaves 99d8b05a0b Deprecate scrapy.utils.python.MutableChain.next 2019-11-18 10:58:47 +01:00
Marc Hernandez Cabot 0e252f5a13 fix E711 and E713 2019-11-15 19:12:43 +01:00
Mikhail Korobov 550d8046fd
Merge pull request #4157 from Gallaecio/flake8
Add missing whitespace after ‘,’, ‘;’ or ‘:’
2019-11-14 23:42:06 +05:00
Andrey Rakhmatullin 3b2289ad01 Rename test_non_str_url_py2 to test_bytes_url. 2019-11-14 22:53:28 +05:00
Andrey Rakhmatullin fe3a121f13 Use kwargs when calling get_func_args. 2019-11-14 22:50:53 +05:00
Adrián Chaves 058bdda0af Improve the performance of the DOWNLOAD_DELAY test 2019-11-14 16:53:20 +01:00
Andrey Rakhmatullin e291460db6 Fix flake8-detected errors. 2019-11-14 15:24:37 +05:00
Adrián Chaves 1a4a77d49f Remove Python 2 check from MutableChainTest 2019-11-14 10:24:31 +01:00
Andrey Rakhmatullin 87c23ba22d Remove Py2-only code that checks sys.version_info. 2019-11-14 13:45:39 +05:00
Andrey Rakhmatullin a138fb05d4 Replace to_native_str calls with to_unicode. 2019-11-14 13:45:39 +05:00
Andrey Rakhmatullin 92ffd2f249 Simplify some more imports. 2019-11-14 13:45:39 +05:00
Andrey Rakhmatullin 85e79ae792 Remove cStringIO imports. 2019-11-14 13:45:39 +05:00
Andrey Rakhmatullin 1d7c8cb0b1 Remove six.PY2 and six.PY3 conditionals. 2019-11-14 13:45:37 +05:00
Adrián Chaves 33ef24c757 Add missing whitespace after ‘,’, ‘;’ or ‘:’ 2019-11-13 10:52:05 +01:00
Andrey Rahmatullin c911e80209
Merge pull request #4088 from ammarnajjar/4086-constructor-initializer-docs
docs: use __init__ method instead of constructor
2019-11-12 21:48:16 +05:00
Andrey Rahmatullin c91390558d
Merge pull request #4074 from purvaudai/master
Added Pathlib.Path support: Issue #3731
2019-11-12 21:43:28 +05:00
purvaudai 4b8b0345e5 Mades Changes as per review 2019-11-12 18:17:15 +05:30
Andrey Rahmatullin 93385e647a
Merge pull request #4123 from elacuesta/utils-local-cache-limit
Fix LocalCache limit issue, add tests
2019-11-12 16:05:22 +05:00
purvaudai 50eaabe1fc Added Test 2019-11-11 20:00:26 +05:30
purvaudai f39ff49458 Added Test 2019-11-11 18:54:21 +05:30
purvaudai 970c3be160 Added Test 2019-11-11 18:34:15 +05:30
purvaudai 9e6e2dde2b Adding test 2019-11-11 16:10:37 +05:30
purvaudai 0042c389eb Adding test 2019-11-11 15:57:58 +05:30
purvaudai 084a1cda6d Adding test 2019-11-11 15:41:00 +05:30
Eugenio Lacuesta 07fa768d33
Merge branch 'remove-six-code' of github.com:scrapy/scrapy into remove-six-code 2019-11-08 22:17:12 -03:00
Eugenio Lacuesta b6bbb28197
PEP8 adjustments 2019-11-08 22:13:03 -03:00
Eugenio Lacuesta 342e3b5bd5
Merge remote-tracking branch 'upstream/master' into remove-six-code 2019-11-08 12:29:15 -03:00
Adrián Chaves 1df5755699 Set the bases for testing code examples from the documentation 2019-11-08 16:00:10 +01:00
elacuesta 44f19df311
[test] Update mitmproxy version
Co-Authored-By: Adrián Chaves <adrian@chaves.io>
2019-11-08 11:32:50 -03:00
Marc Hernández c377c14e32 Fix W391 Blank line at end of file (#4137) 2019-11-07 17:47:35 +01:00
elacuesta fe31695ba0
Remove unused import (urllib.parse.unquote)
Co-Authored-By: Adrián Chaves <adrian@chaves.io>
2019-11-05 15:36:19 -03:00
Eugenio Lacuesta 613c66a034
Do not override built-in max function 2019-11-05 09:45:51 -03:00
elacuesta fed9fbe62d
Update tests/test_utils_datatypes.py
Co-Authored-By: Adrián Chaves <adrian@chaves.io>
2019-11-04 15:34:27 -03:00
Eugenio Lacuesta 439a3e59b8
Fix scrapy.utils.datatypes.LocalCache limit issue 2019-11-04 10:35:58 -03:00
Eugenio Lacuesta 00b793dc59
Remove elluding six occurrences 2019-11-03 12:26:38 -03:00
Eugenio Lacuesta 5797aefd4c
Remove six.assertCountEqual 2019-11-03 12:18:35 -03:00
Eugenio Lacuesta 586b25d27e
Remove six types 2019-11-03 12:10:37 -03:00
Eugenio Lacuesta 7f3cb05d8e
Remove metaclass-related six code 2019-11-03 12:03:02 -03:00
Eugenio Lacuesta cca1959c07
Merge remote-tracking branch 'upstream/remove-py2-tests' into remove-six-code 2019-11-03 01:20:08 -03:00
Eugenio Lacuesta d72444b9c8
Remove more six imports 2019-11-03 01:11:28 -03:00
Eugenio Lacuesta eaeaa40b99
Remove six.PY* checks 2019-11-03 01:08:08 -03:00
Eugenio Lacuesta 5d8abdde59
Remove six.text_type from tests 2019-11-03 01:01:23 -03:00
Eugenio Lacuesta 54a786b102
Remove six imports 2019-11-03 00:58:47 -03:00
Eugenio Lacuesta 1aba513693
Remove six.iter* occurrences 2019-11-03 00:26:44 -03:00
Eugenio Lacuesta 5ab0f189ce
Remove six.moves occurrences from tests 2019-11-03 00:01:09 -03:00
Eugenio Lacuesta c0bfaef37a
Remove __future__ imports from tests 2019-11-02 23:27:04 -03:00
Andrey Rakhmatullin 350aa67c3d Rename tests/py3-ignores.txt to tests/ignores.txt. 2019-11-01 19:52:57 +05:00
Andrey Rakhmatullin 4b0cdf7f3e Use self.proc.communicate() after killing mitmdump. 2019-11-01 19:51:52 +05:00
Andrey Rakhmatullin 3c9963ab04 Only xfail test_https_connect_tunnel_error on 3.6+. 2019-11-01 19:47:12 +05:00
Andrey Rakhmatullin e0c5c72496 Improve the test_https_tunnel_without_leak_proxy_authorization_header change. 2019-11-01 19:46:19 +05:00
Andrey Rakhmatullin 5eb01b617d Use an older mitmproxy for py3.5. 2019-10-31 23:21:30 +05:00
Andrey Rakhmatullin a5eb59b92d Fix test_proxy_connect.py for py3.5. 2019-10-31 23:21:14 +05:00
Adrián Chaves f02c3d1dcf
Use communicate() instead of wait() after killing the mock server (#4095) 2019-10-31 13:31:33 +01:00
Andrey Rakhmatullin 7299e91b1f Remove Py2-only code that checks sys.version_info. 2019-10-31 15:22:53 +05:00
Andrey Rakhmatullin 397e883556 Replace to_native_str calls with to_unicode. 2019-10-31 15:22:53 +05:00
Andrey Rakhmatullin 75b1d051d9 Simplify some more imports. 2019-10-31 15:22:45 +05:00
Andrey Rakhmatullin 3ac4b430ae Remove an unused six import. 2019-10-31 15:20:28 +05:00
Andrey Rakhmatullin cea2f5e244 Remove cStringIO imports. 2019-10-31 15:07:54 +05:00
Andrey Rakhmatullin bbd9f4be90 Remove six.PY2 and six.PY3 conditionals. 2019-10-31 15:07:10 +05:00
Andrey Rakhmatullin 186f9d88ac Fix the skip message for test_download_gzip_response. 2019-10-31 15:03:44 +05:00
Andrey Rakhmatullin 439e37fc7b Mark failing proxy tests. 2019-10-31 15:03:44 +05:00
Andrey Rakhmatullin b0d6f4917d Restore tests/test_proxy_connect.py and update it to modern mitmproxy. 2019-10-31 15:03:44 +05:00
Andrey Rakhmatullin b44bd6f825 Remove Python 2-only tests. 2019-10-31 15:03:09 +05:00
Adrián Chaves 15c55d0c1d
Remove LevelDB support (#4112) 2019-10-31 10:47:29 +01:00
Andrey Rahmatullin 229e722a03 Initial Python 2 removal (#4091) 2019-10-31 10:46:02 +01:00
Benjamin Ooghe-Tabanou 6d6da78eda Add a keep_fragments parameter to the request_fingerprint function (#4104) 2019-10-30 09:13:36 +01:00
Amardeep Bhowmick 66cbceeb0a Fix redirection error when the Location header value starts with 3 slashes (#4042) 2019-10-30 09:09:12 +01:00
Andrey Rahmatullin 18b808b2e9
Merge pull request #4092 from further-reading/master
Add Python 3.8 official support
2019-10-29 16:30:58 +05:00
Roy 93e3dc1b82 [test_downloadermiddleware_httpcache.py] Cleaning text
https://github.com/scrapy/scrapy/issues/4085
2019-10-28 16:12:03 +00:00
Roy b73d217de5 [test_downloadermiddleware_httpcache.py] Fixing pytest mark behaviour
https://github.com/scrapy/scrapy/issues/4085
2019-10-28 12:55:54 +00:00
Roy c51fb959e2 [test_downloadermiddleware_httpcache] Fixing pytest skip behaviour
https://github.com/scrapy/scrapy/issues/4085
2019-10-28 12:36:54 +00:00
Roy 4432136fff [test_downloadermiddleware_httpcache] Fixing pytest skip behaviour
https://github.com/scrapy/scrapy/issues/4085
2019-10-28 12:22:21 +00:00
Roy 16bb3ac20d [test_downloadermiddleware_httpcache] Using skipif approach
https://github.com/scrapy/scrapy/issues/4085
2019-10-28 11:24:09 +00:00
elacuesta 7731814cc2 ItemLoader: improve handling of initial item (#4036) 2019-10-28 10:53:53 +01:00
Roy 20ea912513 [test_downloadermiddleware_httpcache] Making xfails more informative
https://github.com/scrapy/scrapy/issues/4085
2019-10-27 18:52:01 +00:00
Roy 70b2854590 [test_downloadermiddleware_httpcache] Making xfails more informative
https://github.com/scrapy/scrapy/issues/4085
2019-10-27 18:51:26 +00:00
Roy b3df0a8415 [test_downloadermiddleware_httpcache] Adding xfails to impacted tests following hack fix
https://github.com/scrapy/scrapy/issues/4085
2019-10-27 18:28:47 +00:00
Roy 11942c436c [test_downloadermiddleware_httpcache] Trying hack to handle systemerror whjen importing leveldb
https://github.com/scrapy/scrapy/issues/4085
2019-10-27 18:02:13 +00:00
Roy deacd34c8d [test_downloadermiddleware_httpcache] Attempting to add xfail for leveldb related tests
https://github.com/scrapy/scrapy/issues/4085
2019-10-27 17:39:47 +00:00
Roy Healy 4068797558
Update test_downloadermiddleware_httpcache.py
Adding xfail denoting that leveldb is not supported in 3.8
2019-10-27 17:02:17 +00:00
Victor Torres f701f5b0db fix #2552 by improving request schema check on its initialization 2019-10-22 10:48:02 -03:00
Ammar Najjar 7a84a4bdba
docs: use "constructor" for from_settings() & rom_crawler() factory methods
Issue #4086
2019-10-22 15:31:34 +02:00
Adrián Chaves 1d5c270ce8
Fix dangling file descriptor in FeedExporter when FEED_STORE_EMPTY is False (#4023) 2019-10-22 15:12:52 +02:00
purvaudai 4184bac068 Added Pathlib.Path test 2019-10-22 16:57:14 +05:30
purvaudai 85f56a92f0 Added Pathlib.Path test 2019-10-22 16:43:17 +05:30
purvaudai 7031e3a124 Added Pathlib.Path test 2019-10-22 16:31:14 +05:30
purvaudai cd4c211f4b Added Pathlib.Path test 2019-10-22 15:38:06 +05:30
purvaudai a776554282 Added Pathlib.Path test 2019-10-22 15:31:55 +05:30
purvaudai ad96d6ef59 Added Pathlib.Path test correctly 2019-10-22 14:53:59 +05:30
purvaudai 2ee38e8ddb Added Pathlib.Path test 2019-10-22 14:43:47 +05:30
Ammar Najjar da8cd9448d
docs: always surround __init__ with `` in docs
Issue #4086
2019-10-21 19:56:58 +02:00
Ammar Najjar 68a7d05ed8
docs: use __init__ method instead of constructor
Issue #4086
2019-10-21 15:42:24 +02:00
Eugenio Lacuesta e1fa1fd8ad
TextResponse.follow_all: skip invalid links 2019-10-10 00:37:30 -03:00
Eugenio Lacuesta 5f168cd459
Response.follow_all 2019-10-08 16:32:56 -03:00
Eugenio Lacuesta e0fabab5cc
Fix TypeError when using DummyStatsCollector 2019-10-01 18:03:22 -03:00
Eugenio Lacuesta 07a31b13db
Update LogFormatter tests 2019-10-01 17:55:57 -03:00
Adrián Chaves 7f4f98fd38 Provide complete API documentation coverage of scrapy.linkextractors 2019-09-30 18:22:28 +02:00
s-sanjay 2c14692e60 remove .keys() to avoid creating a tmp list/keyview obj (#4031)
Also add --verbose and --nolinks for code coverage
2019-09-27 09:56:43 +02:00
Mikhail Korobov 31c631f9ee
Merge pull request #3999 from Gallaecio/documentation-coverage
Provide complete API documentation coverage of scrapy.item
2019-09-25 16:13:13 +01:00
Adrián Chaves 1236e9e81e Provide complete API documentation coverage of scrapy.item 2019-09-25 13:24:56 +02:00
Mikhail Korobov 1364e92007
Merge pull request #4015 from elacuesta/remove_deprecated_xlib
Remove deprecated xlib module
2019-09-20 15:28:07 +01:00
Mikhail Korobov 17c0d72d04
Merge pull request #4016 from elacuesta/rule_default_link_extractor
Crawling rules: make link extractors optional
2019-09-20 15:27:17 +01:00
Eugenio Lacuesta 27436cbbc9
[test] LogFormatter.error 2019-09-16 12:12:10 -03:00
watsta 0b52fa6ca9 LogFormatter: Add the ability to skip log messages (#3987) 2019-09-16 14:12:04 +02:00
OmarFarrag 13735bcf34 Disallow media extensions unregistered with IANA (#3954)
Co-Authored-By: s-sanjay <sanjay537@gmail.com>
2019-09-16 14:04:06 +02:00
Eugenio Lacuesta 21ad8e20b9
Crawling rules: make link extractors optional 2019-09-13 17:32:42 -03:00
Eugenio Lacuesta c5612f387b
Remove deprecated xlib module 2019-09-13 14:32:05 -03:00
Mikhail Korobov 534de7395d
Merge pull request #3988 from elacuesta/contracts_cb_kwargs
CallbackKeywordArgumentsContract
2019-09-08 04:23:16 +05:00
OmarFarrag 0e8770a2f4 test for files pipeline ftp store 2019-09-06 15:47:57 +02:00
Eugenio Lacuesta b92b114633
[test] cb_kwargs contract 2019-08-31 02:44:09 -03:00
Marc Hernández ace2df3d14 Fix JSONRequest naming (#3982) 2019-08-30 11:03:44 +02:00
Júlio César Batista b84f99ff5d Merge 2019-08-29 11:11:56 -03:00
Júlio César Batista 110bc92e6b Fix default value of FEED_STORAGE_GCS_ACL 2019-08-29 11:10:00 -03:00
Mikhail Korobov ede91478e5
Merge pull request #3966 from anubhavp28/robotstxt_useragent
Adds ROBOTSTXT_USER_AGENT setting
2019-08-28 22:00:17 +05:00
Anubhav Patel 3a7b949d6d Adds integration with Protego robots.txt parser (#3935) 2019-08-27 09:41:31 +02:00
Anubhav Patel 00fe05e536 adds ROBOTSTXT_USER_AGENT setting 2019-08-19 09:24:16 +05:30
Andrey Rakhmatullin aaa5229e5d Fixes and improvements for DOWNLOADER_CLIENT_TLS_CIPHERS. 2019-08-13 16:56:26 +05:00
Andrey Rakhmatullin 9a8edf2bf1 Tests for setting SSL ciphers. 2019-08-13 16:53:19 +05:00
Mikhail Korobov 73d1b4b748
Merge pull request #3939 from Gallaecio/improve-scrapes-contract
Report all missing fields when a scrapes contract fails
2019-08-08 13:49:09 +05:00
Mikhail Korobov b4556d6508
Merge pull request #3941 from starrify/ftp-storage-uri-unquote
[MRG+1] Added: Properly handling quoted passwords in FEED_URI for FTP
2019-08-08 13:38:17 +05:00
Adrián Chaves 9119798a5c Add test coverage for contract failures involving multiple missing fields 2019-08-08 09:52:03 +02:00
Marc Hernández d76b6944c9 Create Request from curl command (#3862) 2019-08-08 09:43:42 +02:00
elacuesta 5dbeece8da [MRG+1] Drop py34 support - Update CI envs (#3892)
* Drop py34 support

* Travis experiments

* More Travis experiments

* Bump Twisted version for py35+ (stretch)

* Remove Debian build

* Remove pinned lxml for Py34

* Fix merge error

* Remove unused tox env

* Add environment with pinned versions for py36

* Bump minimum Twisted version in py27; Envs with pinned versions for py27 and py35

* Add botocore as extra dep for py27 tests

* Update requirements-py2.txt

* Add botocore and Pillow as extra dependencies
2019-08-07 12:36:52 +05:00
Pengyu Chen 7b755a41a1
Added: Properly handling quoted passwords in FEED_URI for FTP 2019-08-06 15:19:57 +01:00
Anubhav Patel 8e813953bd [MRG+1] [GSoC 2019] Interface for robots.txt parsers (#3796)
Make the robots.txt parser configurable through the new ROBOTSTXT_PARSER setting, support the Reppy and Robotexclusionrulesparser parsers, and allow implementing custom robots.txt parsers.
2019-08-02 09:43:29 +02:00
Renne Rocha a25e09ecdd Added constrain on lxml version based on Python version 2019-07-30 23:24:41 -03:00
Mikhail Korobov 9c514b976f
Merge pull request #3450 from wRAR/tls-logging
Log cipher, certificate and temp key info on establishing an SSL connection
2019-07-24 01:45:40 +05:00
Eugenio Lacuesta 7e3a602d56
Suggested changes 2019-07-15 12:37:09 -03:00
Eugenio Lacuesta d5a2a70329
Fix import 2019-07-13 23:47:41 -03:00
Eugenio Lacuesta ef9a619214
More DeprecationWarnings 2019-07-13 23:36:39 -03:00
Eugenio Lacuesta eced544d64
Prevent even more DeprecationWarnings 2019-07-13 22:16:23 -03:00
Eugenio Lacuesta 40086dabb8 Prevent more DeprecationWarnings 2019-07-13 22:14:00 -03:00
Eugenio Lacuesta 92d624c161
[Tests] Prevent more TestCase DeprecationWarnings
* assertRegexpMatches -> assertRegex
2019-07-13 20:55:45 -03:00
Eugenio Lacuesta b714a372e2
[Tests] Prevent more DeprecationWarnings
* assertRegexpMatches -> assertRegex
* invalid escape sequence \[
2019-07-13 20:23:15 -03:00
Eugenio Lacuesta 09e27d2d2e
[Tests] Monkey patch unittest.TestCase to prevent DeprecationWarning(s) 2019-07-13 19:26:59 -03:00
Andrey Rakhmatullin a96a07bc76 Add a test for DOWNLOADER_CLIENT_TLS_VERBOSE_LOGGING. 2019-07-12 18:44:45 +05:00
Luiz Francisco Rodrigues da Silva df68c4b9b1 Add a setting to use active mode in FTPFeedStorage (#3829)
Add a setting to use active mode in FTPFeedStorage

FTP servers can be configured in active and passive mode, by default
Python and Scrapy use passive mode and there was no way to use active.

This commit adds a setting FEED_STORAGE_FTP_ACTIVE to allow a feed
to be exported to a FTP server configured in active mode.
2019-07-10 14:25:52 +02:00
nyov 5442c2d3c3 Updating S3FeedStorage instancing without AWS key. 2019-07-06 13:41:56 +00:00
nyov 7a398b7086 Deprecation removals for Scrapy 1.7
Removing deprecations of 2015 and prior (pre-1.1)
2019-07-06 13:41:56 +00:00
Daniel Graña 3d8f075b0a
Merge pull request #3840 from mabelvj/itemloader-errors
[MRG+1] Itemloader errors #3836
2019-07-05 08:55:43 -03:00
Mikhail Korobov 9aec7856b0
Merge pull request #3794 from csalazar/whitelist-form-methods-in-fromresponse
[MRG+1] Fix form methods in FormRequest.from_response (#3777)
2019-07-02 20:08:14 +05:00
Eugenio Lacuesta 312e57382c Request.cb_kwargs: update in spider middleware 2019-06-26 12:48:00 -03:00
Eugenio Lacuesta d4d68cf321 Request.cb_kwargs: update in downloader middleware 2019-06-26 12:31:41 -03:00
Eugenio Lacuesta 1f9f41b850 Move request.cb_kwargs tests to their own test file 2019-06-26 12:31:12 -03:00
Eugenio Lacuesta 428309ba1a Merge remote-tracking branch 'origin/master' into callback_kwargs 2019-06-26 11:03:31 -03:00
Mikhail Korobov c81d120bde
Merge pull request #3768 from Gallaecio/meta-ignore-tags
Implement the METAREFRESH_IGNORE_TAGS setting
2019-06-25 23:25:58 +03:00
Mabel Villalba b1e348b281 [itemloader-errors] updated Compose and MapCompose messages and added tests
#3836
2019-06-25 17:11:14 +02:00
Mabel Villalba a753ea7e16 [itemloader-errors] added test for Compose and MapCompose
#3836
2019-06-25 14:35:49 +02:00
Mabel Villalba 99eb03a810 [itemloader-errors] adapted compose test for the new error being returned by compose
#3836
2019-06-25 14:24:27 +02:00
Victor Torres f4f2b1695c Fix a memory leak on the Media Pipeline (Files and Images) (#3813)
We're storing exceptions captured by Twisted on the media pipeline
cache, but we're also using the defer.returnValue method with our
own methods decorated with @defer.inlineCallbacks.

The defer.returnValue method passes returned values forward by
throwing a defer._DefGen_Return exception, which in its turn
extends the BaseException class and is captured by Twisted.

This way, the latest exception stored in the Failure's object may
also have an HtmlResponse object in its __context__ attribute. As
the Response object also keeps track of the Request object that
has originated it, you could figure it out how many RAM we're
wasting here.

This could easily lead to a Memory Leak problem when running
spiders with Media Pipeline enabled and a particular Request set
that tends to raise a significant number of exceptions.

Example triggers:
- media requests with 404 status responses
- user land exceptins coming from custom middlewares
- etc.
2019-06-24 12:38:05 +02:00
Daniel Graña b53ff59a22
Merge pull request #3790 from andrewbaxter/master
[MRG+1] Account for mangling when serializing requests with private callbacks
2019-06-17 12:33:21 -03:00
Daniel Graña 31cdb940ff
Merge pull request #3833 from anubhavp28/remove_unused_var
removes unused var
2019-06-17 11:50:49 -03:00
Anubhav Patel b8900ec6a6 removes unused var 2019-06-17 00:06:44 +05:30
Daniel Graña cdfb20aee8
Merge pull request #3739 from Matthijsy/feature/scrapy_check_env
[MRG+1] Add SCRAPY_CHECK environment variable
2019-06-13 19:43:01 -03:00
sortafreel cdeccac6d6 Linting (return previous indentation). 2019-06-11 17:38:06 +03:00
sortafreel 7dad2f7b13 Add more tests. 2019-06-11 07:43:03 +03:00
sortafreel a1bca6a8e7 Add tests. 2019-06-11 07:36:29 +03:00
Claudio Salazar 0c50879568 Change behavior to use method GET when there are unknown methods
in the form
2019-06-06 22:10:59 +02:00
Andrew Baxter 6af1dc89aa Fix mangling test 2019-06-06 04:25:19 +09:00
Andrew Baxter 3dd3e8c298 Restrict different class mangling tests to Py 3+ 2019-06-05 23:49:54 +09:00
Andrew Baxter 9c81721c40 Add tests for private method name mangling 2019-06-05 23:43:56 +09:00
Andrew Baxter bcad8947e8 Support inherited private method names 2019-06-03 20:41:02 +09:00
Andrew Baxter 9af91a26b0 Replace regex usage 2019-05-28 01:40:26 +09:00
Andrew Baxter 72b7d3e90a Make the regex align to the spec better; add unit tests for name variations 2019-05-27 23:30:23 +09:00
Claudio Salazar 461682fc3d Whitelist form methods in FormRequest.from_response method 2019-05-25 11:01:19 +02:00
Andrew Baxter e667ca7682 Account for mangling when serializing requests with private callbacks 2019-05-24 21:45:53 +09:00
Anubhav Patel 2994b624e0 makes suggested changes 2019-05-17 12:14:43 +00:00
Anubhav Patel 653ac3eebe makes suggested changes 2019-05-16 06:20:39 +00:00
Adrián Chaves 611249bb7f Implement the METAREFRESH_IGNORE_TAGS setting 2019-05-08 12:52:29 +02:00
Anubhav Patel 881bade2c1 tests for new API 2019-05-07 16:12:26 +05:30
Anubhav Patel 33925a7761 test for deprecation warning 2019-05-07 15:44:21 +05:30
Matthijs Vos f6485e6697 Restore alphabetic order and two lines between import and code 2019-05-03 13:55:18 +02:00
Anubhav Patel 2a6bcdb413 makes fix backward compatible 2019-04-29 21:21:02 +05:30
Matthijs Vos 6d52708579 Add reset case 2019-04-18 15:19:23 +02:00
Matthijs Vos 2973998947 Add set_environ test 2019-04-18 14:50:02 +02:00
Mikhail Korobov 5b667b6156
Merge pull request #3707 from Gallaecio/pytest-xdist
Use pytest-xdist
2019-04-17 13:20:37 +05:00
Adrián Chaves 5a6fb3daa6 Use pytest-xdist 2019-04-17 09:02:34 +02:00
Anubhav Patel 6039b66f42 aesthetic changes 2019-04-13 10:17:26 +05:30
Anubhav Patel c6769d6887 make suggested changes 2019-04-13 10:10:08 +05:30
Anubhav Patel 398639a0bf fix test 2019-04-08 12:27:36 +05:30
Mikhail Korobov 9280185054
Merge pull request #3520 from whalebot-helmsman/round-robin-scheduler-tested
[MRG+1] Downloader-aware Priority Queue for Scrapy
2019-04-07 00:06:08 +05:00
Maram Sumanth aa46e1995c [MRG+1] Show elapsed time in statscollector (#3638)
* Update corestats.py

* Update corestats.py

* corrected tests

* Update corestats.py

* Update scrapy/extensions/corestats.py
2019-04-07 00:03:40 +05:00
Kostis Anagnostopoulos 3a493b6066 fix: do not catch system exceptions like KeyboardInterrupt 2019-04-05 11:52:00 +02:00
Konstantin Lopuhin b5c552d17f
Merge pull request #2061 from elacuesta/process_spider_exception_generator
[MRG+1] process_spider_exception on generators
2019-04-01 10:43:19 +03:00
Eugenio Lacuesta f5e0b6b89a parse command: rename cb_kwargs option to cbkwargs 2019-03-29 14:03:26 -03:00
Adrián Chaves 484bd0d22a Allow customizing export column names 2019-03-29 15:16:54 +01:00
Eugenio Lacuesta e8af6331b5 Add cb_kwargs option to the parse command 2019-03-28 15:03:40 -03:00
Eugenio Lacuesta 70a4d93aa3 Callback kwargs: more tests 2019-03-28 13:28:19 -03:00
Mikhail Korobov ec719f55e7
Merge pull request #3682 from elacuesta/rule_process_request_response_parameter
[MRG+1] Rule.process_request: access Response object
2019-03-28 01:39:54 +05:00
Eugenio Lacuesta c43a23152b Merge remote-tracking branch 'upstream/master' into callback_kwargs 2019-03-27 14:42:41 -03:00
Anubhav Patel ca882d8d9f include test 2019-03-27 19:10:44 +05:30
Maram Sumanth 2fd8b7c28c [MRG+1] redirect_reasons in Request.meta (#3687) 2019-03-27 00:15:53 +05:00
Maram Sumanth 5f2ad5377e
fixed typo 2019-03-26 16:46:15 +05:30
Maram Sumanth ae856e8ba8
corrected tests 2019-03-26 16:21:52 +05:30
Maram Sumanth 213b9eb879
Update test_http_request.py 2019-03-26 15:59:38 +05:30
Maram Sumanth dc8310e292
changed tests 2019-03-26 15:42:58 +05:30
Adrián Chaves ba13de29e1
Merge branch 'master' into feat-685 2019-03-26 10:38:38 +01:00
Vostretsov Nikita 73e4ff5304 report warnings 2019-03-25 13:48:58 +00:00
Vostretsov Nikita 103fdc40c1 Merge remote-tracking branch 'upstream/master' into round-robin-scheduler-tested 2019-03-25 16:16:42 +03:00
Vostretsov Nikita 31b8a6b33a report warnings 2019-03-25 16:08:40 +03:00
Lucy Wang df574de8cc improve tests and fix some lint warnings (#6)
* refactor downloader-aware test cases

* fix lint

* add doctest for _path_safe

* remove unused code

* better doctest
2019-03-25 16:08:40 +03:00
Vostretsov Nikita 8afffb7234 Tests Cleanup
add doctest for function
no need in this variables
move common assertion inside function
rename variable
rename variables
rename function
use function
this is not a method of public API
correct name for test
Update docs/topics/settings.rst

Co-Authored-By: whalebot-helmsman <whalebot.helmsman@gmail.com>
2019-03-25 16:08:40 +03:00
Vostretsov Nikita 989bba6cb3 Revert "new signal"
This reverts commit 646164fd7d6dd52061804d2df7424cff929bf739.
remove tests
Revert "emit new signal"

This reverts commit fcde0c6880678957a76af6083b6248f430a00fcf.
Revert "documentation for new signal"

This reverts commit 8aeb9f696ece95c16499a96767a7afa3d9c4abf4.
2019-03-25 16:08:40 +03:00
Vostretsov Nikita 443fb98a47 Use downloader directly
rename variable
remove old write function
remove unused imports
remove old read function
remove unused function
use mock methods
mock downloader
close downloader
add parse method
use new PQ class
create mock downloader
use downloader directly
remove mark/unmark mechanism
2019-03-25 16:08:40 +03:00
Vostretsov Nikita 3b1db71dac New signal
update signature
documentation for new signal
utilize new signal
correct signal handler signature
emit new signal
test another signal
new signal
rename test file
faster test
rename test case
tests for signal emitting in bad cases
2019-03-25 16:08:40 +03:00
Vostretsov Nikita 757f53a324 Address Lucy's comments
add tests to check correctness of slot setermination
unmark requests after downloading
shorter
better exception message
2019-03-25 16:08:40 +03:00
Mikhail Korobov 90934959d0 actually apply __slots__ suggestion
[wip] refactoring

* SlotPriorityQueues doesn't care about objects inside, it is now just
  a container for multiple priority queues
* assorted variable renames
* don't inherit DownloaderAwarePriorityQueue from SlotBasedPriorityQueue
* apply @whalebot-helmsman's suggestions for __slots__ and meta issues
more bike-shedding

* remove mutable default arguments
* more verbose variable names
remove unneeded code

* PriorityAsTupleQueue.is_empty does the same as len(self) == 0
* custom PriorityAsTupleQueue.close is not needed after a switch
  to namedtuples
* is_new and is_empty return values are unused
* "url" local variable is unused
PrioritySlot.__str__ shouldn't return unicode in Python 2

also, do some bike-shedding: _pathable -> _path_safe
use namedtuple for PrioritySlot
cleanup: _get_from_request does the same here

Request.meta is always a dict
2019-03-25 16:08:40 +03:00
Eugenio Lacuesta 1b4385b7e3 Rule.process_request: move deprecation warnings and compiling code, update tests 2019-03-22 19:46:17 -03:00
Mikhail Korobov 729580dae2
Merge pull request #3671 from Gallaecio/item-deepcopy
Implement Item.deepcopy()
2019-03-22 22:56:39 +05:00
Adrián Chaves 7c148fce5a Implement Item.deepcopy() 2019-03-22 17:07:10 +01:00
Konstantin Lopuhin af2b666595
Merge pull request #3505 from kasun/json_request
[MRG+2] Request subclass for json requests #3504
2019-03-22 18:25:54 +03:00
Vostretsov Nikita 987c2ae4a9 test ip concurrency incompatibility with DAPQ 2019-03-22 15:40:37 +03:00
Vostretsov Nikita 4163a7a1c7 no need for this 2019-03-22 15:40:37 +03:00
Vostretsov Nikita d970be64cc Integration test
integration testing only everything is working, not logic of PQ
use method
create slot attribute in constructor
corect class for test case
stop crawler in teardown method
use class
correct entity naming
python 2 adaptation
integration test with crawler and spider
2019-03-22 15:40:36 +03:00
Vostretsov Nikita a23e1894b3 Fix boto problem
another way to fix boto problem
Revert "fix for travis ci based on https://github.com/boto/boto/issues/3717"

This reverts commit 150d2564ff0ea994652da7f5be333d72e0b38d93.
fix for travis ci based on https://github.com/boto/boto/issues/3717
2019-03-22 15:40:36 +03:00
Vostretsov Nikita f56079f6c7 Test cleanups
PEP8 fixes
no need to close implicitly
do not use pytest
need to put it into class
remove round-robin queue
additional check for empty queue
use pytest tmpdir fixture
2019-03-22 15:40:36 +03:00
Vostretsov Nikita 821f5bb260 First implementation
handle exception
use O(N) instead of O(NlogN)
here we have request as struct
additional check for meptiness
small performance improvement
do not consume another request
test number of responses
mark requests
back to 3 slots test case
raise exceptions in case of missed meta
add marks to requests and work only with your own requests
only disk queue should obtain signals
separate functions for slot rasd/write
use signlas without variable
stop crawler
get signals in correct place
logic test for download-aware priority queue
update comment for structure
ensure text type
transform slot name to path
use implicit structure
use unicode type implicitly
use real crawler
add signals
more slot accounting
simple implementation of pop
small slot accounting code
no need for custom len function
ability to call super in py27
add slots
generic tests for downloader aware queue
dummy implementation of crawler aware priority queue
move common logic to base class
rename class
pass crawler to pqclass constructor
do not copy quelib.PriorityQueue code
add comment about new class
remove obsolete function
modify behaviour of queuelib.PriorityQueue to dodge very complex priority
better way to get name
remove obsolete commentary
check boundaries
function for priority convertion with known limits
correct import path
move file
do not switch on by deffault as ip concurrency not supported
set scheduler slot in case of empty slot
use constant
single place for added urls
single place for constants
use as default queue
correct format for error text
test migration from old version with on disk queue
in these tests we have only two inflection points - jobdir and priority_queue_cls
we do not need separate mock spider, use usual one
do not rely on order of dict elements, imply order of list
test round robiness of priority queue
add comments and requirements for our magick function
remove debug logging
put queues into slot
as we fabricate priorities we do not need special types anymore
fabricate priority for priority queue
more versatile priorities
Scheduler class is not inflection point
wrap correct types
check for emptinees before initialization
tests for new priority queue
correct default type for startprios
use exact values
put common settings to base class
test priorities for disk scheduler
test dequeue for disk scheduler
test length for disk scheduler
setUp/tearDown methods for on disk schedulers
new methods
remove excessive line
base class to handle scheduler creation
correct method names
test priorities
deque test
close scheduler on test end
enqueue some requests
test template for scheduler
use downloader slot
I/O implementation for RoundRobin queue
round-robin implementation without I/O and slot detection
wrappers for every disk queue class
2019-03-22 15:40:36 +03:00
Maram Sumanth 4c89e53e68
Update test_http_request.py 2019-03-20 18:46:25 +05:30
Eugenio Lacuesta 6760bca74b Rename Request.kwargs to Request.cb_kwargs 2019-03-15 22:42:29 +00:00
Eugenio Lacuesta 645e8d16a4 Count keyword argument checks 2019-03-15 22:20:36 +00:00
Anubhav Patel 07487dd487 make tests work with new convert_image 2019-03-15 23:29:53 +05:30
Eugenio Lacuesta 01ed605d02 PEP8 changes to test_spider.py 2019-03-15 16:54:14 +00:00
Victor Torres fda1d04b81
Merge branch 'master' into feed-storage-s3-acl 2019-03-15 13:26:45 -03:00
Adrián Chaves 70a0f1f2e4
Merge pull request #3610 from Gallaecio/spidercls-check
[MRG+1] Check that spidercls arguments in scrapy.crawler classes are not spid…
2019-03-15 08:25:16 +01:00
Adrián Chaves 1f7413dc88
Merge pull request #3635 from matthieucham/feature-filteringlinkextractor-restrict-text
[MRG+1] Feature filteringlinkextractor restrict text
2019-03-15 07:58:28 +01:00
Mikhail Korobov 5dc94db847
Merge branch 'master' into backward 2019-03-14 22:21:09 +05:00
Eugenio Lacuesta 22fda61d62 Rule.process_request: tests 2019-03-13 10:54:38 +00:00
Maram Sumanth 8831fafabc
Update test_http_request.py 2019-03-04 15:42:48 +05:30
Maram Sumanth fdf03a6d0d
correcting tests 2019-03-04 15:12:44 +05:30
Maram Sumanth d75b61b96a
Update test_http_request.py 2019-03-04 15:07:12 +05:30
Adrián Chaves 75d6f56c8a Switch from ` to `` where inline code formatting is desired 2019-03-01 16:56:58 +01:00
Adrián Chaves 858f5be747 backwards → backward (adj.) 2019-03-01 16:10:23 +01:00
Matthieu Grandrie e3b15252c8 New constructor arg *restrict_text* for FilteringLinkExtractor.
Same as allow and deny args, it holds a string, a regex or an iterable of. Links whose text don't match one of the regex are filtered out.
DOC restrict_text in LxmlLinkExtractor
2019-02-28 17:21:17 +01:00
Júlio César Batista 0bb3d8ca93 Updating Google Cloud Storage scheme to gs instead of gcs 2019-02-27 18:41:01 -03:00
Victor Torres 9b8ba4c383 try to import botocore before runing some tests 2019-02-14 16:20:56 -02:00