Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix data_types incompatibility with Django 1.8+, issue #128. #129

Merged
merged 1 commit into from
Nov 17, 2016

Conversation

chris-nlnz
Copy link

Django 1.8 changed to assume the data_types attribute is on the DatabaseWrapper class, rather than the DatabaseCreation class, causing issues when saving objects (see issue #128 for more details).

I've added data_types to the DatabaseWrapper as well so as to be compatible with Django 1.8+ as well as retain compatibility with older versions.

@RossRogers
Copy link
Contributor

RossRogers commented Nov 17, 2016

Hi Chris,

Thanks for the contribution. Apologies for the lack of response on your issue. We're all crazy busy right now, unfortunately.

The django-pyodbc project does not want to drop support for Django 1.4-1.7 at this time. I don't have Microsoft SQL Server on my home machine, so I can't test it, but it seems like your edits are not backwards compatible with versions less than 1.7. Have you tried running your version against django 1.7? e.g. pip install django==1.7.11 and try to invoke your code.

@chris-nlnz
Copy link
Author

Hi Ross,

No worries, I understand you're busy, wasn't expecting such a quick response even!

I haven't removed the data_types from the DatabaseCreation class so now it's present in both classes, which I think should mean ensures compatibility with older Django versions as well.

I've tried it against 1.7.11 and 1.6.11 and it works fine (I was having some issues running the test suites so I've only done a few basic tests, e.g. some regular Django queries and a .save() that previously failed before this fix).

Thanks for the feedback

@RossRogers
Copy link
Contributor

Yeah, the test suites are a little rusty too. W.I.P...

I can't see how your edits could cause a conflict, so I'll merge it in.

@RossRogers RossRogers merged commit 95dae6e into lionheart:master Nov 17, 2016
@chris-nlnz
Copy link
Author

Great, thanks!

@RossRogers
Copy link
Contributor

I'll do a proper release in my morning tomorrow and bump the version to 1.0.1 .

@RossRogers
Copy link
Contributor

Released as version 1.0.1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants