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

Custom credential source without metadata test fails #3075

Open
minsis opened this issue Oct 26, 2024 · 1 comment
Open

Custom credential source without metadata test fails #3075

minsis opened this issue Oct 26, 2024 · 1 comment

Comments

@minsis
Copy link

minsis commented Oct 26, 2024

I've created a custom credential type which is loaded into AWX just fine. It has no metadata associated with it since I don't need to specify any kind of identifier to return data. In the AWX UI when clicking the "test" button it fails with an error.

image

Full text:

TypeError: undefined is not an object (evaluating 'r.inputs.metadata.reduce')
P1@http://127.0.0.1:49287/static/js/main.fcec0bf3.js:2:2168142
ao@http://127.0.0.1:49287/static/js/main.fcec0bf3.js:2:851392
Ks@http://127.0.0.1:49287/static/js/main.fcec0bf3.js:2:903737
Al@http://127.0.0.1:49287/static/js/main.fcec0bf3.js:2:890983
Tl@http://127.0.0.1:49287/static/js/main.fcec0bf3.js:2:890911
El@http://127.0.0.1:49287/static/js/main.fcec0bf3.js:2:890774
yl@http://127.0.0.1:49287/static/js/main.fcec0bf3.js:2:887740
@http://127.0.0.1:49287/static/js/main.fcec0bf3.js:2:837184
@http://127.0.0.1:49287/static/js/main.fcec0bf3.js:2:933490
Ki@http://127.0.0.1:49287/static/js/main.fcec0bf3.js:2:837130
Wi@http://127.0.0.1:49287/static/js/main.fcec0bf3.js:2:837065
Le@http://127.0.0.1:49287/static/js/main.fcec0bf3.js:2:908276
Yt@http://127.0.0.1:49287/static/js/main.fcec0bf3.js:2:815676

My inputs:

github_app_inputs = {
    "fields": [
        {"id": "app_id", "label": "Application ID", "type": "string", "required": True},
        {"id": "installation_id", "label": "Installation ID", "type": "integer", "required": True},
        {"id": "private_key", "label": "Private Key", "type": "string", 'multiline': True, "required": True, "secret": True},
        {"id": "jwt_expiry", "label": "JWT Token Expiry (sec)", "type": "integer", "default": 600},
    ],
    "required": ["app_id", "installation_id", "private_key"],
}
@minsis
Copy link
Author

minsis commented Oct 26, 2024

If I provide an empty metadata it the "test" button works now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant