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

Add checks (or other enforcement) to prevent model conflicts with rest_filters #395

Open
AlanCoding opened this issue May 16, 2024 · 0 comments
Labels
enhancement New feature or request help wanted Extra attention is needed ready to work Item is ready to be worked on

Comments

@AlanCoding
Copy link
Member

AlanCoding commented May 16, 2024

Followup from:

#384 (comment)

It is possibly to incorrectly configure rest_filters. The specific scenario described there is that you have MyModel.type field defined. This will not be filterable because type is a reserved word. So the obviously check is to crawl the model meta information and see if any field names are in the rest_filters reserved list. Simple enough.

Related AWX issue

We have a related subject that, as a tech-debt item, we should set ignored fields specific to AWX in the setting ANSIBLE_BASE_REST_FILTERS_RESERVED_NAMES in the AWX settings, or in the AWX view. Then these should be moved out of the default setting value.

@AlanCoding AlanCoding added enhancement New feature or request help wanted Extra attention is needed ready to work Item is ready to be worked on labels May 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed ready to work Item is ready to be worked on
Projects
None yet
Development

No branches or pull requests

1 participant