Laerte Pereira
26a16f2c43
Fix tests
2024-02-28 16:36:19 -03:00
Andrey Rakhmatullin
282767f23b
Bump black.
2024-02-28 14:30:38 +05:00
Laerte Pereira
2de95f1fc0
Remove leftover from _make_compatible removal
2023-10-17 19:44:12 -03:00
Adrián Chaves
b07d3f85a3
Upgrade CI tools
2023-02-02 06:37:40 +01:00
Andrey Rakhmatullin
ccd1385e11
Merge branch 'master' into no-callback
2023-01-30 15:43:05 +05:00
Jalil SA
a5c1ef8276
sort imports with isort
2023-01-25 14:25:15 -06:00
Adrián Chaves
9272c4af0c
Merge remote-tracking branch 'scrapy/master' into no-callback
2023-01-25 17:41:41 +01:00
Adrián Chaves
50500a6b28
Implement a NO_CALLBACK value for Request.callback
2023-01-19 17:14:18 +01:00
Emmanuel Rondan
e211ec0aa2
adding black formatter to all the code
2022-11-29 11:30:46 -03:00
Mark Mayo
f9a29f03d9
Address some issues reported by Pylint ( #5677 )
...
Co-authored-by: Felipe Boff Nunes <51033921+felipeboffnunes@users.noreply.github.com>
Co-authored-by: Andrey Rahmatullin <wrar@wrar.name>
2022-11-27 11:00:13 +01:00
Adrián Chaves
c5627af15b
Centralize request fingerprints ( #4524 )
...
Co-authored-by: Mikhail Korobov <kmike84@gmail.com>
2022-06-07 18:44:54 +02:00
Mohammadtaher Abbasi
5c586d78f0
add tests
2022-05-25 23:58:09 +04:30
Adrián Chaves
308a58aa27
Update CI to support Twisted 21.2.0 ( #5027 )
2021-03-19 18:39:44 +01:00
Ajay Mittur
1c4b4cc6b0
Support defining file path based on item in media pipelines ( #4686 )
2020-08-11 14:12:44 +02:00
Marc Hernández
336f19f5cc
Change super syntax ( #4707 )
2020-08-04 20:42:01 +02: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
Eugenio Lacuesta
bf56517abf
Flake8: Remove E128 (tests, part 2)
2020-05-06 19:18:29 -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
Eugenio Lacuesta
4023d5db33
Replace _DefGen_Return exception handling
...
Handle StopIteration instead
2020-04-13 06:35:26 -03:00
Eugenio Lacuesta
2265c1fda9
Merge branch 'master' into fix-pycodestyle-e731
2020-04-10 14:32:30 -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
Marc Hernández
91bbc70bc1
fix E30X flake8 ( #4355 )
2020-02-21 06:05:31 +01:00
Adrián Chaves
b5c4c2cae8
Keep 2 spaces between code and inline comments ( #4195 )
2019-12-13 14:20:48 +01:00
Eugenio Lacuesta
b6bbb28197
PEP8 adjustments
2019-11-08 22:13:03 -03:00
Eugenio Lacuesta
c0bfaef37a
Remove __future__ imports from tests
2019-11-02 23:27:04 -03:00
Andrey Rakhmatullin
cea2f5e244
Remove cStringIO imports.
2019-10-31 15:07:54 +05: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
Paul Tremberth
c68f99eed8
Refactor settings tests
2017-03-03 17:03:25 +01:00
Paul Tremberth
f7e11b198e
Cleanup
2017-03-03 16:00:59 +01:00
Paul Tremberth
ecde166ee1
Refactor without MEDIA_HTTPSTATUS_LIST setting
2017-03-03 15:52:05 +01:00
Bernardas
11b31c9fbd
fix redirect change
2017-03-03 15:52:05 +01:00
Bernardas
3cef1cd451
adjust variable wording and redirect logic
2017-03-03 15:52:05 +01:00
Bernardas
6a42214716
add tests for media pipeline MEDIA_ALLOW_REDIRECTS and MEDIA_HTTPSTATUS_LIST settings
2017-03-03 15:52:05 +01:00
nyov
ec8afbc060
PY3 fix test pipeline media
2015-07-29 13:51:01 +00:00
Julia Medina
6dccb3a9b3
Replace FailureFormatter with direct exc_info conversions in log calls
2015-05-15 05:46:14 -03:00
Julia Medina
d3f576a816
Move scrapy/spider.py to scrapy/spiders/__init__.py
2015-05-09 04:20:09 -03:00
Julia Medina
8021df18d4
Move scrapy/contrib/pipeline to scrapy/pipelines
2015-04-29 21:26:35 -03:00
Julia Medina
c2d716807a
Use LogCapture in testfixtures package for tests
...
This allows to remove `get_testlog` helper, `flushLoggedErrors` from
twisted.trial.unittest.TestCase and Twisted log observers created for
each test on conftest.py.
2015-04-22 17:24:40 -03:00
Daniel Graña
242c08553f
move tests under root dir
2014-07-30 19:45:08 -03:00