The Industry choice

Stefan Axelsson crap1234 at
Fri Jan 7 23:02:26 CET 2005

Bulba! wrote:

> Oh, and by the way - since Python bytecode can be relatively
> easily decompiled to source, could it interpreted to "really" 
> count as source code and not binary? What are the consequences 
> of releasing code  _written in Python_  as GPLed?

Well, to your first question, in a word 'no', it wouldn't count as 
source code. To quote the GPL section 3:

"The source code for a work means the preferred form of the work for 
making modifications to it. For an executable work, complete source code 
means all the source code for all modules it contains, plus any 
associated interface definition files, plus the scripts used to control 
compilation and installation of the executable."

As the preferred form for making changes to Python programs would be 
Python source, that's what counts. This is also what forbids obfuscated 
code. If you were to *write* Python bytecode, as a form of assembly, 
then of course that's another matter.

I've released Python source as GPL and as far as I'm concerned it ought 
to work, even though that's not explicitly covered. As the only way 
you're going to receive my program is by receiving the source then 
you'll end up having it and everything's basically OK. If someone tries 
to make a binary from that and distribute that without also making the 
source available then the GPL obviously comes into effect, and the game 
is up. I haven't sought legal (or FSF) input on this matter though, it's 
just my understanding. You can be fairly confident that the GPL is iron 
clad though, it would have been dragged through every court in the land 
by now if it wasn't.

I've also followed the LGPL/GPL library debate, and while I have 
opinions on that as well, this is getting long in the tooth already.

Stefan Axelsson  (email at

More information about the Python-list mailing list