MCPcopy Create free account
hub / github.com/ActiveState/code / get_file

Function get_file

recipes/Python/456375_File_Extractor/recipe-456375.py:59–67  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

57 print
58
59def get_file():
60 while True:
61 try:
62 return file(raw_input('Filename: '), 'rb', 0).read()
63 except Exception, error:
64 if error.__class__ is EOFError:
65 raise EOFError
66 else:
67 print 'ERROR: Filename Is Invalid'
68
69def work_menu():
70 print '(1) Extract *.BMP'

Callers 1

workspaceFunction · 0.70

Calls 1

readMethod · 0.45

Tested by

no test coverage detected