Compiled Byte code

Cliff Wells clifford.wells at comcast.net
Thu Oct 14 21:00:53 EDT 2004


On Thu, 2004-10-14 at 14:57 +0000, Michael Hudson wrote: 
> Cliff Wells <clifford.wells at comcast.net> writes:
> 
> > On Wed, 2004-10-13 at 19:19 +0530, Soumitri wrote:
> > > Hi,
> > > 
> > > Is there a dependency of version or platform for running a snippet of
> > > python compiled code? I have a .pyc (possibly created on a *nix box)
> > > that was created off ver 1.5.2 and returns a "Bad Magic Number in .pyc
> > > file" error when i run a box with XP and Python 2.3.
> > 
> > IIRC, I believe bytecode (pyc files), while mostly portable across
> > platforms (I've used the same pyc files on Linux and Windows)
> 
> Uh, *entirely* portable, I hope, or you've found a bug :-).

I qualified my statement as I was unsure about platforms other than the
ones I mentioned.  It occurred to me that 64-bit platforms *might* not
be compatible.  Since I wasn't sure I was reluctant to make a blanket
assertion.  But I can try harder in the future ;-)

Regards,
Cliff

-- 
Cliff Wells <clifford.wells at comcast.net>




More information about the Python-list mailing list