Project

Profile

Help

Issue #7258

Not able to generate schema with the CLI

Added by fao89 about 2 months ago. Updated about 2 months ago.

Status:
CLOSED - CURRENTRELEASE
Priority:
Normal
Assignee:
-
Category:
-
Sprint/Milestone:
Start date:
Due date:
Estimated time:
Severity:
2. Medium
Version:
Platform Release:
OS:
Triaged:
No
Groomed:
No
Sprint Candidate:
No
Tags:
API Bindings, Documentation
Sprint:
Quarter:

Description

(pulp) [vagrant@pulp3-source-fedora31 ~]$ django-admin spectacular --format openapi --file spec-openapi.yaml
Traceback (most recent call last):
  File "/usr/local/lib/pulp/bin/django-admin", line 8, in <module>
    sys.exit(execute_from_command_line())
  File "/usr/local/lib/pulp/lib64/python3.7/site-packages/django/core/management/__init__.py", line 381, in execute_from_command_line
    utility.execute()
  File "/usr/local/lib/pulp/lib64/python3.7/site-packages/django/core/management/__init__.py", line 375, in execute
    self.fetch_command(subcommand).run_from_argv(self.argv)
  File "/usr/local/lib/pulp/lib64/python3.7/site-packages/django/core/management/base.py", line 323, in run_from_argv
    self.execute(*args, **cmd_options)
  File "/usr/local/lib/pulp/lib64/python3.7/site-packages/django/core/management/base.py", line 364, in execute
    output = self.handle(*args, **options)
  File "/usr/local/lib/pulp/lib64/python3.7/site-packages/drf_spectacular/management/commands/spectacular.py", line 50, in handle
    schema = generator.get_schema(request=None, public=True)
  File "/home/vagrant/devel/pulpcore/pulpcore/openapi/__init__.py", line 356, in get_schema
    result = super().get_schema(request, public)
  File "/usr/local/lib/pulp/lib64/python3.7/site-packages/drf_spectacular/generators.py", line 166, in get_schema
    paths=self.parse(request, public),
  File "/home/vagrant/devel/pulpcore/pulpcore/openapi/__init__.py", line 272, in parse
    if "bindings" in request.query_params:
AttributeError: 'NoneType' object has no attribute 'query_params'

Associated revisions

Revision f6c53f62 View on GitHub
Added by Fabricio Aguiar about 2 months ago

OpenAPI schema generation from CLI

https://pulp.plan.io/issues/7258 closes #7258

History

#1 Updated by pulpbot about 2 months ago

  • Status changed from NEW to POST

#2 Updated by Anonymous about 2 months ago

  • Status changed from POST to MODIFIED

#3 Updated by dkliban@redhat.com about 2 months ago

  • Sprint/Milestone set to 3.6.0

#4 Updated by pulpbot about 2 months ago

  • Status changed from MODIFIED to CLOSED - CURRENTRELEASE

Please register to edit this issue

Also available in: Atom PDF