Related to #5099
Current OPTIONS for job_templates output doesn't have default listed as "default": "" for webhook_service, which have required: false.
Default is expected to be listed within the API since it is not required -
"webhook_service": {
"type": "choice",
"required": false,
"label": "Webhook service",
"help_text": "Service that webhook requests will be accepted from",
"filterable": true,
"choices": [
[
"",
"---------"
],
[
"github",
"GitHub"
],
[
"gitlab",
"GitLab"
]
]
},
AWX version: 11.2.0
AWX install method: N/A
Ansible version: N/A
Operating System:
Web Browser:
@ryanpetrello can you weigh in on this?
Nope, I'm not familiar with the change that affected this cc @AlanCoding @jbradberry @elyezer
This skip field behavior is coming from Django REST Framework itself, and thus this piece of metadata should be missing on all of our fields that have an empty default since we aren't overriding it anywhere.
https://github.com/ansible/awx/blob/a26df3135b73290951c45a2a3903849517a44c72/awx/api/metadata.py#L88-L96
This looks easy enough to fix if we want this change, but it will affect all currently skipped fields, not just .webhook_service
I take that back, ultimately the field itself is refusing to return a value when get_default is called on it.