--- Begin Message ---
Source: djangorestframework-filters
Version: 1.0.0.dev2-2
Severity: serious
Justification: FTBFS
Tags: trixie sid ftbfs
User: [email protected]
Usertags: ftbfs-20230925 ftbfs-trixie
Hi,
During a rebuild of all packages in sid, your package failed to build
on amd64.
Relevant part (hopefully):
> debian/rules build
> dh build --with python3 --buildsystem=pybuild
> dh_update_autotools_config -O--buildsystem=pybuild
> dh_autoreconf -O--buildsystem=pybuild
> dh_auto_configure -O--buildsystem=pybuild
> pybuild --configure -i python{version} -p 3.11
> I: pybuild base:291: python3.11 setup.py config
> /usr/lib/python3/dist-packages/setuptools/config/setupcfg.py:293:
> _DeprecatedConfig: Deprecated config in `setup.cfg`
> !!
>
>
> ********************************************************************************
> The license_file parameter is deprecated, use license_files instead.
>
> By 2023-Oct-30, you need to update your project and remove deprecated
> calls
> or your builds will no longer be supported.
>
> See
> https://setuptools.pypa.io/en/latest/userguide/declarative_config.html for
> details.
>
> ********************************************************************************
>
> !!
> parsed = self.parsers.get(option_name, lambda x: x)(value)
> running config
> dh_auto_build -O--buildsystem=pybuild
> pybuild --build -i python{version} -p 3.11
> I: pybuild base:291: /usr/bin/python3 setup.py build
> /usr/lib/python3/dist-packages/setuptools/config/setupcfg.py:293:
> _DeprecatedConfig: Deprecated config in `setup.cfg`
> !!
>
>
> ********************************************************************************
> The license_file parameter is deprecated, use license_files instead.
>
> By 2023-Oct-30, you need to update your project and remove deprecated
> calls
> or your builds will no longer be supported.
>
> See
> https://setuptools.pypa.io/en/latest/userguide/declarative_config.html for
> details.
>
> ********************************************************************************
>
> !!
> parsed = self.parsers.get(option_name, lambda x: x)(value)
> running build
> running build_py
> creating
> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.11_djangorestframework-filters/build/rest_framework_filters
> copying rest_framework_filters/filterset.py ->
> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.11_djangorestframework-filters/build/rest_framework_filters
> copying rest_framework_filters/utils.py ->
> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.11_djangorestframework-filters/build/rest_framework_filters
> copying rest_framework_filters/filters.py ->
> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.11_djangorestframework-filters/build/rest_framework_filters
> copying rest_framework_filters/__init__.py ->
> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.11_djangorestframework-filters/build/rest_framework_filters
> copying rest_framework_filters/backends.py ->
> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.11_djangorestframework-filters/build/rest_framework_filters
> copying rest_framework_filters/complex_ops.py ->
> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.11_djangorestframework-filters/build/rest_framework_filters
> creating
> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.11_djangorestframework-filters/build/rest_framework_filters/templatetags
> copying rest_framework_filters/templatetags/rest_framework_filters.py ->
> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.11_djangorestframework-filters/build/rest_framework_filters/templatetags
> copying rest_framework_filters/templatetags/__init__.py ->
> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.11_djangorestframework-filters/build/rest_framework_filters/templatetags
> running egg_info
> creating djangorestframework_filters.egg-info
> writing djangorestframework_filters.egg-info/PKG-INFO
> writing dependency_links to
> djangorestframework_filters.egg-info/dependency_links.txt
> writing requirements to djangorestframework_filters.egg-info/requires.txt
> writing top-level names to djangorestframework_filters.egg-info/top_level.txt
> writing manifest file 'djangorestframework_filters.egg-info/SOURCES.txt'
> reading manifest file 'djangorestframework_filters.egg-info/SOURCES.txt'
> reading manifest template 'MANIFEST.in'
> warning: no previously-included files matching '__pycache__' found anywhere
> in distribution
> warning: no previously-included files matching '*.py[co]' found anywhere in
> distribution
> adding license file 'LICENSE'
> writing manifest file 'djangorestframework_filters.egg-info/SOURCES.txt'
> /usr/lib/python3/dist-packages/setuptools/command/build_py.py:204: _Warning:
> Package 'rest_framework_filters.templates.rest_framework_filters' is absent
> from the `packages` configuration.
> !!
>
>
> ********************************************************************************
> ############################
> # Package would be ignored #
> ############################
> Python recognizes
> 'rest_framework_filters.templates.rest_framework_filters' as an importable
> package[^1],
> but it is absent from setuptools' `packages` configuration.
>
> This leads to an ambiguous overall configuration. If you want to
> distribute this
> package, please make sure that
> 'rest_framework_filters.templates.rest_framework_filters' is explicitly added
> to the `packages` configuration field.
>
> Alternatively, you can also rely on setuptools' discovery methods
> (for example by using `find_namespace_packages(...)`/`find_namespace:`
> instead of `find_packages(...)`/`find:`).
>
> You can read more about "package discovery" on setuptools
> documentation page:
>
> -
> https://setuptools.pypa.io/en/latest/userguide/package_discovery.html
>
> If you don't want
> 'rest_framework_filters.templates.rest_framework_filters' to be distributed
> and are
> already explicitly excluding
> 'rest_framework_filters.templates.rest_framework_filters' via
> `find_namespace_packages(...)/find_namespace` or
> `find_packages(...)/find`,
> you can try to use `exclude_package_data`, or
> `include-package-data=False` in
> combination with a more fine grained `package-data` configuration.
>
> You can read more about "package data files" on setuptools
> documentation page:
>
> - https://setuptools.pypa.io/en/latest/userguide/datafiles.html
>
>
> [^1]: For Python, any directory (with suitable naming) can be
> imported,
> even if it does not contain any `.py` files.
> On the other hand, currently there is no concept of package data
> directory, all directories are treated like packages.
>
> ********************************************************************************
>
> !!
> check.warn(importable)
> creating
> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.11_djangorestframework-filters/build/rest_framework_filters/templates
> creating
> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.11_djangorestframework-filters/build/rest_framework_filters/templates/rest_framework_filters
> copying
> rest_framework_filters/templates/rest_framework_filters/crispy_form.html ->
> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.11_djangorestframework-filters/build/rest_framework_filters/templates/rest_framework_filters
> copying rest_framework_filters/templates/rest_framework_filters/form.html ->
> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.11_djangorestframework-filters/build/rest_framework_filters/templates/rest_framework_filters
> dh_auto_test -O--buildsystem=pybuild
> pybuild --test --test-pytest -i python{version} -p 3.11
> I: pybuild base:291: cd
> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.11_djangorestframework-filters/build;
> python3.11 -m pytest tests
> ============================= test session starts
> ==============================
> platform linux -- Python 3.11.5, pytest-7.4.2, pluggy-1.3.0
> django: settings: tests.settings (from env)
> rootdir: /<<PKGBUILDDIR>>
> plugins: django-4.5.2
> collected 151 items
>
> tests/test_backends.py .F.F........FFFFFF [
> 11%]
> tests/test_complex_ops.py ................ [
> 22%]
> tests/test_filtering.py .......................... [
> 39%]
> tests/test_filters.py ... [
> 41%]
> tests/test_filterset.py ................................................ [
> 73%]
> ....... [
> 78%]
> tests/test_forms.py ...... [
> 82%]
> tests/test_regressions.py ........ [
> 87%]
> tests/test_utils.py ....... [
> 92%]
> tests/related/test_exclude.py ....... [
> 96%]
> tests/related/test_filter.py .....
> [100%]
>
> =================================== FAILURES
> ===================================
> ________________ BackendTests.test_django_filter_compatibility
> _________________
>
> request = <WSGIRequest: GET '/df-users/?username=user1'>
>
> @wraps(get_response)
> def inner(request):
> try:
> > response = get_response(request)
>
> /usr/lib/python3/dist-packages/django/core/handlers/exception.py:55:
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> _
> /usr/lib/python3/dist-packages/django/core/handlers/base.py:181: in
> _get_response
> callback, callback_args, callback_kwargs = self.resolve_request(request)
> /usr/lib/python3/dist-packages/django/core/handlers/base.py:313: in
> resolve_request
> resolver_match = resolver.resolve(request.path_info)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:663: in resolve
> for pattern in self.url_patterns:
> /usr/lib/python3/dist-packages/django/utils/functional.py:57: in __get__
> res = instance.__dict__[self.name] = self.func(instance)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:715: in url_patterns
> patterns = getattr(self.urlconf_module, "urlpatterns",
> self.urlconf_module)
> /usr/lib/python3/dist-packages/django/utils/functional.py:57: in __get__
> res = instance.__dict__[self.name] = self.func(instance)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:708: in urlconf_module
> return import_module(self.urlconf_name)
> /usr/lib/python3.11/importlib/__init__.py:126: in import_module
> return _bootstrap._gcd_import(name[level:], package, level)
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> _
>
>
> > from django.conf.urls import include, url
> E ImportError: cannot import name 'url' from 'django.conf.urls'
> (/usr/lib/python3/dist-packages/django/conf/urls/__init__.py)
>
> tests/testapp/urls.py:2: ImportError
>
> During handling of the above exception, another exception occurred:
>
> self = <tests.test_backends.BackendTests
> testMethod=test_django_filter_compatibility>
>
> def test_django_filter_compatibility(self):
> > response = self.client.get('/df-users/', {'username': 'user1'})
>
> tests/test_backends.py:35:
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> _
> /usr/lib/python3/dist-packages/rest_framework/test.py:289: in get
> response = super().get(path, data=data, **extra)
> /usr/lib/python3/dist-packages/rest_framework/test.py:206: in get
> return self.generic('GET', path, **r)
> /usr/lib/python3/dist-packages/rest_framework/test.py:234: in generic
> return super().generic(
> /usr/lib/python3/dist-packages/django/test/client.py:609: in generic
> return self.request(**r)
> /usr/lib/python3/dist-packages/rest_framework/test.py:286: in request
> return super().request(**kwargs)
> /usr/lib/python3/dist-packages/rest_framework/test.py:238: in request
> request = super().request(**kwargs)
> /usr/lib/python3/dist-packages/django/test/client.py:886: in request
> response = self.handler(environ)
> /usr/lib/python3/dist-packages/django/test/client.py:176: in __call__
> response = self.get_response(request)
> /usr/lib/python3/dist-packages/rest_framework/test.py:258: in get_response
> return super().get_response(request)
> /usr/lib/python3/dist-packages/django/core/handlers/base.py:140: in
> get_response
> response = self._middleware_chain(request)
> /usr/lib/python3/dist-packages/django/core/handlers/exception.py:57: in inner
> response = response_for_exception(request, exc)
> /usr/lib/python3/dist-packages/django/core/handlers/exception.py:140: in
> response_for_exception
> response = handle_uncaught_exception(
> /usr/lib/python3/dist-packages/django/core/handlers/exception.py:184: in
> handle_uncaught_exception
> callback = resolver.resolve_error_handler(500)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:729: in
> resolve_error_handler
> callback = getattr(self.urlconf_module, "handler%s" % view_type, None)
> /usr/lib/python3/dist-packages/django/utils/functional.py:57: in __get__
> res = instance.__dict__[self.name] = self.func(instance)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:708: in urlconf_module
> return import_module(self.urlconf_name)
> /usr/lib/python3.11/importlib/__init__.py:126: in import_module
> return _bootstrap._gcd_import(name[level:], package, level)
> <frozen importlib._bootstrap>:1204: in _gcd_import
> ???
> <frozen importlib._bootstrap>:1176: in _find_and_load
> ???
> <frozen importlib._bootstrap>:1147: in _find_and_load_unlocked
> ???
> <frozen importlib._bootstrap>:690: in _load_unlocked
> ???
> <frozen importlib._bootstrap_external>:940: in exec_module
> ???
> <frozen importlib._bootstrap>:241: in _call_with_frames_removed
> ???
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> _
>
>
> > from django.conf.urls import include, url
> E ImportError: cannot import name 'url' from 'django.conf.urls'
> (/usr/lib/python3/dist-packages/django/conf/urls/__init__.py)
>
> tests/testapp/urls.py:2: ImportError
> ________________ BackendTests.test_filterset_fields_reusability
> ________________
>
> request = <WSGIRequest: GET '/ff-users/?username=user1'>
>
> @wraps(get_response)
> def inner(request):
> try:
> > response = get_response(request)
>
> /usr/lib/python3/dist-packages/django/core/handlers/exception.py:55:
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> _
> /usr/lib/python3/dist-packages/django/core/handlers/base.py:181: in
> _get_response
> callback, callback_args, callback_kwargs = self.resolve_request(request)
> /usr/lib/python3/dist-packages/django/core/handlers/base.py:313: in
> resolve_request
> resolver_match = resolver.resolve(request.path_info)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:663: in resolve
> for pattern in self.url_patterns:
> /usr/lib/python3/dist-packages/django/utils/functional.py:57: in __get__
> res = instance.__dict__[self.name] = self.func(instance)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:715: in url_patterns
> patterns = getattr(self.urlconf_module, "urlpatterns",
> self.urlconf_module)
> /usr/lib/python3/dist-packages/django/utils/functional.py:57: in __get__
> res = instance.__dict__[self.name] = self.func(instance)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:708: in urlconf_module
> return import_module(self.urlconf_name)
> /usr/lib/python3.11/importlib/__init__.py:126: in import_module
> return _bootstrap._gcd_import(name[level:], package, level)
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> _
>
>
> > from django.conf.urls import include, url
> E ImportError: cannot import name 'url' from 'django.conf.urls'
> (/usr/lib/python3/dist-packages/django/conf/urls/__init__.py)
>
> tests/testapp/urls.py:2: ImportError
>
> During handling of the above exception, another exception occurred:
>
> self = <tests.test_backends.BackendTests
> testMethod=test_filterset_fields_reusability>
>
> def test_filterset_fields_reusability(self):
> # Ensure auto-generated FilterSet is reusable w/ filterset_fields.
> See:
> # https://github.com/philipn/django-rest-framework-filters/issues/81
>
> # Ensure that the filterset_fields aren't altered
> self.assertDictEqual(
> views.FilterFieldsUserViewSet.filterset_fields,
> {'username': '__all__'},
> )
>
> > response = self.client.get('/ff-users/', {'username': 'user1'})
>
> tests/test_backends.py:49:
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> _
> /usr/lib/python3/dist-packages/rest_framework/test.py:289: in get
> response = super().get(path, data=data, **extra)
> /usr/lib/python3/dist-packages/rest_framework/test.py:206: in get
> return self.generic('GET', path, **r)
> /usr/lib/python3/dist-packages/rest_framework/test.py:234: in generic
> return super().generic(
> /usr/lib/python3/dist-packages/django/test/client.py:609: in generic
> return self.request(**r)
> /usr/lib/python3/dist-packages/rest_framework/test.py:286: in request
> return super().request(**kwargs)
> /usr/lib/python3/dist-packages/rest_framework/test.py:238: in request
> request = super().request(**kwargs)
> /usr/lib/python3/dist-packages/django/test/client.py:886: in request
> response = self.handler(environ)
> /usr/lib/python3/dist-packages/django/test/client.py:176: in __call__
> response = self.get_response(request)
> /usr/lib/python3/dist-packages/rest_framework/test.py:258: in get_response
> return super().get_response(request)
> /usr/lib/python3/dist-packages/django/core/handlers/base.py:140: in
> get_response
> response = self._middleware_chain(request)
> /usr/lib/python3/dist-packages/django/core/handlers/exception.py:57: in inner
> response = response_for_exception(request, exc)
> /usr/lib/python3/dist-packages/django/core/handlers/exception.py:140: in
> response_for_exception
> response = handle_uncaught_exception(
> /usr/lib/python3/dist-packages/django/core/handlers/exception.py:184: in
> handle_uncaught_exception
> callback = resolver.resolve_error_handler(500)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:729: in
> resolve_error_handler
> callback = getattr(self.urlconf_module, "handler%s" % view_type, None)
> /usr/lib/python3/dist-packages/django/utils/functional.py:57: in __get__
> res = instance.__dict__[self.name] = self.func(instance)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:708: in urlconf_module
> return import_module(self.urlconf_name)
> /usr/lib/python3.11/importlib/__init__.py:126: in import_module
> return _bootstrap._gcd_import(name[level:], package, level)
> <frozen importlib._bootstrap>:1204: in _gcd_import
> ???
> <frozen importlib._bootstrap>:1176: in _find_and_load
> ???
> <frozen importlib._bootstrap>:1147: in _find_and_load_unlocked
> ???
> <frozen importlib._bootstrap>:690: in _load_unlocked
> ???
> <frozen importlib._bootstrap_external>:940: in exec_module
> ???
> <frozen importlib._bootstrap>:241: in _call_with_frames_removed
> ???
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> _
>
>
> > from django.conf.urls import include, url
> E ImportError: cannot import name 'url' from 'django.conf.urls'
> (/usr/lib/python3/dist-packages/django/conf/urls/__init__.py)
>
> tests/testapp/urls.py:2: ImportError
> __ BackendCrispyFormsRenderingTests.test_crispy_forms_filterset_compatibility
> __
>
> self = <tests.test_backends.BackendCrispyFormsRenderingTests
> testMethod=test_crispy_forms_filterset_compatibility>
>
> def test_crispy_forms_filterset_compatibility(self):
> class SimpleCrispyFilterSet(FilterSet):
> class Meta:
> model = models.User
> fields = ['username']
>
> class SimpleViewSet(views.FilterFieldsUserViewSet):
> filterset_class = SimpleCrispyFilterSet
>
> > self.assertHTMLEqual(self.render(SimpleViewSet), """
> <h2>Field filters</h2>
> <form method="get">
> <div id="div_id_username" class="form-group">
> <label for="id_username" class="control-label
> ">Username</label>
> <div class=" controls">
> <input type="text"
> name="username"
> class="form-control textinput textInput"
> id="id_username">
> </div>
> </div>
> <button type="submit" class="btn btn-primary">Submit</button>
> </form>
> """)
>
> tests/test_backends.py:346:
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> _
> tests/test_backends.py:24: in render
> return backend().to_html(request, view.get_queryset(), view)
> rest_framework_filters/backends.py:50: in to_html
> return super().to_html(request, queryset, view)
> /usr/lib/python3/dist-packages/django_filters/rest_framework/backends.py:83:
> in to_html
> return template.render(context, request)
> /usr/lib/python3/dist-packages/django/template/backends/django.py:61: in
> render
> return self.template.render(context)
> /usr/lib/python3/dist-packages/django/template/base.py:175: in render
> return self._render(context)
> /usr/lib/python3/dist-packages/django/test/utils.py:112: in
> instrumented_test_render
> return self.nodelist.render(context)
> /usr/lib/python3/dist-packages/django/template/base.py:1005: in render
> return SafeString("".join([node.render_annotated(context) for node in
> self]))
> /usr/lib/python3/dist-packages/django/template/base.py:1005: in <listcomp>
> return SafeString("".join([node.render_annotated(context) for node in
> self]))
> /usr/lib/python3/dist-packages/django/template/base.py:966: in
> render_annotated
> return self.render(context)
> /usr/lib/python3/dist-packages/crispy_forms/templatetags/crispy_forms_tags.py:204:
> in render
> c = self.get_render(context).flatten()
> /usr/lib/python3/dist-packages/crispy_forms/templatetags/crispy_forms_tags.py:111:
> in get_render
> response_dict = self.get_response_dict(helper, context, is_formset)
> /usr/lib/python3/dist-packages/crispy_forms/templatetags/crispy_forms_tags.py:149:
> in get_response_dict
> attrs = helper.get_attributes(template_pack=self.template_pack)
> /usr/lib/python3/dist-packages/crispy_forms/helper.py:355: in get_attributes
> if self.form_action:
> /usr/lib/python3/dist-packages/crispy_forms/helper.py:243: in form_action
> return reverse(self._form_action)
> /usr/lib/python3/dist-packages/django/urls/base.py:88: in reverse
> return resolver._reverse_with_prefix(view, prefix, *args, **kwargs)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:746: in
> _reverse_with_prefix
> self._populate()
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:543: in _populate
> for url_pattern in reversed(self.url_patterns):
> /usr/lib/python3/dist-packages/django/utils/functional.py:57: in __get__
> res = instance.__dict__[self.name] = self.func(instance)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:715: in url_patterns
> patterns = getattr(self.urlconf_module, "urlpatterns",
> self.urlconf_module)
> /usr/lib/python3/dist-packages/django/utils/functional.py:57: in __get__
> res = instance.__dict__[self.name] = self.func(instance)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:708: in urlconf_module
> return import_module(self.urlconf_name)
> /usr/lib/python3.11/importlib/__init__.py:126: in import_module
> return _bootstrap._gcd_import(name[level:], package, level)
> <frozen importlib._bootstrap>:1204: in _gcd_import
> ???
> <frozen importlib._bootstrap>:1176: in _find_and_load
> ???
> <frozen importlib._bootstrap>:1147: in _find_and_load_unlocked
> ???
> <frozen importlib._bootstrap>:690: in _load_unlocked
> ???
> <frozen importlib._bootstrap_external>:940: in exec_module
> ???
> <frozen importlib._bootstrap>:241: in _call_with_frames_removed
> ???
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> _
>
>
> > from django.conf.urls import include, url
> E ImportError: cannot import name 'url' from 'django.conf.urls'
> (/usr/lib/python3/dist-packages/django/conf/urls/__init__.py)
>
> tests/testapp/urls.py:2: ImportError
> _____ BackendCrispyFormsRenderingTests.test_related_filterset_crispy_forms
> _____
>
> self = <tests.test_backends.BackendCrispyFormsRenderingTests
> testMethod=test_related_filterset_crispy_forms>
>
> def test_related_filterset_crispy_forms(self):
> class UserFilter(FilterSet):
> username = filters.CharFilter()
>
> class NoteFilter(FilterSet):
> author = filters.RelatedFilter(
> filterset=UserFilter,
> queryset=models.User.objects.all(),
> label='Writer',
> )
>
> class RelatedViewSet(views.NoteViewSet):
> filterset_class = NoteFilter
>
> > self.assertHTMLEqual(self.render(RelatedViewSet), """
> <h2>Field filters</h2>
> <form method="get">
> <div id="div_id_author" class="form-group">
> <label for="id_author" class="control-label ">Writer</label>
> <div class=" controls">
> <select name="author" class="select form-control"
> id="id_author">
> <option value="" selected>---------</option>
> </select>
> </div>
> </div>
>
> <fieldset>
> <legend>Writer</legend>
>
> <div id="div_id_author__username" class="form-group">
> <label for="id_author__username" class="control-label ">
> Username
> </label>
> <div class=" controls">
> <input type="text" class="form-control textinput
> textInput"
> id="id_author__username"
> name="author__username">
> </div>
> </div>
> </fieldset>
>
> <button type="submit" class="btn btn-primary">Submit</button>
> </form>
> """)
>
> tests/test_backends.py:376:
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> _
> tests/test_backends.py:24: in render
> return backend().to_html(request, view.get_queryset(), view)
> rest_framework_filters/backends.py:50: in to_html
> return super().to_html(request, queryset, view)
> /usr/lib/python3/dist-packages/django_filters/rest_framework/backends.py:83:
> in to_html
> return template.render(context, request)
> /usr/lib/python3/dist-packages/django/template/backends/django.py:61: in
> render
> return self.template.render(context)
> /usr/lib/python3/dist-packages/django/template/base.py:175: in render
> return self._render(context)
> /usr/lib/python3/dist-packages/django/test/utils.py:112: in
> instrumented_test_render
> return self.nodelist.render(context)
> /usr/lib/python3/dist-packages/django/template/base.py:1005: in render
> return SafeString("".join([node.render_annotated(context) for node in
> self]))
> /usr/lib/python3/dist-packages/django/template/base.py:1005: in <listcomp>
> return SafeString("".join([node.render_annotated(context) for node in
> self]))
> /usr/lib/python3/dist-packages/django/template/base.py:966: in
> render_annotated
> return self.render(context)
> /usr/lib/python3/dist-packages/crispy_forms/templatetags/crispy_forms_tags.py:204:
> in render
> c = self.get_render(context).flatten()
> /usr/lib/python3/dist-packages/crispy_forms/templatetags/crispy_forms_tags.py:111:
> in get_render
> response_dict = self.get_response_dict(helper, context, is_formset)
> /usr/lib/python3/dist-packages/crispy_forms/templatetags/crispy_forms_tags.py:149:
> in get_response_dict
> attrs = helper.get_attributes(template_pack=self.template_pack)
> /usr/lib/python3/dist-packages/crispy_forms/helper.py:355: in get_attributes
> if self.form_action:
> /usr/lib/python3/dist-packages/crispy_forms/helper.py:243: in form_action
> return reverse(self._form_action)
> /usr/lib/python3/dist-packages/django/urls/base.py:88: in reverse
> return resolver._reverse_with_prefix(view, prefix, *args, **kwargs)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:746: in
> _reverse_with_prefix
> self._populate()
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:543: in _populate
> for url_pattern in reversed(self.url_patterns):
> /usr/lib/python3/dist-packages/django/utils/functional.py:57: in __get__
> res = instance.__dict__[self.name] = self.func(instance)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:715: in url_patterns
> patterns = getattr(self.urlconf_module, "urlpatterns",
> self.urlconf_module)
> /usr/lib/python3/dist-packages/django/utils/functional.py:57: in __get__
> res = instance.__dict__[self.name] = self.func(instance)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:708: in urlconf_module
> return import_module(self.urlconf_name)
> /usr/lib/python3.11/importlib/__init__.py:126: in import_module
> return _bootstrap._gcd_import(name[level:], package, level)
> <frozen importlib._bootstrap>:1204: in _gcd_import
> ???
> <frozen importlib._bootstrap>:1176: in _find_and_load
> ???
> <frozen importlib._bootstrap>:1147: in _find_and_load_unlocked
> ???
> <frozen importlib._bootstrap>:690: in _load_unlocked
> ???
> <frozen importlib._bootstrap_external>:940: in exec_module
> ???
> <frozen importlib._bootstrap>:241: in _call_with_frames_removed
> ???
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> _
>
>
> > from django.conf.urls import include, url
> E ImportError: cannot import name 'url' from 'django.conf.urls'
> (/usr/lib/python3/dist-packages/django/conf/urls/__init__.py)
>
> tests/testapp/urls.py:2: ImportError
> ____________________ ComplexFilterBackendTests.test_invalid
> ____________________
>
> request = <WSGIRequest: GET
> '/ffcomplex-users/?filters=%28username%253Duser1%29asdf%28email__contains%253Dexample.org%29'>
>
> @wraps(get_response)
> def inner(request):
> try:
> > response = get_response(request)
>
> /usr/lib/python3/dist-packages/django/core/handlers/exception.py:55:
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> _
> /usr/lib/python3/dist-packages/django/core/handlers/base.py:181: in
> _get_response
> callback, callback_args, callback_kwargs = self.resolve_request(request)
> /usr/lib/python3/dist-packages/django/core/handlers/base.py:313: in
> resolve_request
> resolver_match = resolver.resolve(request.path_info)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:663: in resolve
> for pattern in self.url_patterns:
> /usr/lib/python3/dist-packages/django/utils/functional.py:57: in __get__
> res = instance.__dict__[self.name] = self.func(instance)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:715: in url_patterns
> patterns = getattr(self.urlconf_module, "urlpatterns",
> self.urlconf_module)
> /usr/lib/python3/dist-packages/django/utils/functional.py:57: in __get__
> res = instance.__dict__[self.name] = self.func(instance)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:708: in urlconf_module
> return import_module(self.urlconf_name)
> /usr/lib/python3.11/importlib/__init__.py:126: in import_module
> return _bootstrap._gcd_import(name[level:], package, level)
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> _
>
>
> > from django.conf.urls import include, url
> E ImportError: cannot import name 'url' from 'django.conf.urls'
> (/usr/lib/python3/dist-packages/django/conf/urls/__init__.py)
>
> tests/testapp/urls.py:2: ImportError
>
> During handling of the above exception, another exception occurred:
>
> self = <tests.test_backends.ComplexFilterBackendTests testMethod=test_invalid>
>
> def test_invalid(self):
> readable =
> quote('(username%3Duser1)asdf(email__contains%3Dexample.org)')
> > response = self.client.get('/ffcomplex-users/?filters=' + readable)
>
> tests/test_backends.py:428:
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> _
> /usr/lib/python3/dist-packages/rest_framework/test.py:289: in get
> response = super().get(path, data=data, **extra)
> /usr/lib/python3/dist-packages/rest_framework/test.py:206: in get
> return self.generic('GET', path, **r)
> /usr/lib/python3/dist-packages/rest_framework/test.py:234: in generic
> return super().generic(
> /usr/lib/python3/dist-packages/django/test/client.py:609: in generic
> return self.request(**r)
> /usr/lib/python3/dist-packages/rest_framework/test.py:286: in request
> return super().request(**kwargs)
> /usr/lib/python3/dist-packages/rest_framework/test.py:238: in request
> request = super().request(**kwargs)
> /usr/lib/python3/dist-packages/django/test/client.py:886: in request
> response = self.handler(environ)
> /usr/lib/python3/dist-packages/django/test/client.py:176: in __call__
> response = self.get_response(request)
> /usr/lib/python3/dist-packages/rest_framework/test.py:258: in get_response
> return super().get_response(request)
> /usr/lib/python3/dist-packages/django/core/handlers/base.py:140: in
> get_response
> response = self._middleware_chain(request)
> /usr/lib/python3/dist-packages/django/core/handlers/exception.py:57: in inner
> response = response_for_exception(request, exc)
> /usr/lib/python3/dist-packages/django/core/handlers/exception.py:140: in
> response_for_exception
> response = handle_uncaught_exception(
> /usr/lib/python3/dist-packages/django/core/handlers/exception.py:184: in
> handle_uncaught_exception
> callback = resolver.resolve_error_handler(500)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:729: in
> resolve_error_handler
> callback = getattr(self.urlconf_module, "handler%s" % view_type, None)
> /usr/lib/python3/dist-packages/django/utils/functional.py:57: in __get__
> res = instance.__dict__[self.name] = self.func(instance)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:708: in urlconf_module
> return import_module(self.urlconf_name)
> /usr/lib/python3.11/importlib/__init__.py:126: in import_module
> return _bootstrap._gcd_import(name[level:], package, level)
> <frozen importlib._bootstrap>:1204: in _gcd_import
> ???
> <frozen importlib._bootstrap>:1176: in _find_and_load
> ???
> <frozen importlib._bootstrap>:1147: in _find_and_load_unlocked
> ???
> <frozen importlib._bootstrap>:690: in _load_unlocked
> ???
> <frozen importlib._bootstrap_external>:940: in exec_module
> ???
> <frozen importlib._bootstrap>:241: in _call_with_frames_removed
> ???
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> _
>
>
> > from django.conf.urls import include, url
> E ImportError: cannot import name 'url' from 'django.conf.urls'
> (/usr/lib/python3/dist-packages/django/conf/urls/__init__.py)
>
> tests/testapp/urls.py:2: ImportError
> ___________ ComplexFilterBackendTests.test_invalid_filterset_errors
> ____________
>
> request = <WSGIRequest: GET
> '/ffcomplex-users/?filters=%28id%253Dfoo%29%20%7C%20%28id%253Dbar%29'>
>
> @wraps(get_response)
> def inner(request):
> try:
> > response = get_response(request)
>
> /usr/lib/python3/dist-packages/django/core/handlers/exception.py:55:
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> _
> /usr/lib/python3/dist-packages/django/core/handlers/base.py:181: in
> _get_response
> callback, callback_args, callback_kwargs = self.resolve_request(request)
> /usr/lib/python3/dist-packages/django/core/handlers/base.py:313: in
> resolve_request
> resolver_match = resolver.resolve(request.path_info)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:663: in resolve
> for pattern in self.url_patterns:
> /usr/lib/python3/dist-packages/django/utils/functional.py:57: in __get__
> res = instance.__dict__[self.name] = self.func(instance)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:715: in url_patterns
> patterns = getattr(self.urlconf_module, "urlpatterns",
> self.urlconf_module)
> /usr/lib/python3/dist-packages/django/utils/functional.py:57: in __get__
> res = instance.__dict__[self.name] = self.func(instance)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:708: in urlconf_module
> return import_module(self.urlconf_name)
> /usr/lib/python3.11/importlib/__init__.py:126: in import_module
> return _bootstrap._gcd_import(name[level:], package, level)
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> _
>
>
> > from django.conf.urls import include, url
> E ImportError: cannot import name 'url' from 'django.conf.urls'
> (/usr/lib/python3/dist-packages/django/conf/urls/__init__.py)
>
> tests/testapp/urls.py:2: ImportError
>
> During handling of the above exception, another exception occurred:
>
> self = <tests.test_backends.ComplexFilterBackendTests
> testMethod=test_invalid_filterset_errors>
>
> def test_invalid_filterset_errors(self):
> readable = quote('(id%3Dfoo) | (id%3Dbar)')
> > response = self.client.get('/ffcomplex-users/?filters=' + readable)
>
> tests/test_backends.py:437:
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> _
> /usr/lib/python3/dist-packages/rest_framework/test.py:289: in get
> response = super().get(path, data=data, **extra)
> /usr/lib/python3/dist-packages/rest_framework/test.py:206: in get
> return self.generic('GET', path, **r)
> /usr/lib/python3/dist-packages/rest_framework/test.py:234: in generic
> return super().generic(
> /usr/lib/python3/dist-packages/django/test/client.py:609: in generic
> return self.request(**r)
> /usr/lib/python3/dist-packages/rest_framework/test.py:286: in request
> return super().request(**kwargs)
> /usr/lib/python3/dist-packages/rest_framework/test.py:238: in request
> request = super().request(**kwargs)
> /usr/lib/python3/dist-packages/django/test/client.py:886: in request
> response = self.handler(environ)
> /usr/lib/python3/dist-packages/django/test/client.py:176: in __call__
> response = self.get_response(request)
> /usr/lib/python3/dist-packages/rest_framework/test.py:258: in get_response
> return super().get_response(request)
> /usr/lib/python3/dist-packages/django/core/handlers/base.py:140: in
> get_response
> response = self._middleware_chain(request)
> /usr/lib/python3/dist-packages/django/core/handlers/exception.py:57: in inner
> response = response_for_exception(request, exc)
> /usr/lib/python3/dist-packages/django/core/handlers/exception.py:140: in
> response_for_exception
> response = handle_uncaught_exception(
> /usr/lib/python3/dist-packages/django/core/handlers/exception.py:184: in
> handle_uncaught_exception
> callback = resolver.resolve_error_handler(500)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:729: in
> resolve_error_handler
> callback = getattr(self.urlconf_module, "handler%s" % view_type, None)
> /usr/lib/python3/dist-packages/django/utils/functional.py:57: in __get__
> res = instance.__dict__[self.name] = self.func(instance)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:708: in urlconf_module
> return import_module(self.urlconf_name)
> /usr/lib/python3.11/importlib/__init__.py:126: in import_module
> return _bootstrap._gcd_import(name[level:], package, level)
> <frozen importlib._bootstrap>:1204: in _gcd_import
> ???
> <frozen importlib._bootstrap>:1176: in _find_and_load
> ???
> <frozen importlib._bootstrap>:1147: in _find_and_load_unlocked
> ???
> <frozen importlib._bootstrap>:690: in _load_unlocked
> ???
> <frozen importlib._bootstrap_external>:940: in exec_module
> ???
> <frozen importlib._bootstrap>:241: in _call_with_frames_removed
> ???
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> _
>
>
> > from django.conf.urls import include, url
> E ImportError: cannot import name 'url' from 'django.conf.urls'
> (/usr/lib/python3/dist-packages/django/conf/urls/__init__.py)
>
> tests/testapp/urls.py:2: ImportError
> ___________ ComplexFilterBackendTests.test_pagination_compatibility
> ____________
>
> request = <WSGIRequest: GET
> '/ffcomplex-users/?filters=%28email__contains%253Dexample.org%29'>
>
> @wraps(get_response)
> def inner(request):
> try:
> > response = get_response(request)
>
> /usr/lib/python3/dist-packages/django/core/handlers/exception.py:55:
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> _
> /usr/lib/python3/dist-packages/django/core/handlers/base.py:181: in
> _get_response
> callback, callback_args, callback_kwargs = self.resolve_request(request)
> /usr/lib/python3/dist-packages/django/core/handlers/base.py:313: in
> resolve_request
> resolver_match = resolver.resolve(request.path_info)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:663: in resolve
> for pattern in self.url_patterns:
> /usr/lib/python3/dist-packages/django/utils/functional.py:57: in __get__
> res = instance.__dict__[self.name] = self.func(instance)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:715: in url_patterns
> patterns = getattr(self.urlconf_module, "urlpatterns",
> self.urlconf_module)
> /usr/lib/python3/dist-packages/django/utils/functional.py:57: in __get__
> res = instance.__dict__[self.name] = self.func(instance)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:708: in urlconf_module
> return import_module(self.urlconf_name)
> /usr/lib/python3.11/importlib/__init__.py:126: in import_module
> return _bootstrap._gcd_import(name[level:], package, level)
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> _
>
>
> > from django.conf.urls import include, url
> E ImportError: cannot import name 'url' from 'django.conf.urls'
> (/usr/lib/python3/dist-packages/django/conf/urls/__init__.py)
>
> tests/testapp/urls.py:2: ImportError
>
> During handling of the above exception, another exception occurred:
>
> self = <tests.test_backends.ComplexFilterBackendTests
> testMethod=test_pagination_compatibility>
>
> def test_pagination_compatibility(self):
> # Ensure that complex-filtering does not affect additional query
> param processing.
> readable = quote('(email__contains%3Dexample.org)')
>
> # sanity check w/o pagination
> > response = self.client.get('/ffcomplex-users/?filters=' + readable)
>
> tests/test_backends.py:456:
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> _
> /usr/lib/python3/dist-packages/rest_framework/test.py:289: in get
> response = super().get(path, data=data, **extra)
> /usr/lib/python3/dist-packages/rest_framework/test.py:206: in get
> return self.generic('GET', path, **r)
> /usr/lib/python3/dist-packages/rest_framework/test.py:234: in generic
> return super().generic(
> /usr/lib/python3/dist-packages/django/test/client.py:609: in generic
> return self.request(**r)
> /usr/lib/python3/dist-packages/rest_framework/test.py:286: in request
> return super().request(**kwargs)
> /usr/lib/python3/dist-packages/rest_framework/test.py:238: in request
> request = super().request(**kwargs)
> /usr/lib/python3/dist-packages/django/test/client.py:886: in request
> response = self.handler(environ)
> /usr/lib/python3/dist-packages/django/test/client.py:176: in __call__
> response = self.get_response(request)
> /usr/lib/python3/dist-packages/rest_framework/test.py:258: in get_response
> return super().get_response(request)
> /usr/lib/python3/dist-packages/django/core/handlers/base.py:140: in
> get_response
> response = self._middleware_chain(request)
> /usr/lib/python3/dist-packages/django/core/handlers/exception.py:57: in inner
> response = response_for_exception(request, exc)
> /usr/lib/python3/dist-packages/django/core/handlers/exception.py:140: in
> response_for_exception
> response = handle_uncaught_exception(
> /usr/lib/python3/dist-packages/django/core/handlers/exception.py:184: in
> handle_uncaught_exception
> callback = resolver.resolve_error_handler(500)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:729: in
> resolve_error_handler
> callback = getattr(self.urlconf_module, "handler%s" % view_type, None)
> /usr/lib/python3/dist-packages/django/utils/functional.py:57: in __get__
> res = instance.__dict__[self.name] = self.func(instance)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:708: in urlconf_module
> return import_module(self.urlconf_name)
> /usr/lib/python3.11/importlib/__init__.py:126: in import_module
> return _bootstrap._gcd_import(name[level:], package, level)
> <frozen importlib._bootstrap>:1204: in _gcd_import
> ???
> <frozen importlib._bootstrap>:1176: in _find_and_load
> ???
> <frozen importlib._bootstrap>:1147: in _find_and_load_unlocked
> ???
> <frozen importlib._bootstrap>:690: in _load_unlocked
> ???
> <frozen importlib._bootstrap_external>:940: in exec_module
> ???
> <frozen importlib._bootstrap>:241: in _call_with_frames_removed
> ???
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> _
>
>
> > from django.conf.urls import include, url
> E ImportError: cannot import name 'url' from 'django.conf.urls'
> (/usr/lib/python3/dist-packages/django/conf/urls/__init__.py)
>
> tests/testapp/urls.py:2: ImportError
> _____________________ ComplexFilterBackendTests.test_valid
> _____________________
>
> request = <WSGIRequest: GET
> '/ffcomplex-users/?filters=%28username%253Duser1%29%7C%28email__contains%253Dexample.org%29'>
>
> @wraps(get_response)
> def inner(request):
> try:
> > response = get_response(request)
>
> /usr/lib/python3/dist-packages/django/core/handlers/exception.py:55:
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> _
> /usr/lib/python3/dist-packages/django/core/handlers/base.py:181: in
> _get_response
> callback, callback_args, callback_kwargs = self.resolve_request(request)
> /usr/lib/python3/dist-packages/django/core/handlers/base.py:313: in
> resolve_request
> resolver_match = resolver.resolve(request.path_info)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:663: in resolve
> for pattern in self.url_patterns:
> /usr/lib/python3/dist-packages/django/utils/functional.py:57: in __get__
> res = instance.__dict__[self.name] = self.func(instance)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:715: in url_patterns
> patterns = getattr(self.urlconf_module, "urlpatterns",
> self.urlconf_module)
> /usr/lib/python3/dist-packages/django/utils/functional.py:57: in __get__
> res = instance.__dict__[self.name] = self.func(instance)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:708: in urlconf_module
> return import_module(self.urlconf_name)
> /usr/lib/python3.11/importlib/__init__.py:126: in import_module
> return _bootstrap._gcd_import(name[level:], package, level)
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> _
>
>
> > from django.conf.urls import include, url
> E ImportError: cannot import name 'url' from 'django.conf.urls'
> (/usr/lib/python3/dist-packages/django/conf/urls/__init__.py)
>
> tests/testapp/urls.py:2: ImportError
>
> During handling of the above exception, another exception occurred:
>
> self = <tests.test_backends.ComplexFilterBackendTests testMethod=test_valid>
>
> def test_valid(self):
> readable = quote('(username%3Duser1)|(email__contains%3Dexample.org)')
> > response = self.client.get('/ffcomplex-users/?filters=' + readable)
>
> tests/test_backends.py:418:
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> _
> /usr/lib/python3/dist-packages/rest_framework/test.py:289: in get
> response = super().get(path, data=data, **extra)
> /usr/lib/python3/dist-packages/rest_framework/test.py:206: in get
> return self.generic('GET', path, **r)
> /usr/lib/python3/dist-packages/rest_framework/test.py:234: in generic
> return super().generic(
> /usr/lib/python3/dist-packages/django/test/client.py:609: in generic
> return self.request(**r)
> /usr/lib/python3/dist-packages/rest_framework/test.py:286: in request
> return super().request(**kwargs)
> /usr/lib/python3/dist-packages/rest_framework/test.py:238: in request
> request = super().request(**kwargs)
> /usr/lib/python3/dist-packages/django/test/client.py:886: in request
> response = self.handler(environ)
> /usr/lib/python3/dist-packages/django/test/client.py:176: in __call__
> response = self.get_response(request)
> /usr/lib/python3/dist-packages/rest_framework/test.py:258: in get_response
> return super().get_response(request)
> /usr/lib/python3/dist-packages/django/core/handlers/base.py:140: in
> get_response
> response = self._middleware_chain(request)
> /usr/lib/python3/dist-packages/django/core/handlers/exception.py:57: in inner
> response = response_for_exception(request, exc)
> /usr/lib/python3/dist-packages/django/core/handlers/exception.py:140: in
> response_for_exception
> response = handle_uncaught_exception(
> /usr/lib/python3/dist-packages/django/core/handlers/exception.py:184: in
> handle_uncaught_exception
> callback = resolver.resolve_error_handler(500)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:729: in
> resolve_error_handler
> callback = getattr(self.urlconf_module, "handler%s" % view_type, None)
> /usr/lib/python3/dist-packages/django/utils/functional.py:57: in __get__
> res = instance.__dict__[self.name] = self.func(instance)
> /usr/lib/python3/dist-packages/django/urls/resolvers.py:708: in urlconf_module
> return import_module(self.urlconf_name)
> /usr/lib/python3.11/importlib/__init__.py:126: in import_module
> return _bootstrap._gcd_import(name[level:], package, level)
> <frozen importlib._bootstrap>:1204: in _gcd_import
> ???
> <frozen importlib._bootstrap>:1176: in _find_and_load
> ???
> <frozen importlib._bootstrap>:1147: in _find_and_load_unlocked
> ???
> <frozen importlib._bootstrap>:690: in _load_unlocked
> ???
> <frozen importlib._bootstrap_external>:940: in exec_module
> ???
> <frozen importlib._bootstrap>:241: in _call_with_frames_removed
> ???
> _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
> _
>
>
> > from django.conf.urls import include, url
> E ImportError: cannot import name 'url' from 'django.conf.urls'
> (/usr/lib/python3/dist-packages/django/conf/urls/__init__.py)
>
> tests/testapp/urls.py:2: ImportError
> =============================== warnings summary
> ===============================
> ../../../../../../usr/lib/python3/dist-packages/django/conf/__init__.py:241
> /usr/lib/python3/dist-packages/django/conf/__init__.py:241:
> RemovedInDjango50Warning: The default value of USE_TZ will change from False
> to True in Django 5.0. Set USE_TZ to False in your project settings if you
> want to keep the current default behavior.
> warnings.warn(
>
> .pybuild/cpython3_3.11_djangorestframework-filters/build/tests/test_complex_ops.py::CombineComplexQuerysetTests::test_AND
>
> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.11_djangorestframework-filters/build/tests/test_complex_ops.py:202:
> RemovedInDjango51Warning: assertQuerysetEqual() is deprecated in favor of
> assertQuerySetEqual().
> self.assertQuerysetEqual(
>
> .pybuild/cpython3_3.11_djangorestframework-filters/build/tests/test_complex_ops.py::CombineComplexQuerysetTests::test_OR
>
> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.11_djangorestframework-filters/build/tests/test_complex_ops.py:217:
> RemovedInDjango51Warning: assertQuerysetEqual() is deprecated in favor of
> assertQuerySetEqual().
> self.assertQuerysetEqual(
>
> .pybuild/cpython3_3.11_djangorestframework-filters/build/tests/test_complex_ops.py::CombineComplexQuerysetTests::test_negation
>
> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.11_djangorestframework-filters/build/tests/test_complex_ops.py:232:
> RemovedInDjango51Warning: assertQuerysetEqual() is deprecated in favor of
> assertQuerySetEqual().
> self.assertQuerysetEqual(
>
> .pybuild/cpython3_3.11_djangorestframework-filters/build/tests/test_complex_ops.py::CombineComplexQuerysetTests::test_single
>
> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.11_djangorestframework-filters/build/tests/test_complex_ops.py:187:
> RemovedInDjango51Warning: assertQuerysetEqual() is deprecated in favor of
> assertQuerySetEqual().
> self.assertQuerysetEqual(
>
> .pybuild/cpython3_3.11_djangorestframework-filters/build/tests/test_filtering.py::RelatedFilterTests::test_relatedfilter_for_aliased_nested_relationships
>
> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.11_djangorestframework-filters/build/tests/test_filtering.py:256:
> RemovedInDjango51Warning: assertQuerysetEqual() is deprecated in favor of
> assertQuerySetEqual().
> self.assertQuerysetEqual(f1.qs, [3], lambda p: p.pk)
>
> .pybuild/cpython3_3.11_djangorestframework-filters/build/tests/test_filtering.py::RelatedFilterTests::test_relatedfilter_for_aliased_nested_relationships
>
> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.11_djangorestframework-filters/build/tests/test_filtering.py:257:
> RemovedInDjango51Warning: assertQuerysetEqual() is deprecated in favor of
> assertQuerySetEqual().
> self.assertQuerysetEqual(f2.qs, [4], lambda p: p.pk)
>
> .pybuild/cpython3_3.11_djangorestframework-filters/build/tests/test_filtering.py::RelatedFilterTests::test_relatedfilter_for_aliased_nested_relationships
>
> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.11_djangorestframework-filters/build/tests/test_filtering.py:258:
> RemovedInDjango51Warning: assertQuerysetEqual() is deprecated in favor of
> assertQuerySetEqual().
> self.assertQuerysetEqual(f3.qs, [], lambda p: p.pk)
>
> .pybuild/cpython3_3.11_djangorestframework-filters/build/tests/test_filtering.py::RelatedFilterTests::test_relatedfilter_for_aliased_nested_relationships
>
> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.11_djangorestframework-filters/build/tests/test_filtering.py:259:
> RemovedInDjango51Warning: assertQuerysetEqual() is deprecated in favor of
> assertQuerySetEqual().
> self.assertQuerysetEqual(f4.qs, [], lambda p: p.pk)
>
> .pybuild/cpython3_3.11_djangorestframework-filters/build/tests/related/test_exclude.py:
> 11 warnings
> .pybuild/cpython3_3.11_djangorestframework-filters/build/tests/related/test_filter.py:
> 7 warnings
>
> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.11_djangorestframework-filters/build/tests/related/data.py:105:
> RemovedInDjango51Warning: assertQuerysetEqual() is deprecated in favor of
> assertQuerySetEqual().
> self.assertQuerysetEqual(qs, expected, attrgetter('pk'), False)
>
> -- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
> =========================== short test summary info
> ============================
> FAILED tests/test_backends.py::BackendTests::test_django_filter_compatibility
> FAILED tests/test_backends.py::BackendTests::test_filterset_fields_reusability
> FAILED
> tests/test_backends.py::BackendCrispyFormsRenderingTests::test_crispy_forms_filterset_compatibility
> FAILED
> tests/test_backends.py::BackendCrispyFormsRenderingTests::test_related_filterset_crispy_forms
> FAILED tests/test_backends.py::ComplexFilterBackendTests::test_invalid -
> Impo...
> FAILED
> tests/test_backends.py::ComplexFilterBackendTests::test_invalid_filterset_errors
> FAILED
> tests/test_backends.py::ComplexFilterBackendTests::test_pagination_compatibility
> FAILED tests/test_backends.py::ComplexFilterBackendTests::test_valid -
> Import...
> ================== 8 failed, 143 passed, 27 warnings in 2.27s
> ==================
> E: pybuild pybuild:395: test: plugin distutils failed with: exit code=1: cd
> /<<PKGBUILDDIR>>/.pybuild/cpython3_3.11_djangorestframework-filters/build;
> python3.11 -m pytest tests
> rm -fr -- /tmp/dh-xdg-rundir-oyCl3wPk
> dh_auto_test: error: pybuild --test --test-pytest -i python{version} -p 3.11
> returned exit code 13
The full build log is available from:
http://qa-logs.debian.net/2023/09/25/djangorestframework-filters_1.0.0.dev2-2_unstable.log
All bugs filed during this archive rebuild are listed at:
https://bugs.debian.org/cgi-bin/pkgreport.cgi?tag=ftbfs-20230925;[email protected]
or:
https://udd.debian.org/bugs/?release=na&merged=ign&fnewerval=7&flastmodval=7&fusertag=only&fusertagtag=ftbfs-20230925&[email protected]&allbugs=1&cseverity=1&ctags=1&caffected=1#results
A list of current common problems and possible solutions is available at
http://wiki.debian.org/qa.debian.org/FTBFS . You're welcome to contribute!
If you reassign this bug to another package, please mark it as 'affects'-ing
this package. See https://www.debian.org/Bugs/server-control#affects
If you fail to reproduce this, please provide a build log and diff it with mine
so that we can identify if something relevant changed in the meantime.
--- End Message ---