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

TypeError: tuple expected at most 1 arguments, got 3 #2572

Closed
kosuke-zhang opened this issue Feb 5, 2023 · 1 comment
Closed

TypeError: tuple expected at most 1 arguments, got 3 #2572

kosuke-zhang opened this issue Feb 5, 2023 · 1 comment

Comments

@kosuke-zhang
Copy link
Contributor

kosuke-zhang commented Feb 5, 2023

Exception in thread django-main-thread:

Traceback (most recent call last):

  File "/opt/redis/__init__.py", line 57, in <module>

    VERSION = tuple(map(int_or_str, __version__.split(".")))

AttributeError: 'NoneType' object has no attribute 'split'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):

  File "/var/lang/python37/lib/python3.7/threading.py", line 926, in _bootstrap_inner

    self.run()

  File "/var/lang/python37/lib/python3.7/threading.py", line 870, in run

    self._target(*self._args, **self._kwargs)

  File "/opt/django/utils/autoreload.py", line 64, in wrapper

    fn(*args, **kwargs)

  File "/opt/django/core/management/commands/runserver.py", line 118, in inner_run

    self.check(display_num_errors=True)

  File "/opt/django/core/management/base.py", line 423, in check

    databases=databases,

  File "/opt/django/core/checks/registry.py", line 76, in run_checks

    new_errors = check(app_configs=app_configs, databases=databases)

  File "/opt/django/core/checks/urls.py", line 40, in check_url_namespaces_unique

    all_namespaces = _load_all_namespaces(resolver)

  File "/opt/django/core/checks/urls.py", line 57, in _load_all_namespaces

    url_patterns = getattr(resolver, 'url_patterns', [])

  File "/opt/django/utils/functional.py", line 48, in __get__

    res = instance.__dict__[self.name] = self.func(instance)

  File "/opt/django/urls/resolvers.py", line 602, in url_patterns

    patterns = getattr(self.urlconf_module, "urlpatterns", self.urlconf_module)

  File "/opt/django/utils/functional.py", line 48, in __get__

    res = instance.__dict__[self.name] = self.func(instance)

  File "/opt/django/urls/resolvers.py", line 595, in urlconf_module

    return import_module(self.urlconf_name)

  File "/var/lang/python37/lib/python3.7/importlib/__init__.py", line 127, in import_module

    return _bootstrap._gcd_import(name[level:], package, level)

  File "<frozen importlib._bootstrap>", line 1006, in _gcd_import

  File "<frozen importlib._bootstrap>", line 983, in _find_and_load

  File "<frozen importlib._bootstrap>", line 967, in _find_and_load_unlocked

  File "<frozen importlib._bootstrap>", line 677, in _load_unlocked

  File "<frozen importlib._bootstrap_external>", line 728, in exec_module

  File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed

  File "/var/user/backend/urls.py", line 23, in <module>

    from app_config.views import get_app_config

  File "/var/user/apps/app_config/views.py", line 11, in <module>

    @permission_classes((AllowAny,))

  File "/opt/django/utils/decorators.py", line 117, in _decorator

    middleware = middleware_class(view_func, *m_args, **m_kwargs)

  File "/opt/django/middleware/cache.py", line 174, in __init__

    super().__init__(get_response)

  File "/opt/django/middleware/cache.py", line 67, in __init__

    super().__init__(get_response)

  File "/opt/django/middleware/cache.py", line 133, in __init__

    self.cache = caches[self.cache_alias]

  File "/opt/django/utils/connection.py", line 62, in __getitem__

    conn = self.create_connection(alias)

  File "/opt/django/core/cache/__init__.py", line 44, in create_connection

    return backend_cls(location, params)

  File "/opt/django_redis/cache.py", line 53, in __init__

    self._client_cls = import_string(self._client_cls)

  File "/opt/django/utils/module_loading.py", line 17, in import_string

    module = import_module(module_path)

  File "/var/lang/python37/lib/python3.7/importlib/__init__.py", line 127, in import_module

    return _bootstrap._gcd_import(name[level:], package, level)

  File "/opt/django_redis/client/__init__.py", line 1, in <module>

    from .default import DefaultClient

  File "/opt/django_redis/client/default.py", line 12, in <module>

    from redis import Redis

  File "/opt/redis/__init__.py", line 59, in <module>

    VERSION = tuple(99, 99, 99)

TypeError: tuple expected at most 1 arguments, got 3
@dvora-h
Copy link
Collaborator

dvora-h commented Feb 6, 2023

Fixed by #2573

@dvora-h dvora-h closed this as completed Feb 6, 2023
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

No branches or pull requests

2 participants