I have a lightly forked MySQLdb1 at https://github.com/tkho/MySQLdb1/commits/libmysqldb that creates a MySQLdb_embedded package and _mysql_embedded.so—versions of MySQLdb that are statically built and linked against the embedded mysql library. These have proved to be a great way to write hermetic tests using the same database stack we run in production; we have it so that subclassing a simple EmbeddedMySQLTestCase and swapping DB URLs is all that’s needed to run against the embedded database.
Now, my question: Does anyone have suggestions on the best way to make this widely available? Ideally the end result is a pypi package that exists side by side (or in) the existing MySQLdb1. Having MySQLdb1 build both _mysql.so and _mysql_embedded.so and support both is one ideal outcome, but I’m not sure there’s a clean way to get there, and it seems like a large change for a mature project. Another alternative is to create a new (published) package as a fork/patchset on top of MySQLdb1. I’d be happy to maintain a fork/sibling package, but would prefer a solution that didn’t require that.
I have a lightly forked MySQLdb1 at https://github.com/tkho/MySQLdb1/commits/libmysqldb that creates a MySQLdb_embedded package and _mysql_embedded.so—versions of MySQLdb that are statically built and linked against the embedded mysql library. These have proved to be a great way to write hermetic tests using the same database stack we run in production; we have it so that subclassing a simple EmbeddedMySQLTestCase and swapping DB URLs is all that’s needed to run against the embedded database.
Now, my question: Does anyone have suggestions on the best way to make this widely available? Ideally the end result is a pypi package that exists side by side (or in) the existing MySQLdb1. Having MySQLdb1 build both _mysql.so and _mysql_embedded.so and support both is one ideal outcome, but I’m not sure there’s a clean way to get there, and it seems like a large change for a mature project. Another alternative is to create a new (published) package as a fork/patchset on top of MySQLdb1. I’d be happy to maintain a fork/sibling package, but would prefer a solution that didn’t require that.
Ideas?