[New-bugs-announce] [issue5554] file.read() doesn't read the whole file

Ultrasick report at bugs.python.org
Tue Mar 24 18:24:57 CET 2009

New submission from Ultrasick <python at ontheserver.de>:

# open the file
file = open('F:/test.bmp', 'r')

# read the content
content = file.read()

# close the file

print "len(content): " + str(len(content))

len(content): 1522

on my computer. But it should be something like

len(content): 1248858

components: Interpreter Core
files: test.bmp
messages: 84098
nosy: Ultrasick
severity: normal
status: open
title: file.read() doesn't read the whole file
type: behavior
versions: Python 2.6
Added file: http://bugs.python.org/file13407/test.bmp

Python tracker <report at bugs.python.org>

More information about the New-bugs-announce mailing list