Skip to content

Instantly share code, notes, and snippets.

@alexggordon
Last active October 14, 2015 00:57
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save alexggordon/cad0d1cc5e876cae513e to your computer and use it in GitHub Desktop.
Save alexggordon/cad0d1cc5e876cae513e to your computer and use it in GitHub Desktop.
Farpest Post
** Text of the post on Sourceforge by Andy Dustman (@farcepest) for redundancy**
** http://sourceforge.net/p/mysql-python/discussion/70460/thread/9ae42ab5/ **
There have been questions about the license for MySQLdb, so here's my official position.
Originally MySQLdb had a license based on the old Python license, i.e. the CNRI license, which is essentially BSD-ish. Later, because MySQL uses a GPL license, GPL v2 was added. However, it's up to you which license to use on MySQLdb-1.2.
Licensing is not an issue for end-users. The GPL only applies to people who distribute the package. If you just download MySQLdb and use it in your own code, you do not have to accept any license. See section 0 of the GPL. http://www.gnu.org/licenses/gpl-2.0.html
"""Activities other than copying, distribution and modification are not covered by this License; they are outside its scope. The act of running the Program is not restricted, and the output from the Program is covered only if its contents constitute a work based on the Program (independent of having been made by running the Program). Whether that is true depends on what the Program does."""
In my opinion, the output does not constitute a work based on the program and therefore is not covered by the GPL; only copying, distribution, and modification. Simply doing "import MySQLdb" does not force you to license your code under GPL; consider this an exemption/position parallel to the one Linus Torvalds makes for the Linux kernel. Some people have claimed that this is linking and thus it would be covered. If they are right, you can fall back to the original BSD-ish license. I like free software and I like the GPL so I hope you will use the GPL in your own projects but you are not required to. (I have not decided about GPL v3 yet.)
If you do use MySQLdb in your public project, make a note of which license you support, i.e.
import MySQLdb # GPL
import MySQLdb # CNRI
Or you can state this in a README or license file. You're not required to do this at all; it's a suggestion.
The above applies to all releases of MySQLdb-1.2.x and earlier.
Licensing for MySQLdb-1.3.x is likely to be different, and it may be GPL v2 only, or it may be something else. Suggestions are welcome.
Code that is in the subversion repository should be considered GPL v2. This is a subtle distinction, but it's there because repositories cover the entire continuum of time and space.
If you're in doubt about licensing for specific situations, not covered above, ask.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment