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

Code changes needed to update to drf-spectacular latest version #5518

Open
glennmatthews opened this issue Apr 1, 2024 · 1 comment
Open
Labels
type: bug Something isn't working as expected

Comments

@glennmatthews
Copy link
Contributor

Environment

  • Nautobot version (Docker tag too if applicable): 2.2.0

Steps to Reproduce

  1. poetry add --extras sidecar drf-spectacular~0.27.2
  2. Build container
  3. invoke check-schema

Expected Behavior

Schema generation to pass without errors

Observed Behavior

Warning: enum naming encountered a non-optimally resolvable collision for fields named "type". The same name has been used for multiple choice sets in multiple components. The collision was resolved with "Type6adEnum". add an entry to ENUM_NAME_OVERRIDES to fix the naming.
Warning: enum naming encountered a non-optimally resolvable collision for fields named "type". The same name has been used for multiple choice sets in multiple components. The collision was resolved with "Type09dEnum". add an entry to ENUM_NAME_OVERRIDES to fix the naming.
Warning: enum naming encountered a non-optimally resolvable collision for fields named "type". The same name has been used for multiple choice sets in multiple components. The collision was resolved with "TypeF53Enum". add an entry to ENUM_NAME_OVERRIDES to fix the naming.
Warning: enum naming encountered a non-optimally resolvable collision for fields named "type". The same name has been used for multiple choice sets in multiple components. The collision was resolved with "Type7b8Enum". add an entry to ENUM_NAME_OVERRIDES to fix the naming.
Warning: enum naming encountered a non-optimally resolvable collision for fields named "type". The same name has been used for multiple choice sets in multiple components. The collision was resolved with "Type459Enum". add an entry to ENUM_NAME_OVERRIDES to fix the naming.
Warning: enum naming encountered a non-optimally resolvable collision for fields named "mode". The same name has been used for multiple choice sets in multiple components. The collision was resolved with "Mode308Enum". add an entry to ENUM_NAME_OVERRIDES to fix the naming.
Warning: enum naming encountered a non-optimally resolvable collision for fields named "mode". The same name has been used for multiple choice sets in multiple components. The collision was resolved with "Mode791Enum". add an entry to ENUM_NAME_OVERRIDES to fix the naming.

Schema generation summary:
Warnings: 7 (7 unique)
Errors:   0 (0 unique)

SchemaGenerationError: Failing as requested due to warnings

This appears to be due to additional validation logic added by tfranzel/drf-spectacular#1113

@glennmatthews glennmatthews added the type: bug Something isn't working as expected label Apr 1, 2024
@lampwins
Copy link
Member

lampwins commented Apr 4, 2024

Once this is done, ensure the dependency is actually updated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug Something isn't working as expected
Projects
None yet
Development

No branches or pull requests

2 participants