def verify_file(real_source_filename, real_bytecode_filename):
tempdir = tempfile.gettempdir()<EOL>source_filename = os.path.join(tempdir, "<STR_LIT>")<EOL>if not os.path.exists(real_source_filename):<EOL><INDENT>return<EOL><DEDENT>try:<EOL><INDENT>f = open(real_source_filename, '<STR_LIT>')<EOL><DEDENT>except:<EOL><INDENT>return<EOL><DEDENT>codestring = f.read()<EOL>f.close()<EOL>codeobject1 = compile(codestring, source_filename,'<STR_LIT>')<EOL>(version, timestamp, magic_int, codeobject2, is_pypy,<EOL>source_size) = load_module(real_bytecode_filename)<EOL>if magic_int == <NUM_LIT>+<NUM_LIT:7>:<EOL><INDENT>magic_int = <NUM_LIT><EOL><DEDENT>assert MAGIC == magics.int2magic(magic_int),("<STR_LIT>" %<EOL>(magic_int, magics.magic2int(MAGIC), os.getcwd(), real_bytecode_filename))<EOL>bytecode_filename1 = os.path.join(tempdir, "<STR_LIT>")<EOL>dump_compile(codeobject1, bytecode_filename1, timestamp, MAGIC)<EOL>(version, timestamp, magic_int, codeobject3, is_pypy,<EOL>source_size) = load_module(real_bytecode_filename, fast_load=not is_pypy)<EOL>bytecode_filename2 = os.path.join(tempdir, "<STR_LIT>")<EOL>dump_compile(codeobject1, bytecode_filename2, timestamp, magics.int2magic(magic_int))<EOL>compare_bytecode_files(bytecode_filename1, bytecode_filename2)<EOL>return<EOL>
Compile *real_source_filename* using
    the running Python interpreter. Then
    write bytecode out to a new place again using
    Python's routines.

    Next load it in using two of our routines.
    Compare that the code objects there are equal.

    Next write out the bytecode (using the same Python
    bytecode writin routine as in step 1.

    Finally compare the bytecode files.