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 #663 - Fixed incompatibility of DatabaseSchemaIntrospection with django #693

Merged
merged 1 commit into from
Dec 10, 2021

Conversation

adrienrusso
Copy link
Contributor

@adrienrusso adrienrusso commented Nov 22, 2021

This PR fixes issue #663.

Instead of duplicating the code of the DatabaseSchemaIntrospection methods, the schema search path can simply be set on the cursor.

This class was clearly out of date and some of its functions no longer exist in django.

@adrienrusso adrienrusso marked this pull request as ready for review November 22, 2021 20:45
@adrienrusso adrienrusso marked this pull request as draft November 22, 2021 22:09
…spection with django

Fix search path issue

typo

Fix for psql support
@adrienrusso adrienrusso marked this pull request as ready for review November 22, 2021 23:13
@tomturner
Copy link
Member

@adrienrusso Thanks I will have a look at some point

@adrienrusso
Copy link
Contributor Author

@tomturner any update?

@tomturner tomturner merged commit 12aac37 into django-tenants:master Dec 10, 2021
@tomturner
Copy link
Member

@adrienrusso thank you for doing this. Sorry for the wait it took a bit a time for me to test hence the deley.

Notes to myself on how I tested it

    from django.db import connection
    from django.apps import apps
    tables = connection.introspection.table_names()
    seen_models = connection.introspection.installed_models(tables)
    for model in apps.get_models():
        print(model)

@adrienrusso adrienrusso deleted the fix/db-introspection branch December 10, 2021 12:42
@adrienrusso
Copy link
Contributor Author

Thanks for the review and the merge 👌

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

Successfully merging this pull request may close these issues.

None yet

2 participants