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

Fix broken credentials input on single-provider blocks #8635

Closed
Pwuts opened this issue Nov 13, 2024 — with Linear · 0 comments
Closed

Fix broken credentials input on single-provider blocks #8635

Pwuts opened this issue Nov 13, 2024 — with Linear · 0 comments
Assignees
Labels
bug Something isn't working platform/frontend AutoGPT Platform - Front end

Comments

Copy link
Member

Pwuts commented Nov 13, 2024

PR #8524 introduced a discrimination mechanism for credentials inputs on multi-provider blocks, but due to a type mismatch between frontend and backend this breaks on blocks without a credentials provider discriminator.

The type mismatch:

image.png

image.png

@Pwuts Pwuts added bug Something isn't working platform/frontend AutoGPT Platform - Front end labels Nov 13, 2024 — with Linear
@Pwuts Pwuts self-assigned this Nov 13, 2024
Pwuts added a commit that referenced this issue Nov 13, 2024
Pwuts added a commit that referenced this issue Nov 13, 2024
…8636)

- Resolves #8635

- fix(frontend): Fix type mismatch of `CredentialsField` schema between frontend and backend
   - Fix usages of `credentialsSchema.credentials_provider`

- refactor(backend): Create `CredentialsFieldSchemaExtra` model in backend so it can be mirrored directly in frontend
   - Add check to enforce multi-provider `CredentialsField` always has `discriminator`

- dx: Add type checking shortcut `yarn type-check` / `npm run type-check` for frontend
@Pwuts Pwuts closed this as completed Nov 13, 2024
Pwuts added a commit that referenced this issue Nov 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working platform/frontend AutoGPT Platform - Front end
Projects
None yet
Development

No branches or pull requests

1 participant