From 83d05aa5aff0b27027fb10986390d898a3153eb2 Mon Sep 17 00:00:00 2001 From: Jason Kirtland Date: Wed, 29 Aug 2007 22:27:45 +0000 Subject: engine.url cleanups [ticket:742] - translate_connect_args can now take kw args or the classic list - in-tree dialects updated to supply their overrides as keywords - tweaked url parsing in the spirit of the #742 patch, more or less --- lib/sqlalchemy/databases/mysql.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'lib/sqlalchemy/databases/mysql.py') diff --git a/lib/sqlalchemy/databases/mysql.py b/lib/sqlalchemy/databases/mysql.py index af01cf84e..6d5c54578 100644 --- a/lib/sqlalchemy/databases/mysql.py +++ b/lib/sqlalchemy/databases/mysql.py @@ -1353,7 +1353,8 @@ class MySQLDialect(default.DefaultDialect): dbapi = classmethod(dbapi) def create_connect_args(self, url): - opts = url.translate_connect_args(['host', 'db', 'user', 'passwd', 'port']) + opts = url.translate_connect_args(database='db', username='user', + password='passwd') opts.update(url.query) util.coerce_kw_type(opts, 'compress', bool) -- cgit v1.2.1