New submission from Robert Cheng <robert.h.ch...@gmail.com>:

When reporthook is None, size variable is not computed and defaulted to -1. 
Thus, without reporthook, ContentTooShortError is not raised even when 
Content-Length header is supplied and download size is less than expected 
amount, contrary to the documentation.

----------
components: Library (Lib)
messages: 125186
nosy: RC
priority: normal
severity: normal
status: open
title: urllib.request.urlretrieve never raises ContentTooShortError if no 
reporthook
type: behavior
versions: Python 2.7

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue10817>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to