Skip to content

Commit 0336c25

Browse files
committed
Use context factory class name in warning message
1 parent c29a1b9 commit 0336c25

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

scrapy/core/downloader/handlers/http11.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -43,9 +43,10 @@ def __init__(self, settings):
4343
# use context factory defaults
4444
self._contextFactory = self._contextFactoryClass()
4545
msg = """
46-
You are using a context factory class that does not accept the `method` argument
47-
(type OpenSSL.SSL method, e.g. OpenSSL.SSL.SSLv23_METHOD).
48-
Please upgrade your context factory class to handle or ignore it."""
46+
'%s' does not accept `method` argument (type OpenSSL.SSL method,\
47+
e.g. OpenSSL.SSL.SSLv23_METHOD).\
48+
Please upgrade your context factory class to handle it or ignore it.""" % (
49+
settings['DOWNLOADER_CLIENTCONTEXTFACTORY'],)
4950
warnings.warn(msg)
5051
self._default_maxsize = settings.getint('DOWNLOAD_MAXSIZE')
5152
self._default_warnsize = settings.getint('DOWNLOAD_WARNSIZE')

0 commit comments

Comments
 (0)