A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2002-June/024847.html below:

[Python-Dev] PYC Magic

[Python-Dev] PYC Magic [Python-Dev] PYC MagicNeal Norwitz neal@metaslash.com
Sat, 01 Jun 2002 09:20:04 -0400
I recently posted a patch to fix a bug:  http://python.org/sf/561858.
The patch requires changing .pyc magic.  Since this bug goes back
to 2.1, what is the process for changing .pyc magic in bugfix releases?
ie, is it allowed?

In this case the co_stacksize > 32767 and only a short is written 
to disk.  This could be doubled to 65536 (probably should be) 
without changing the magic.  But even that isn't sufficient 
to solve this problem.

It also brings up a related problem.  If the PyCodeObject 
can't be written to disk, should a .pyc be created at all?  
The code will run fine the first time, but when imported 
the second time it will fail.

The other 16 bit values stored are:  co_argcount, co_nlocals, co_flags.
At least argcount & nlocals aren't too likely to exceed 32k, but
co_flags could, which would be silently ignored now.

Neal




RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4