[Python-Dev] importing .pyc-files generated by Python 1.5.2 in Python 1.6. Why not?

Eric S. Raymond esr@thyrsus.com
Wed, 24 May 2000 18:02:15 -0400


Peter Funk <pf@artcom-gmbh.de>:
> BTW: import.c contains the  following comment:
> /* XXX Perhaps the magic number should be frozen and a version field
>    added to the .pyc file header? */
> 
> Judging from my decade long experience with exotic image and CAD data 
> formats I think this is always the way to go for binary data files.  
> Using this method newer versions of a program can always recognize
> the file format version and convert files generated by older versions
> in an appropriate way.

I have similar experience, notably with hacking graphics file formats.
I concur with this recommendation.
-- 
		<a href="http://www.tuxedo.org/~esr">Eric S. Raymond</a>

The end move in politics is always to pick up a gun.
	-- R. Buckminster Fuller