Skip to content

Instantly share code, notes, and snippets.

@alikins
Created August 3, 2020 16:04
Show Gist options
  • Save alikins/196065bb24651ad37e11ba9206791817 to your computer and use it in GitHub Desktop.
Save alikins/196065bb24651ad37e11ba9206791817 to your computer and use it in GitHub Desktop.
pulp manage spectactular AttributeError in pulpcore.openapi
(galaxy_ng_py36) [newswoop:F31:galaxy_ng (use_pulp_git_330 %)]$ ./compose run --rm api manage spectacular --format openapi --file spec-openapi.yaml
INFO: Using compose profile alikins
INFO: $ANSIBLE_HUB_UI_PATH is unset.
If you want to run the UI inside compose please set $ANSIBLE_HUB_UI_PATH
to the location of your local copy of https://github.com/ansible/ansible-hub-ui.
Starting galaxy_ng_postgres_1 ... done
Starting galaxy_ng_redis_1 ... done
Starting galaxy_ng__base_1 ... done
Installing path django-extensions in editable mode.
Installing path pulpcore in editable mode.
Installing path pulp_ansible in editable mode.
Installing path galaxy_ng in editable mode.
Traceback (most recent call last):
File "/venv/bin/django-admin", line 8, in <module>
sys.exit(execute_from_command_line())
File "/venv/lib64/python3.6/site-packages/django/core/management/__init__.py", line 381, in execute_from_command_line
utility.execute()
File "/venv/lib64/python3.6/site-packages/django/core/management/__init__.py", line 375, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "/venv/lib64/python3.6/site-packages/django/core/management/base.py", line 323, in run_from_argv
self.execute(*args, **cmd_options)
File "/venv/lib64/python3.6/site-packages/django/core/management/base.py", line 364, in execute
output = self.handle(*args, **options)
File "/venv/lib64/python3.6/site-packages/drf_spectacular/management/commands/spectacular.py", line 50, in handle
schema = generator.get_schema(request=None, public=True)
File "/src/pulpcore/pulpcore/openapi/__init__.py", line 356, in get_schema
result = super().get_schema(request, public)
File "/venv/lib64/python3.6/site-packages/drf_spectacular/generators.py", line 166, in get_schema
paths=self.parse(request, public),
File "/src/pulpcore/pulpcore/openapi/__init__.py", line 272, in parse
if "bindings" in request.query_params:
AttributeError: 'NoneType' object has no attribute 'query_params'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment