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

iterable ConnectionHandler #129

Open
jayvdb opened this issue Jul 5, 2020 · 2 comments
Open

iterable ConnectionHandler #129

jayvdb opened this issue Jul 5, 2020 · 2 comments
Labels
enhancement New feature or request

Comments

@jayvdb
Copy link
Contributor

jayvdb commented Jul 5, 2020

Occurs in the test suite of https://github.com/pmac/django-redirect-urls/ , but I have seen it frequently in test suites which havent been updated to use pytest.

cls = <class 'tests.test_middleware.TestRedirectsMiddleware'>

    @classmethod
    def _validate_databases(cls):
        if cls.databases == '__all__':
            return frozenset(connections)
        for alias in cls.databases:
>           if alias not in connections:
E           TypeError: argument of type 'ConnectionHandler' is not iterable
@browniebroke
Copy link
Owner

browniebroke commented Jul 5, 2020

Hey, I'm not sure I understand what you mean. Is it a bug that you're reporting or are you suggesting a new feature? Can you please elaborate on what does this have to do with django-codemod?

@jayvdb
Copy link
Contributor Author

jayvdb commented Jul 5, 2020

That is a code excerpt for which I need a fixer, and will very likely build it soon.

@browniebroke browniebroke added the enhancement New feature or request label Jul 5, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants