Created
May 17, 2024 18:47
-
-
Save AlanCoding/fb44e008939875b9434117c7632ba4aa to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(awx) bash-5.1$ py.test awx/main/tests/functional/api/test_instance_group.py::test_instance_group_order_persistence awx/main/tests/docs/test_swagger_generation.py::TestSwaggerGeneration::test_sanity | |
========================================== test session starts ========================================== | |
platform linux -- Python 3.11.7, pytest-8.1.1, pluggy-1.5.0 | |
django: version: 4.2.6, settings: awx.main.tests.settings_for_test (from ini) | |
rootdir: /awx_devel | |
configfile: pytest.ini | |
plugins: anyio-4.3.0, django-test-migrations-1.3.0, asyncio-0.23.6, cov-5.0.0, django-4.8.0, forked-1.6.0, mock-1.11.1, timeout-2.3.1, xdist-1.34.0 | |
asyncio: mode=Mode.STRICT | |
collected 4 items | |
awx/main/tests/functional/api/test_instance_group.py ... [ 75%] | |
awx/main/tests/docs/test_swagger_generation.py E [100%] | |
================================================ ERRORS ================================================= | |
__________________________ ERROR at setup of TestSwaggerGeneration.test_sanity __________________________ | |
Traceback (most recent call last): | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/_pytest/runner.py", line 340, in from_call | |
result: Optional[TResult] = func() | |
^^^^^^ | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/_pytest/runner.py", line 240, in <lambda> | |
lambda: runtest_hook(item=item, **kwds), when=when, reraise=reraise | |
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/pluggy/_hooks.py", line 513, in __call__ | |
return self._hookexec(self.name, self._hookimpls.copy(), kwargs, firstresult) | |
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/pluggy/_manager.py", line 120, in _hookexec | |
return self._inner_hookexec(hook_name, methods, kwargs, firstresult) | |
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/pluggy/_callers.py", line 139, in _multicall | |
raise exception.with_traceback(exception.__traceback__) | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/pluggy/_callers.py", line 122, in _multicall | |
teardown.throw(exception) # type: ignore[union-attr] | |
^^^^^^^^^^^^^^^^^^^^^^^^^ | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/_pytest/unraisableexception.py", line 85, in pytest_runtest_setup | |
yield from unraisable_exception_runtest_hook() | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/_pytest/unraisableexception.py", line 65, in unraisable_exception_runtest_hook | |
yield | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/pluggy/_callers.py", line 122, in _multicall | |
teardown.throw(exception) # type: ignore[union-attr] | |
^^^^^^^^^^^^^^^^^^^^^^^^^ | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/_pytest/logging.py", line 843, in pytest_runtest_setup | |
yield from self._runtest_for(item, "setup") | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/_pytest/logging.py", line 832, in _runtest_for | |
yield | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/pluggy/_callers.py", line 122, in _multicall | |
teardown.throw(exception) # type: ignore[union-attr] | |
^^^^^^^^^^^^^^^^^^^^^^^^^ | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/_pytest/capture.py", line 878, in pytest_runtest_setup | |
return (yield) | |
^^^^^ | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/pluggy/_callers.py", line 122, in _multicall | |
teardown.throw(exception) # type: ignore[union-attr] | |
^^^^^^^^^^^^^^^^^^^^^^^^^ | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/_pytest/threadexception.py", line 82, in pytest_runtest_setup | |
yield from thread_exception_runtest_hook() | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/_pytest/threadexception.py", line 63, in thread_exception_runtest_hook | |
yield | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/pluggy/_callers.py", line 103, in _multicall | |
res = hook_impl.function(*args) | |
^^^^^^^^^^^^^^^^^^^^^^^^^ | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/_pytest/runner.py", line 158, in pytest_runtest_setup | |
item.session._setupstate.setup(item) | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/_pytest/runner.py", line 515, in setup | |
raise exc | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/_pytest/runner.py", line 512, in setup | |
col.setup() | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/_pytest/python.py", line 1775, in setup | |
self._request._fillfixtures() | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/_pytest/fixtures.py", line 687, in _fillfixtures | |
item.funcargs[argname] = self.getfixturevalue(argname) | |
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/_pytest/fixtures.py", line 541, in getfixturevalue | |
fixturedef = self._get_active_fixturedef(argname) | |
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/_pytest/fixtures.py", line 570, in _get_active_fixturedef | |
self._compute_fixture_value(fixturedef) | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/_pytest/fixtures.py", line 647, in _compute_fixture_value | |
fixturedef.execute(request=subrequest) | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/_pytest/fixtures.py", line 1079, in execute | |
result = ihook.pytest_fixture_setup(fixturedef=self, request=request) | |
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/pluggy/_hooks.py", line 513, in __call__ | |
return self._hookexec(self.name, self._hookimpls.copy(), kwargs, firstresult) | |
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/pluggy/_manager.py", line 120, in _hookexec | |
return self._inner_hookexec(hook_name, methods, kwargs, firstresult) | |
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/pluggy/_callers.py", line 182, in _multicall | |
return outcome.get_result() | |
^^^^^^^^^^^^^^^^^^^^ | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/pluggy/_result.py", line 100, in get_result | |
raise exc.with_traceback(exc.__traceback__) | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/pluggy/_callers.py", line 167, in _multicall | |
teardown.throw(outcome._exception) | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/_pytest/setuponly.py", line 36, in pytest_fixture_setup | |
return (yield) | |
^^^^^ | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/pluggy/_callers.py", line 103, in _multicall | |
res = hook_impl.function(*args) | |
^^^^^^^^^^^^^^^^^^^^^^^^^ | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/_pytest/fixtures.py", line 1132, in pytest_fixture_setup | |
result = call_fixture_func(fixturefunc, request, kwargs) | |
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/_pytest/fixtures.py", line 913, in call_fixture_func | |
fixture_result = fixturefunc(**kwargs) | |
^^^^^^^^^^^^^^^^^^^^^ | |
File "/awx_devel/awx/main/tests/docs/test_swagger_generation.py", line 130, in _prepare | |
response = get(url, user=admin) | |
^^^^^^^^^^^^^^^^^^^^ | |
File "/awx_devel/awx/main/tests/functional/conftest.py", line 631, in rf | |
response = view(request, *view_args, **view_kwargs) | |
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/django/views/decorators/csrf.py", line 56, in wrapper_view | |
return view_func(*args, **kwargs) | |
^^^^^^^^^^^^^^^^^^^^^^^^^^ | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/django/views/generic/base.py", line 104, in view | |
return self.dispatch(request, *args, **kwargs) | |
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/rest_framework/views.py", line 509, in dispatch | |
response = self.handle_exception(exc) | |
^^^^^^^^^^^^^^^^^^^^^^^^^^ | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/rest_framework/views.py", line 469, in handle_exception | |
self.raise_uncaught_exception(exc) | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/rest_framework/views.py", line 480, in raise_uncaught_exception | |
raise exc | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/rest_framework/views.py", line 506, in dispatch | |
response = handler(request, *args, **kwargs) | |
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/drf_yasg/views.py", line 96, in get | |
schema = generator.get_schema(request, self.public) | |
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/drf_yasg/generators.py", line 276, in get_schema | |
paths, prefix = self.get_paths(endpoints, components, request, public) | |
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/drf_yasg/generators.py", line 482, in get_paths | |
operation = self.get_operation(view, path, prefix, method, components, request) | |
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/drf_yasg/generators.py", line 509, in get_operation | |
operation_keys = self.get_operation_keys(path[len(prefix):], method, view) | |
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | |
File "/var/lib/awx/venv/awx/lib64/python3.11/site-packages/drf_yasg/generators.py", line 386, in get_operation_keys | |
mapped_methods = { | |
^ | |
TypeError: 'NoneType' object is not iterable | |
----------------------------------------- Captured stderr setup ----------------------------------------- | |
2024-05-17 18:41:01,394 INFO [-] awx.analytics.job_lifecycle projectupdate-1 created {"type": "projectupdate", "task_id": 1, "state": "created", "work_unit_id": null, "task_name": "name-2"} | |
------------------------------------------ Captured log setup ------------------------------------------- | |
DEBUG awx.main.models.inventory:inventory.py:392 Going to update inventory computed fields, pk=1 | |
DEBUG awx.main.models.inventory:inventory.py:435 Finished updating inventory computed fields, pk=1, in 0.007 seconds | |
WARNING rest_framework.fields:fields.py:994 min_value in DecimalField should be Decimal type. | |
=========================================== warnings summary ============================================ | |
../var/lib/awx/venv/awx/lib64/python3.11/site-packages/_pytest/assertion/rewrite.py:178 | |
/var/lib/awx/venv/awx/lib64/python3.11/site-packages/_pytest/assertion/rewrite.py:178: DeprecationWarning: pkg_resources is deprecated as an API. See https://setuptools.pypa.io/en/latest/pkg_resources.html | |
exec(co, module.__dict__) | |
../var/lib/awx/venv/awx/lib64/python3.11/site-packages/pkg_resources/__init__.py:2868 | |
/var/lib/awx/venv/awx/lib64/python3.11/site-packages/pkg_resources/__init__.py:2868: DeprecationWarning: Deprecated call to `pkg_resources.declare_namespace('zope')`. | |
Implementing implicit namespace packages (as specified in PEP 420) is preferred to `pkg_resources.declare_namespace`. See https://setuptools.pypa.io/en/latest/references/keywords.html#keyword-namespace-packages | |
declare_namespace(pkg) | |
../var/lib/awx/venv/awx/lib64/python3.11/site-packages/django/conf/__init__.py:267 | |
/var/lib/awx/venv/awx/lib64/python3.11/site-packages/django/conf/__init__.py:267: RemovedInDjango50Warning: The USE_L10N setting is deprecated. Starting with Django 5.0, localized formatting of data will always be enabled. For example Django will display numbers and dates using the format of the current locale. | |
warnings.warn(USE_L10N_DEPRECATED_MSG, RemovedInDjango50Warning) | |
../var/lib/awx/venv/awx/lib64/python3.11/site-packages/_pytest/assertion/rewrite.py:178 | |
/var/lib/awx/venv/awx/lib64/python3.11/site-packages/_pytest/assertion/rewrite.py:178: DeprecationWarning: module 'sre_constants' is deprecated | |
exec(co, module.__dict__) | |
../var/lib/awx/venv/awx/lib64/python3.11/site-packages/_pytest/assertion/rewrite.py:178 | |
/var/lib/awx/venv/awx/lib64/python3.11/site-packages/_pytest/assertion/rewrite.py:178: DeprecationWarning: 'cgi' is deprecated and slated for removal in Python 3.13 | |
exec(co, module.__dict__) | |
../var/lib/awx/venv/awx/lib64/python3.11/site-packages/_pytest/assertion/rewrite.py:178 | |
/var/lib/awx/venv/awx/lib64/python3.11/site-packages/_pytest/assertion/rewrite.py:178: DeprecationWarning: The distutils package is deprecated and slated for removal in Python 3.12. Use setuptools or check PEP 632 for potential alternatives | |
exec(co, module.__dict__) | |
awx/main/tests/functional/api/test_instance_group.py: 1 warning | |
awx/main/tests/docs/test_swagger_generation.py: 25 warnings | |
/var/lib/awx/venv/awx/lib64/python3.11/site-packages/rest_framework/schemas/coreapi.py:357: RemovedInDRF317Warning: CoreAPI compatibility is deprecated and will be removed in DRF 3.17 | |
warnings.warn('CoreAPI compatibility is deprecated and will be removed in DRF 3.17', RemovedInDRF317Warning) | |
-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html | |
======================================== short test summary info ======================================== | |
ERROR awx/main/tests/docs/test_swagger_generation.py::TestSwaggerGeneration::test_sanity - TypeError: 'NoneType' object is not iterable | |
================================ 3 passed, 32 warnings, 1 error in 3.12s ================================ | |
(awx) bash-5.1$ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment