Add deprecation warning for ChunkedTransfer middleware

This commit is contained in:
Paul Tremberth 2016-11-24 17:33:27 +01:00
parent 03cf5f1bd2
commit e6f174b015
1 changed files with 8 additions and 0 deletions

View File

@ -1,6 +1,14 @@
import warnings
from scrapy.exceptions import ScrapyDeprecationWarning
from scrapy.utils.http import decode_chunked_transfer
warnings.warn("Module `scrapy.downloadermiddlewares.chunked.ChunkedTransferMiddleware` "
"is deprecated, chunked transfers are supported by default.",
ScrapyDeprecationWarning, stacklevel=2)
class ChunkedTransferMiddleware(object):
"""This middleware adds support for chunked transfer encoding, as
documented in: http://en.wikipedia.org/wiki/Chunked_transfer_encoding