django-sqlserver
django-sqlserver copied to clipboard
Add support for more detailed connection parameters
On the front page you mention:
You can also specify additional OPTIONS attribute as described in http://django-mssql.readthedocs.io/en/latest/settings.html#options
The link talks about extra_params
. But I don't see it being passed to pytds.connect()
. The part of the code responsible for creating the connection dict either hardcodes some values or checks _SUPPORTED_OPTIONS
, which contains only failover_partner
(that is already retrieved from the options few lines prior to checking _SUPPORTED_OPTIONS
).
In my case I'm missing the ability to set timeout
and login_timeout
(which should as easy as just passing them to connect
- e.g. through updating _SUPPORTED_OPTIONS
). I don't know about an easy way of adding extra_params
support, since I don't see that one being accepted by the connect
function.
After the merge of #23 all of the kwargs from pytds.connect()
should be supported.
extra_params
is not one of those, so it's still not supported.