From 99ae0dc821a1a36a6d1a966f51843f6632fc4117 Mon Sep 17 00:00:00 2001 From: Mike Bayer Date: Tue, 15 Apr 2014 23:34:07 -0400 Subject: - Fixed bug in new :meth:`.DialectKWArgs.argument_for` method where adding an argument for a construct not previously included for any special arguments would fail. fixes #3024 --- lib/sqlalchemy/sql/base.py | 2 ++ 1 file changed, 2 insertions(+) (limited to 'lib/sqlalchemy/sql') diff --git a/lib/sqlalchemy/sql/base.py b/lib/sqlalchemy/sql/base.py index 379f61ed7..59f30ed69 100644 --- a/lib/sqlalchemy/sql/base.py +++ b/lib/sqlalchemy/sql/base.py @@ -181,6 +181,8 @@ class DialectKWArgs(object): raise exc.ArgumentError("Dialect '%s' does have keyword-argument " "validation and defaults enabled configured" % dialect_name) + if cls not in construct_arg_dictionary: + construct_arg_dictionary[cls] = {} construct_arg_dictionary[cls][argument_name] = default @util.memoized_property -- cgit v1.2.1